23.01.2014, 16:25
pawn Код:
stock EstaEnPosicion(playerid){
if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
else if(IsPlayerInRangeOfPoint(playerid, Float:range, Float:x, Float:y, Float:z)) return 1;
//ETC...
return false;
}
pawn Код:
if(EstaEnPosicion(playerid))
{
//TU FUNCION
//ESTA EN LA POSICION
}
else
{
//TU FUNCION
//NO ESTA EN LA POSICION
}