21.06.2011, 15:47
PHP код:
new Carro[MAX_PLAYERS] = 0x0;
if(strcmp(cmd, "/zr350", true) == 0) {
DestroyVehicle(Carro[playerid]);
new Float:Pos[4];
GetPlayerPos(playerid,Pos[0],Pos[1],Pos[2]);
GetPlayerFacingAngle(playerid,Pos[3]);
Carro[playerid] = AddStaticVehicle(477,Pos[0],Pos[1],Pos[2],Pos[3],-1,-1,60000);
PutPlayerInVehicle(playerid, Carro[playerid], 0);
return 0x01;
}
//OnPlayerDisconnect:
if(Carro[playerid] > 0) DestroyVehicle(Carro[playerid);