07.10.2009, 22:48
I How make a command to respawn vehicles
if(strcmp(cmd, "/respawnall", true) == 0 || strcmp(cmd, "/respvehs", true) == 0) { for(new i=0;i<MAX_VEHICLES;i++) { if(IsVehicleOccupied(i) == 0) { SetVehicleToRespawn(i); } } SendClientMessage(playerid, 0xAFAFAFAA, "* All unoccupied vehicles respawned!!"); return 1; }
forward IsVehicleOccupied(vehicleid); public IsVehicleOccupied(vehicleid) { for(new i=0;i<MAX_PLAYERS;i++) { if(IsPlayerInVehicle(i,vehicleid)) return 1; } return 0; }
Originally Posted by MartinDaniel
C:\Documents and Settings\Medo\Desktop\SA-MP Server\gamemodes\stuntscript.pwn(366) : error 017: undefined symbol "cmd"
How i fix it please ? |