TP Command Problem
#1

Hello, i have a command /loungeenter but everytime i type it, it tp'ing me to the default not in the position i want here's my current code hope you can fix this..

pawn Код:
CMD:loungeenter(playerid, params[])
{
    if(IsPlayerInRangeOfPoint(playerid, 13.0, -4398.9072, 870.9648, 986.3803))
 {
  if(PlayerInfo[playerid][pDonator] >= 0)
  {
                    SetPlayerPos(playerid, -2636.7969,1403.7454,907.6803);
                    TelePos[playerid][0] = 0.0;TelePos[playerid][1] = 0.0;
                    SendClientMessageEx(playerid, COLOR_YELLOW, "VIP: You have entered the the VIP Lounge!");
                    SetPlayerInterior(playerid,0);
                    PlayerInfo[playerid][pInt] = 0;
                    SetPlayerVirtualWorld(playerid, 0);
                    PlayerInfo[playerid][pVW] = 0;
        }
    }
    return 1;
}
I mean if i type /loungeenter it doesn't tp'ing me to the position i want
Reply
#2

You set the interior and virtual work before setting the position.
Reply
#3

Nevermind it i already solve it because -2636.7969,1403.7454,907.6803 this is not a interior 0 that is interior 3 that's why
Reply
#4

Also your code

pawn Код:
if(PlayerInfo[playerid][pDonator] >= 0)
You do realise that'll let anyone inside the VIP lounge right?
Reply
#5

Quote:
Originally Posted by (*|Flake|*)
Посмотреть сообщение
Also your code

pawn Код:
if(PlayerInfo[playerid][pDonator] >= 0)
You do realise that'll let anyone inside the VIP lounge right?
Yes don't mind it.. I have a dynamic door that don't allow not donator to enter.
Reply
#6

Quote:
Originally Posted by ChuckyBabe
Посмотреть сообщение
Yes don't mind it.. I have a dynamic door that don't allow not donator to enter.
Then why even run the check?
Reply
#7

Quote:
Originally Posted by (*|Flake|*)
Посмотреть сообщение
Then why even run the check?
Nothing just want to have a long code


P.S = How to make it for vips 1 up only ?
Reply
#8

you could try if(PlayerInfo[playerid][pDonator] < 1) if it don't work just use if(PlayerInfo[playerid][pDonator] >= 1)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)