[Ajuda] Compila mais n vai
#1

Bom queria saber se essas coordenadas estгo corretas

pawn Код:
stock IsPlayerInFavela(playerid)
    {
    new Float:x,Float:y,Float:z;
    GetPlayerPos(playerid, x, y, z);
    if(x >= 2031.5837 && y >= -944.6428 && x <= 2236.0325 && y <= -967.2399) return 1;
    else return 0;
    }
Cordenadas
AddPlayerClass(285,2031.5837,-944.6428,46.9143,70.6536,0,0,0,0,0,0); // esquedo baixo
AddPlayerClass(285,2236.0325,-1063.3468,62.1875,235.0894,0,0,0,0,0,0); // direito cima


OBS CRIAЗГO GZ FAVELA
Reply
#2

Fera usa essa stock:

pawn Код:
stock IsPlayerInPlace(playerid,Float:XMin,Float:YMin,Float:XMax,Float:YMax )
{
    new RetValue = 0;
    new Float:X,Float:Y,Float:Z;
    GetPlayerPos(playerid,X,Y,Z );
    if( X >= XMin && Y >= YMin && X < XMax && Y < YMax )
    {
      RetValue = 1;
    }
    return RetValue;
}
e depois usa assim:
pawn Код:
if (IsPlayerInPlace(playerid, 2031.5837, -944.6428, 2236.0325, -967.2399))
Reply
#3

N cara tem q ter as coord certas
Reply
#4

Quote:
Originally Posted by Caio_loco
Посмотреть сообщение
N cara tem q ter as coord certas
Sim, as coordenadas й com vocк.
Reply
#5

mas se eu fazer assim tenho que mudar o gm todo
Reply
#6

Nгo, й sу tirar essa linha:
pawn Код:
if(x >= 2031.5837 && y >= -944.6428 && x <= 2236.0325 && y <= -967.2399) return 1;
e colocar essa:
pawn Код:
if (IsPlayerInPlace(playerid, 2031.5837, -944.6428, 2236.0325, -967.2399))
Com as coordenadas certas.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)