25.02.2012, 22:37
Quote:
Why doesn't this work?
pawn Код:
|
You can also use this for checking if player is exiting a vehicle:-
pawn Код:
public OnPlayerExitVehicle(playerid, vehicleid, ispassenger)
{
SendClientMessage(playerid, -1, "You are going to exit the vehicle.");
return 1;
}
pawn Код:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if ((newstate == PLAYER_STATE_ONFOOT) && ((oldstate == PLAYER_STATE_DRIVER) || (oldstate == PLAYER_STATE_PASSENGER))) // your new state is ONFOOT and old state is when he was in the vehicle.
// your rest of code here
SendClientMessage(playerid, -1, "you just exited a vehicle.");
return 1;
}
-FalconX