SA-MP Forums Archive
help! with car engine - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: help! with car engine (/showthread.php?tid=122331)



help! with car engine - wordas - 21.01.2010

hello guys, i need your help i use Vortex RP Script and when i want to add a engine system(from LARP) i have this :

Код:
public Startup(playerid, vehicleid)
{
  new pveh = GetVehicleModel(GetPlayerVehicleID(playerid));
  new newcar = GetPlayerVehicleID(playerid);
	if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER || engineOn[vehicleid])
	{
		//I do nothing!
	}
	else if(IsPlayerInAnyVehicle(playerid) && !engineOn[vehicleid] && !vehicleEntered[playerid][vehicleid] && GetPlayerState(playerid) == PLAYER_STATE_DRIVER && pveh != 510 && pveh != 462 && newcar != 59 && newcar != 60)
	{
		SendClientMessage(playerid, COLOR_RED, "use ALT");
		TogglePlayerControllable(playerid,false);
		vehicleEntered[playerid][vehicleid] = true;
	}
	else if(IsPlayerInAnyVehicle(playerid) && !engineOn[vehicleid] && vehicleEntered[playerid][vehicleid] && GetPlayerState(playerid) == PLAYER_STATE_DRIVER && pveh != 510 && pveh != 462 && newcar != 59 && newcar != 60)
	{
		SendClientMessage(playerid, COLOR_RED, "use ALT");
		TogglePlayerControllable(playerid,false);
	}
}
everythings ok no errors, when i go in-game it writes me "use ALT" but dosen't froze me... whats the prob.?


Re: help! with car engine - Kwarde - 21.01.2010

Quote:

TogglePlayerControllable(playerid,false);

Try to toggle the false to 0
So this:
pawn Код:
TogglePlayerControllable(playerid,0);



Re: help! with car engine - wordas - 21.01.2010

already tried i also tried to put this onstatechange but nothing maybe its Vortex script or something?


Re: help! with car engine - wordas - 21.01.2010

come on guys, i really need to do this is there no other way? any at all?


Re: help! with car engine - Kwarde - 21.01.2010

Sorry I dunno then. I gonna look at it. Can I get the WHOLE script?
Gvm


Re: help! with car engine - wordas - 21.01.2010

Quote:
Originally Posted by Kwarde
Sorry I dunno then. I gonna look at it. Can I get the WHOLE script?
Gvm
its in this Forum, just look for Vortex Role-Play its Carlitos Edit.

It Work fine with the larp but in Carlitos edit it won't


Re: help! with car engine - wordas - 21.01.2010

just checked that it won't work only in vehicles


Re: help! with car engine - Kwarde - 21.01.2010

okay


Re: help! with car engine - wordas - 21.01.2010

fixed it. Turns out my speedo meter f****d all up