03.02.2014, 02:14
Hello so i made a variable that if a player dosent picks a class Engineer or Pilot he cant get in to army vehicles
but when i try to get in when i am not a pilot or engineer nothing happens it dosent remove me from the vehicle
if you guys help me i will +rep you
here is the code
but when i try to get in when i am not a pilot or engineer nothing happens it dosent remove me from the vehicle
if you guys help me i will +rep you
here is the code
pawn Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
if(vehicleid == 432)
{
if(Engineer[playerid] != 1)
{
RemovePlayerFromVehicle(playerid);
SendClientMessage(playerid,COLOR_RED,"You need to be Engineer class to use this vehicle");
}
}
if(vehicleid == 520 && 425)
{
if(Pilot[playerid] != 1)
{
RemovePlayerFromVehicle(playerid);
SendClientMessage(playerid,COLOR_RED,"You need to be Pilot class to use this vehicle");
}
}
return 1;
}