Код:
else if(OrgID == 3 || OrgID == 27)
{
if(IsPlayerInHidre(playerid))
{
if(Dominando[playerid] == 1)
{
SendClientMessage(playerid, COLOR_GRAD5, "Vocк ja estб dominando um territorio.");
return 1;
}
if(GuerranaHidre == 1)
{
SendClientMessage(playerid, COLOR_GRAD5, "Jб estб tendo uma guerra nesse territorio.");
return 1;
}
GetPlayerName(playerid, playername, MAX_PLAYER_NAME);
format(string, sizeof(string), "%s %s estгo dominando a Hidre!",playername,NomeORGTr(OrgID));
SendClientMessageToAll(OrgCor(OrgID), string);
SendClientMessage(playerid, COLOR_GRAD3, "Fique esperto os Inimigos foram avisados!");
SendClientMessage(playerid, COLOR_GRAD5, "Espere 30 segundos para dominar estб area .");
GangZoneFlashForAll(GZHidre,OrgCor(OrgID));
Dominando[playerid] = 1;
ProvocoHidre[playerid] = 1;
GuerranaHidre = 1;
TempoGuerraHidre = SetTimerEx("GuerraHidre", 30000, 0, "i", playerid);
return 1;
}
else
{
SendClientMessage(playerid, COLOR_GRAD3, "Vocк nгo estб em nenhum territуrio!");
}
}
stock IsPlayerInHidre(playerid)
{
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid, x, y, z);
if(x >= -591.7480 && y >= 1805.1368 && x <= -817.9867 && y <= 2048.1484) return 1;
else return 0;
}
pawn Код:
stock IsPlayerInHidre(playerid) {
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid, x, y, z);
if(x >= -591.7480 && y >= 1805.1368 && x <= -817.9867 && y <= 2048.1484) return 1;
else return 0;
}