IsFactionCar isn't running
#1

Hello all, i'm making faction cars but when i did the script, i saw some warnings ( 18 warnings exactly, yes, so many... ), but, the problem is, when I'm joining the game with pFaction variable 0, if i'm entering the faction car without specific faction, I don't get down from vehicle. A warning, that's why, or...? Down I will take some usefully stuff. Thanks.

Code:
forward IsJobCar(vehicleid);
stock IsJobCar(vehicleid)
{
	new EQNCar[MAX_VEHICLES];
    for(new i = 0; i < sizeof(EQNCar); i++)
        if(vehicleid == EQNCar[i])
            return true;
    return false;
}
*IsJobCar function
Code:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
	if(IsJobCar(vehicleid) && PlayerInfo[playerid][pFaction] != 4)
	{
		RemovePlayerFromVehicle(playerid);
	    SendClientMessage(playerid, -1, "{FFFFFF}Factiune invalida.");
	}
	return 1;
}
*OnPlayerEnterVehicle function
Mhm, if now I think, I must put GetVehicleID after OnPlayerEnterVehicle line?... I really don't know.
Bye!
Reply


Messages In This Thread
IsFactionCar isn't running - by ImTouchk - 26.09.2016, 18:13
Re: IsFactionCar isn't running - by Vince - 26.09.2016, 18:35
Re: IsFactionCar isn't running - by ImTouchk - 26.09.2016, 19:34
Re: IsFactionCar isn't running - by Shinja - 26.09.2016, 19:52
Re: IsFactionCar isn't running - by ImTouchk - 27.09.2016, 07:09
Re: IsFactionCar isn't running - by Konstantinos - 27.09.2016, 08:59

Forum Jump:


Users browsing this thread: 1 Guest(s)