#10

Use OnPlayerEnterVehicle.
You can stop the player from entering the vehicle if he's not doing the job like this:
PHP код:
public OnPlayerEnterVehicle(playeridvehicleidispassenger)
{
    new 
model GetVehicleModel(vehicleid);
    if(
model == 407){
        if(
Fireman[playerid] == 0){
        new 
Float:X,Float:Y,Float:Z;
        
GetPlayerPos(playerid,X,Y,Z);
        
SetPlayerPos(playerid,X,Y,Z);
        
SendClientMessage(playeridCOLOR_WHITE"You don't have the fireman job.");
        return 
1;
        }
    }
    return 
1;

Reply


Messages In This Thread
Anti - by Ugaustin - 12.06.2016, 12:31
Re: Anti - by Xdrime - 12.06.2016, 12:41
Re: Anti - by MBilal - 12.06.2016, 12:42
Re: Anti - by Ugaustin - 12.06.2016, 13:27
Re: Anti - by MBilal - 12.06.2016, 13:37
Re: Anti - by Ugaustin - 12.06.2016, 16:19
Re: Anti - by Ugaustin - 12.06.2016, 18:43
Re: Anti - by Ugaustin - 13.06.2016, 11:18
Re: Anti - by Sjn - 13.06.2016, 12:08
Re: Anti - by cuzido - 13.06.2016, 12:09

Forum Jump:


Users browsing this thread: 1 Guest(s)