[Ajuda] Interiores
#1

Pessoal, eu queria colocar vбrios interiores iguais para entradas e saidas diferentes, quando eu digito o comando de entrar ele entra certinho e com vw diferente. Quando eu digito o comando de sair, ele sai sempre no mesmo local.... o que tenho que fazer para mover a pessoa para o mesmo interior, sem elas se verem e movendo para saidas em locais diferentes?
Reply
#2

Posta o comando de entrar e sair dos interiores...
Reply
#3

Tem que mudar o VW de saida tbb, eu acho.
Reply
#4

pawn Код:
if(strcmp(cmd, "/dpsair", true) == 0)
    {
        if(IsAPDMember(playerid) || IsAFreecop(playerid))
        {

// Police Station Ganton

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 0);
            SetPlayerPos(playerid,2495.83032227,-1759.26220703,13.19610023);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
// Police Station El Corona

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 0);
            SetPlayerPos(playerid,1935.74462891,-2086.46948242,13.22142220);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station East Los Santos

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 0);
            SetPlayerPos(playerid,2522.33886719,-1343.66760254,30.47849655);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Rodeo

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 0);
            SetPlayerPos(playerid,617.58319092,-1330.05078125,13.29710579);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Verona Beach

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 0);
            SetPlayerPos(playerid,1026.92041016,-1582.93005371,13.19610023);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }


        }
    }

    if(strcmp(cmd, "/dpentrar", true) == 0)
    {
        if(IsAPDMember(playerid) || IsAFreecop(playerid))
        {



// Police Station Ganton

           if(IsPlayerInRangeOfPoint(playerid,3.0,2495.83032227,-1759.26220703,13.19610023))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 2);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
// Police Station El Corona

           if(IsPlayerInRangeOfPoint(playerid,3.0,1935.74462891,-2086.46948242,13.22142220))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 3);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
           
// Police Station East Los Santos

           if(IsPlayerInRangeOfPoint(playerid,3.0,2522.33886719,-1343.66760254,30.47849655))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 4);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Rodeo

           if(IsPlayerInRangeOfPoint(playerid,3.0,617.58319092,-1330.05078125,13.29710579))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 5);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
           
// Police Station Verona Beach

           if(IsPlayerInRangeOfPoint(playerid,3.0,1026.92041016,-1582.93005371,13.19610023))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 6);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }



        }
    }
Reply
#5

Tente ai :
pawn Код:
if(strcmp(cmd, "/dpsair", true) == 0)
    {
        if(IsAPDMember(playerid) || IsAFreecop(playerid))
        {

// Police Station Ganton

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 2);
            SetPlayerPos(playerid,2495.83032227,-1759.26220703,13.19610023);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
// Police Station El Corona

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 3);
            SetPlayerPos(playerid,1935.74462891,-2086.46948242,13.22142220);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station East Los Santos

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 4);
            SetPlayerPos(playerid,2522.33886719,-1343.66760254,30.47849655);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Rodeo

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 5);
            SetPlayerPos(playerid,617.58319092,-1330.05078125,13.29710579);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Verona Beach

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 6);
            SetPlayerPos(playerid,1026.92041016,-1582.93005371,13.19610023);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }


        }
    }
 if(strcmp(cmd, "/dpentrar", true) == 0)
    {
        if(IsAPDMember(playerid) || IsAFreecop(playerid))
        {



// Police Station Ganton

           if(IsPlayerInRangeOfPoint(playerid,3.0,2495.83032227,-1759.26220703,13.19610023))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 2);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
// Police Station El Corona

           if(IsPlayerInRangeOfPoint(playerid,3.0,1935.74462891,-2086.46948242,13.22142220))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 3);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
           
// Police Station East Los Santos

           if(IsPlayerInRangeOfPoint(playerid,3.0,2522.33886719,-1343.66760254,30.47849655))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 4);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Rodeo

           if(IsPlayerInRangeOfPoint(playerid,3.0,617.58319092,-1330.05078125,13.29710579))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 5);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
           
