30.04.2009, 21:52
You haven't posted a newcar variable in the code above, so I'm not sure what you're asking...
I added a line to get a newcar variable, if that's what you want...
Код:
if(strcmp(cmd, "/respawnthiscar", true) == 0 || strcmp(cmd, "/rtc", true) == 0) // by Ellis { if(IsPlayerConnected(playerid)) { if(IsPlayerInAnyVehicle(playerid)) { new newcar = GetPlayerVehicleID(playerid); GetPlayerName(playerid, sendername, sizeof(sendername)); format(string, 256, "%s has just respawned vehicle id %d.",sendername,GetPlayerVehicleID(playerid)); ABroadCast(COLOR_YELLOW,string,1); SetVehicleToRespawn(GetPlayerVehicleID(playerid)); RemovePlayerFromVehicle(playerid); SendClientMessage(playerid, BLUE, " Vehicle Respawned !"); SendClientMessage(" CAR ID: %d ", GetPlayerVehicleID(playerid)); } } return 1; }