What's wrong in the logic of the code?
#1

This code is supposed to let the player who're class 5 or 9 ride the armed vehicles. But this isn't letting ANYONE ride them, not even a single class.

Код:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
    new vehicleid = GetVehicleModel(GetPlayerVehicleID(playerid));
	if(vehicleid == 520 || vehicleid == 447 || vehicleid == 425 || vehicleid == 432)
	{
     	if(class[playerid] != 5 || class[playerid] != 9)
	    {
	        SendClientMessage(playerid, -1, "{FF0000}Error: {FFFFFF}Your Class must be Technician or Donator to Drive Armed Vehicles.");
	        RemovePlayerFromVehicle(playerid);
	        return 1;
		}
	}
	return 1;
}
Reply


Messages In This Thread
What's wrong in the logic of the code? - by Ritzy2K - 14.11.2017, 09:22
Re: What's wrong in the logic of the code? - by Gammix - 14.11.2017, 09:24
Re: What's wrong in the logic of the code? - by Ritzy2K - 14.11.2017, 09:30

Forum Jump:


Users browsing this thread: 1 Guest(s)