Exit interior script question -
MrXavier - 05.11.2009
I have managed to create an icon that teleports you into an interior. However, there is no way to exit. How, and or what can I add so when I type /exit, I go to a certain spot? Can Anyone help?
Re: Exit interior script question -
Devine - 05.11.2009
Exit is basically the same as enter, it's just an invert operation. Instead of sending them into that interior pos, you send them to the pos that they were last at before entering the interior.
Re: Exit interior script question -
MrXavier - 05.11.2009
see I used a pickup to teleport me into the interior.
and I cant figure out how to make it so I can exit
Re: Exit interior script question -
Devine - 05.11.2009
Quote:
Originally Posted by MrXavier
see I used a pickup to teleport me into the interior.
and I cant figure out how to make it so I can exit
|
pawn Код:
if(PlayerToPoint(1, playerid, //exit pos))
{
SetPlayerInterior(playerid, 0);
SetPlayerVirtualWorld(playerid, 0);
SetPlayerPos(playerid, //old pos/enter pos);
}
Re: Exit interior script question -
MrXavier - 05.11.2009
how do I have the exit for this code, because thats what tp's me into the interior
Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(pickupid == ARMORY)
SetPlayerPos(playerid,2324.419921,-1145.568359,1050.710083);
SetPlayerInterior(playerid,12);
Re: Exit interior script question -
Zeromanster - 05.11.2009
Quote:
Originally Posted by MrXavier
how do I have the exit for this code, because thats what tp's me into the interior
Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(pickupid == ARMORY)
SetPlayerPos(playerid,2324.419921,-1145.568359,1050.710083);
SetPlayerInterior(playerid,12);
|
Make another pickup that teleports you outside.
Re: Exit interior script question -
MrXavier - 05.11.2009
how could I put an "i" marker in an interior? and have it stay? try to show me via my code post.
Re: Exit interior script question -
MrXavier - 05.11.2009
Now, I have added an opposite pickup, yet It now just teleports me into midair. Please help me. Here is the code.
Код:
new ENTER;
new EXIT;
Код:
ENTER = CreatePickup(1239,2,1675.5028,-1637.3276,14.2266);
EXIT = CreatePickup(1239,2,2316.19,-1144.39,1054.30,-1);
Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(pickupid == ENTER)
SetPlayerPos(playerid,2324.419921,-1145.568359,1050.710083);
SetPlayerInterior(playerid,12);
if(pickupid == EXIT)
SetPlayerPos(playerid,1675.5028,-1637.3276,14.2266);
SetPlayerInterior(playerid,0);
}
Re: Exit interior script question -
Blaze09 - 05.11.2009
Use wiki to search icon IDs.
www.wiki.sa-mp.com
Re: Exit interior script question -
MrXavier - 06.11.2009
IGNORE THIS THREAD!
I got this to work after some messing around!