27.04.2017, 14:21
Works perfectly fine using this code:
I went into the server, went to the coordinates and pressed F, it took me inside of the Cluckin Bell and set the interior right, came to the door and pressed F again and it took me to the outside of it, working fine? Strange issue if it's not working for you.
pawn Code:
#include <a_samp>
public OnGameModeInit()
{
DisableInteriorEnterExits();
CreatePickup(1318, 1, -1816.5437,618.0901,35.1719, 0);
return true;
}
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
if(newkeys & KEY_SECONDARY_ATTACK)
{
if(IsPlayerInRangeOfPoint(playerid, 3.0, -1816.5437,618.0901,35.1719))
{
SetPlayerPos(playerid, 364.8150,-11.6074,1001.8516);
SetPlayerInterior(playerid, 9);
}
else if(IsPlayerInRangeOfPoint(playerid, 3.0, 364.8150,-11.6074,1001.8516))
{
SetPlayerPos(playerid, -1816.5437,618.0901,35.1719);
SetPlayerInterior(playerid, 0);
}
}
return 1;
}