Bugged /exit
#1

I'm not too sure what I did wrong here... /enter works fine at both of the enter points. But /exit takes me back to the one in Pershing Square... Can I get some help?


Код:
// PERSHING SQUARE  /ENTER & /EXIT COMMANDS - START

	if (strcmp("/enter", cmdtext, true, 6) == 0)
    {
        if(IsPlayerInRangeOfPoint(playerid, 4, 1412.1007, -1699.9229, 13.5395))
            {
                SetPlayerPos(playerid, 1753.5143, -1691.5734, -14.6642);
                SendClientMessage(playerid, 0xFFFFFFFFF, "{FF0000} Robotic Voice: Welcome to the FDSA Main Headquarters!");
				SetPlayerVirtualWorld(playerid, 10);
                return 1;
            }
    }
    
	if (strcmp("/exit", cmdtext, true, 6) == 0)
    {
        if(IsPlayerInRangeOfPoint(playerid, 4, 1753.5143, -1691.5734, -14.6642))
            {
                SetPlayerPos(playerid, 1412.1007, -1699.9229, 13.5395);
                SendClientMessage(playerid, 0xFFFFFFFF, "{FF0000} Robotic Voice: We hope you enjoyed your stay!");
				SetPlayerVirtualWorld(playerid, 0);

				return 1;
            }

    }
	
// PERSHING SQUARE /ENTER & /EXIT COMMANDS - END














// SAN FIERRO /ENTER & /EXIT COMMANDS - START

	if (strcmp("/enter", cmdtext, true, 7) == 0)
    {
        if(IsPlayerInRangeOfPoint(playerid, 4, -2026.7957, 67.0609, 28.6916))
            {
                SetPlayerPos(playerid, 1753.5143, -1691.5734, -14.6642);
                SendClientMessage(playerid, 0xFFFFFFFFF, "{FF0000} Robotic Voice: Welcome to the FDSA Main Headquarters!");
                SetPlayerVirtualWorld(playerid, 11);
                return 1;
            }
    }

	if (strcmp("/exit", cmdtext, true, 7) == 0)
    {
        if(IsPlayerInRangeOfPoint(playerid, 4, 1753.5143, -1691.5734, -14.6642))
            {
                SetPlayerPos(playerid, -2026.7957, 67.0609, 28.6916);
                SendClientMessage(playerid, 0xFFFFFFFF, "{FF0000} Robotic Voice: We hope you enjoyed your stay!");
				SetPlayerVirtualWorld(playerid, 0);
                return 1;
            }

    }


//SAN FIERRO /ENTER & /EXIT COMMANDS - END
Reply
#2

Look at your IsPlayerInRangeOfPoint for both exit commands. They are the same.
Reply
#3

Quote:
Originally Posted by Tee
Посмотреть сообщение
Look at your IsPlayerInRangeOfPoint for both exit commands. They are the same.
It's me, on a different account. But anyways, it's because it's going into the same interior. Just different virtual worlds... I think..
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)