16.12.2010, 11:47
Modificado:
Original
Код:
if(strcmp(cmd, "/getcar", true) == 0) { if(IsPlayerConnected(playerid)) { tmp = strtok(cmdtext, idx); if(!strlen(tmp)) { SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /getcar [carid]"); return true; } new plo; new playa; playa = ReturnUser(tmp); plo = strval(tmp); new Float:plocx,Float:plocy,Float:plocz; if (PlayerInfo[playerid][pAdmin] >= 3) { new tmpVehID; GetPlayerPos(playerid, plocx, plocy, plocz); tmpVehID = AddStaticVehicle(plo,plocx,plocy+4, plocz,0,1); PutPlayerInVehicle(playa, tmpVehID, SeatDriveMod); return true; } else { SendClientMessage(playerid, COLOR_GRAD1, " you are not authorized to use that command!"); } } return true; }
Код:
if(strcmp(cmd, "/getcar", true) == 0) { if(IsPlayerConnected(playerid)) { tmp = strtok(cmdtext, idx); if(!strlen(tmp)) { SendClientMessage(playerid, COLOR_GRAD2, "USAGE: /getcar [carid]"); return 1; } new Float:plocx,Float:plocy,Float:plocz; new plo; plo = strval(tmp); if (PlayerInfo[playerid][pAdmin] >= 3) { GetPlayerPos(playerid, plocx, plocy, plocz); SetVehiclePos(plo,plocx,plocy+4, plocz); } else { SendClientMessage(playerid, COLOR_GRAD1, " you are not authorized to use that command!"); } } return 1; }