19.11.2014, 18:30
It is GangZoneCreate(Float:minx, Float:miny, Float:maxx, Float:maxy) so it should be
For easier usage you should always use the same syntax
And now OnPlayerUpdate
pawn Код:
SafeZone = GangZoneCreate(581.7188, 676.0, 2972.0, 2930.0);
pawn Код:
IsPlayerInArea(playerid, Float: minx, Float: miny, Float: maxx, Float: maxy) {
new
Float: X,
Float: Y
; // a little optimisation
return GetPlayerPos(playerid, X, Y, Float: playerid) && (minx <= X <= maxx) && (miny <= Y <= maxy);
}
pawn Код:
//OnPlayerUpdate
if(IsPlayerInArea(playerid, 581.7188, 676.0, 2972.0, 2930.0)) {
ResetPlayerWeapons(playerid);
}