SA-MP Forums Archive
/enter [help] - 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: /enter [help] (/showthread.php?tid=332527)



/enter [help] - Infinity90 - 08.04.2012

Hello, SA-MP Community, I was wounding how i could make it so that I could use /enter at any SWAT Van and it would put me in a interior that i custom made. Any ideas on how to do this? I have searched and ****** it.


Re: /enter [help] - Cjgogo - 08.04.2012

pawn Код:
COMAMND:enter(playerid,params[])
{
   if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid,COLOR_RED,"This command must be used on SWAT Van!");
   else
   {
     new vehicleid=GetPlayerVehicleID(playerid);
     if(vehicleid==601) SetPlayerInterior(playerid,custom alien interior made by you id);
     else SendClientMessage(playerid,COLOR_RED,"This command must be used on SWAT Van!");
   }
 return 1;
}



Re: /enter [help] - Infinity90 - 08.04.2012

Thanks!!! YOUR AWSOME DUDE (: + Rep'd you


Re: /enter [help] - Infinity90 - 08.04.2012

Would you be able to use /enter anywhere thou?


Re: /enter [help] - Kindred - 08.04.2012

Considering the fact if you were to read his command, it states that if the player is in any vehicle it continues, and if he is in the vehicleid of 601, it would allow you to enter. So no.


Re: /enter [help] - Infinity90 - 08.04.2012

I get this error warning 203: symbol is never used: "enter"
EDIT: Fixed ^
Also how would i make A /exit command so where ever the vehicle stops someone can Exit at that position?


Re: /enter [help] - Infinity90 - 08.04.2012

Ok quick bug it doesnt let me enter the vehicle. :/
Код:
CMD:entervan(playerid,params[])
{
   if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid,COLOR_RED,"This command must be used on SWAT Van!");
   else
   {
     new vehicleid=GetPlayerVehicleID(playerid);
   if(vehicleid==427)
		  SetPlayerPos(playerid,-26.2717,42.6422,1000.3384);
     else SendClientMessage(playerid,COLOR_RED,"This command must be used near a Enforcer!");
   }
 return 1;
}