// Police Station Verona Beach

           if(IsPlayerInRangeOfPoint(playerid,3.0,1026.92041016,-1582.93005371,13.19610023))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 6);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }



        }
    }
ai fala o que deu
Reply
#6

pawn Код:
SetPlayerVirtualWorld(playerid, World); // Mude o World pra o nъmero que deseja setar o Virtual World dele.
https://sampwiki.blast.hk/wiki/SetPlayerVirtualWorld
Reply
#7

Quote:
Originally Posted by Shickcard
Посмотреть сообщение
pawn Код:
SetPlayerVirtualWorld(playerid, World); // Mude o World pra o nъmero que deseja setar o Virtual World dele.
https://sampwiki.blast.hk/wiki/SetPlayerVirtualWorld
Jб estou usando isso :S o problema й ao digitar /sair

Quote:
Originally Posted by Gabriel Duarte
Посмотреть сообщение
Tente ai :
pawn Код:
if(strcmp(cmd, "/dpsair", true) == 0)
    {
        if(IsAPDMember(playerid) || IsAFreecop(playerid))
        {

// Police Station Ganton

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 2);
            SetPlayerPos(playerid,2495.83032227,-1759.26220703,13.19610023);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
// Police Station El Corona

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 3);
            SetPlayerPos(playerid,1935.74462891,-2086.46948242,13.22142220);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station East Los Santos

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 4);
            SetPlayerPos(playerid,2522.33886719,-1343.66760254,30.47849655);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Rodeo

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 5);
            SetPlayerPos(playerid,617.58319092,-1330.05078125,13.29710579);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Verona Beach

           if(IsPlayerInRangeOfPoint(playerid,3.0,322.197998,302.497985,999.148437))
           {
            SetPlayerInterior(playerid,0);
            SetPlayerVirtualWorld(playerid, 6);
            SetPlayerPos(playerid,1026.92041016,-1582.93005371,13.19610023);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }


        }
    }
 if(strcmp(cmd, "/dpentrar", true) == 0)
    {
        if(IsAPDMember(playerid) || IsAFreecop(playerid))
        {



// Police Station Ganton

           if(IsPlayerInRangeOfPoint(playerid,3.0,2495.83032227,-1759.26220703,13.19610023))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 2);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
// Police Station El Corona

           if(IsPlayerInRangeOfPoint(playerid,3.0,1935.74462891,-2086.46948242,13.22142220))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 3);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
           
// Police Station East Los Santos

           if(IsPlayerInRangeOfPoint(playerid,3.0,2522.33886719,-1343.66760254,30.47849655))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 4);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }

// Police Station Rodeo

           if(IsPlayerInRangeOfPoint(playerid,3.0,617.58319092,-1330.05078125,13.29710579))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 5);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }
           
// Police Station Verona Beach

           if(IsPlayerInRangeOfPoint(playerid,3.0,1026.92041016,-1582.93005371,13.19610023))
           {
            SetPlayerInterior(playerid,5);
            SetPlayerVirtualWorld(playerid, 6);
            SetPlayerPos(playerid,322.197998,302.497985,999.148437);
            GameTextForPlayer(playerid, "~w~Police Station", 5000, 1);
            return 1;
            }



        }
    }
ai fala o que deu
Nгo funcionou :S eu continuo saindo em outro local :S
Reply
#8

Alguem pode me ajudar?
Reply
#9

Quando ele sair seta o virtual world dele pra 0.
Reply
#10

vc faz uma variavel pra ve onde ele entrou, exemplo:
pawn Код:
new entrou[MAX_PLAYERS];
ai la no comando entrar vamo super que ele entro no lugar 1 ai seta junto no comando
pawn Код:
entrou[playerid] = 1;
ai na hora do /sair

usa

pawn Код:
if(entrou[playerid] == 1)
{
SETA A POSIЗГO DO LUGAR 1
}
else if(entrou[playerid] == 2)
{
SETA A POSIЗГO DO LUGAR 2
}
e assim vai
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)