SA-MP Forums Archive
Dont't check if the engine on - 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: Dont't check if the engine on (/showthread.php?tid=639182)



Dont't check if the engine on - Ilaibens - 12.08.2017

Hey, I do check in OnPlayerEnterVehicle if the engine off he send msg to player, but the engine on and he send the msg.
Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
 	GetVehicleParamsEx(vehicleid,engine,lights,alarm,doors,bonnet,boot,objective);
 	if(engine == VEHICLE_PARAMS_OFF || engine == VEHICLE_PARAMS_UNSET)
 	{
		SendClientMessage(playerid, COLOR_WHITE, "The engine of this vehicle is off. Use /engine to start it.");
	}
	return 1;
}
Thanks !

Edit:
I'm fix it.