If the player does not have enough scoure Prevent him from ride Hydra , tank or ....
#5

PHP код:
public OnPlayerStateChange(playeridnewstateoldstate)
{
      if(
newstate == PLAYER_STATE_DRIVER)
         if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 520 && GetPlayerScore(playerid) < 500)
               
RemovePlayerFromVehicle(playerid);
     return 
1;

This code will remove player from Hydra if his score is less than 500.
520 is Hydra vehicle Model ID, refer to https://sampwiki.blast.hk/wiki/Vehicle_Model_ID_List for list of vehicle and their model ids.

EDIT: Too late answer has been already posted above.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 3 Guest(s)