I need help with entering with a car - 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: I need help with entering with a car (
/showthread.php?tid=362331)
I need help with entering with a car -
Ryan_Michael - 24.07.2012
How would i enter a place (garage) when i type /enter and when i /exit and can enter and exit with the car and have it change VW?
Re: I need help with entering with a car -
djcabo - 24.07.2012
goto pawno and script! xD need more help contact me on skype and i teach u! dj.cabo
Re: I need help with entering with a car -
Ryan_Michael - 24.07.2012
Thats the thing i dont know what the script would be to enter with a car and exit with a car and change the VW too
Re: I need help with entering with a car -
McCurdy - 24.07.2012
I don't how to /enter with the car but as i know use LinkVehicleInterior and SetVehicleVirtualWorld to make your vehicle change the int and vw...
Re: I need help with entering with a car -
Devilxz97 - 24.07.2012
give me your x,y,z code . . and choose what interior u want it to spawn when /enter
http://weedarr.wikidot.com/interior
Re: I need help with entering with a car -
Ryan_Michael - 24.07.2012
This is the enter code
Код:
for(new idx=1; idx<MAX_GARAGES; idx++) // Dynamic Garages
{
if(IsPlayerInRangeOfPoint(playerid, 2, GarageInfo[idx][gX], GarageInfo[idx][gY], GarageInfo[idx][gZ]))
{
if(!GarageInfo[idx][gStatus] && PlayerInfo[playerid][pGarage] != idx && PlayerInfo[playerid][pVGarage] != idx) return SendClientMessage(playerid, COLOR_GREY, "This garage is locked.");
format(string, sizeof(string), "* %s pushes the garage door button and enters the Garage.", RPN(playerid));
SendNearbyMessage(playerid, 15, string, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE);
SetPlayerVirtualWorld(playerid, idx+500);
if(GarageInfo[idx][gLevel] == 1)
{
SetPlayerPos(playerid, 290.74,2542.92,16.82);
SetPlayerFacingAngle(playerid, 267.0980);
SetCameraBehindPlayer(playerid);
SetPlayerInterior(playerid, 0);
}
else if(GarageInfo[idx][gLevel] == 2)
{
SetPlayerPos(playerid, 366.77,2538.40,512.06);
SetPlayerFacingAngle(playerid, 267.3974);
SetCameraBehindPlayer(playerid);
SetPlayerInterior(playerid, 0);
}
else if(GarageInfo[idx][gLevel] == 3)
{
SetPlayerPos(playerid, 404.98,2457.82,16.50);
SetPlayerFacingAngle(playerid, 359.8550);
SetCameraBehindPlayer(playerid);
SetPlayerInterior(playerid, 0);
}
}
}