27.10.2009, 18:07
Hi,
I'd like to get a script that gets if the player has uzi/tec9/mp5 and removes it after he enters the car, and when he exits the car he gets it back (The weapon he had before). It is an anti-MP5-jump for bicycles. Since my script doesn't work and i am a newbie in PAWN, please help.
The one that doesn't work.
I'd like to get a script that gets if the player has uzi/tec9/mp5 and removes it after he enters the car, and when he exits the car he gets it back (The weapon he had before). It is an anti-MP5-jump for bicycles. Since my script doesn't work and i am a newbie in PAWN, please help.
pawn Код:
public OnPlayerStateChange(playerid,newstate,oldstate)
{
if (oldstate == PLAYER_STATE_ONFOOT)
if (newstate == PLAYER_STATE_DRIVER)
{
SetPlayerArmedWeapon(playerid, 0);
SendClientMessage(playerid, 0xFFFF00AA, "Driving a vehicle/bicycle, weapon switched to fists.");
}
return 1;
}