SA-MP Forums Archive
Vehicle problem - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Vehicle problem (/showthread.php?tid=608323)



Vehicle problem - Fantje - 30.05.2016

heey guys,

I have a class system and I made that only Pilot Class can drive hunters:

PHP код:
if(newstate == PLAYER_STATE_DRIVER && GetVehicleModel(GetPlayerVehicleID(playerid)) == 425 && gPlayerClass[playerid] != PILOT)
    {
        
RemovePlayerFromVehicle(playerid);
        
SendClientMessage(playeridCOLOR_RED"ERROR: You need the Pilot class to fly a Hunter.");
    } 
My Player class variable:
PHP код:
new gPlayerClass[MAX_PLAYERS];// for defining classes 
Why it doesnt work