15.05.2014, 15:28
PHP код:
enum player_info
{
objid[sizeof(Objects)],
bool:view[sizeof(Objects)]
}
new Player[MAX_PLAYERS][player_info];
bool:IsInReach(Float:x,Float:y,Float:z,Float:x2,Float:y2,Float:z2,Float:dist)
{
x = (x > x2) ? x - x2 : x2 - x;
if(x > dist) return false;
y = (y > y2) ? y - y2 : y2 - y;
if(y > dist) return false;
z = (z > z2) ? z - z2 : z2 - z;
if(z > dist) return false;
return true;
}
new timer;