Zdravím.
Potreboval by som pomoc pri tomto skripte:
- Nevypísalo mi to žiadne chyby, ale keď v hre vojdem do tej zóny, tak sa nič nestane...
forward
forward isPlayerInArea();
settimer
SetTimer("isPlayerInArea", 1000, 1);
ongamemodeinit
public OnGameModeInit()
{
zona = GangZoneCreate(-3433.295, 1996.917, -2125.373, 3503.363);
return 1;
}
onplayerspawn
public OnPlayerSpawn(playerid)
{
GangZoneShowForPlayer(playerid, zone, 0x80FF0096);
return 0;
}
isplayerinarea
public isPlayerInArea()
{
new Float:X, Float:Y, Float:Z;
for(new i=0; i < MAX_PLAYERS; i++)
{
GetPlayerPos(i, X, Y, Z);
if (X <= -3433.295 && X >= 1996.917 && Y <= -2125.373 && Y >= 3503.363)
{
SetPlayerHealth(i, 100);
SendClientMessage(i, TEXT);
}
}
}
Ďakujem