16.08.2011, 16:25
HI !
I just made the gangzone script with that tutorial:
https://sampforum.blast.hk/showthread.php?tid=276352
So,I don't know how I can that my factions with id 5,6,12,13,14,15
to be represented by :
I think that here is the problem and here i must to edit something...
Thank you !!
I'm using gTeam[MAX_PLAYERS];
I just made the gangzone script with that tutorial:
https://sampforum.blast.hk/showthread.php?tid=276352
So,I don't know how I can that my factions with id 5,6,12,13,14,15
to be represented by :
Код:
new Teams[] = { TEAM_PATERNO, TEAM_CORLEONE, TEAM_BARZINI, TEAM_TATTAGLIA, TEAM_CUNEO, TEAM_STRACCI, TEAM_RANDOM };
Код:
public ZoneTimer() { for(new i=0; i < sizeof(ZoneInfo); i++) // loop all zones { if(ZoneAttacker[i] != -1) // zone is being attacked { if(GetPlayersInZone(i, ZoneAttacker[i]) >= MIN_MEMBERS_TO_START_WAR) // team has enough members in the zone { ZoneAttackTime[i]++; if(ZoneAttackTime[i] == TAKEOVER_TIME) // zone has been under attack for enough time and attackers take over the zone { GangZoneStopFlashForAll(ZoneID[i]); SendClientMessage(i,COLOR_RED, "Gangzone-ul a fost cucerit !"); ZoneInfo[i][zTeam] = ZoneAttacker[i]; GangZoneShowForAll(ZoneID[i], GetTeamZoneColor(ZoneInfo[i][zTeam])); // update the zone color for new team ZoneAttacker[i] = -1; } } else // attackers failed to take over the zone { GangZoneStopFlashForAll(ZoneID[i]); SendClientMessage(i,COLOR_RED, "Gangzone-ul nu a putut fi cucerit!"); ZoneAttacker[i] = -1; } } else // check if somebody is attacking { for(new t=0; t < sizeof(Teams); t++) // loop all teams { if(Teams[t] != ZoneInfo[i][zTeam] && GetPlayersInZone(i, Teams[t]) >= MIN_MEMBERS_TO_START_WAR) // if there are enough enemies in the zone { ZoneAttacker[i] = Teams[t]; ZoneAttackTime[i] = 0; SendClientMessageToAll(COLOR_RED, "Tocmai a izbucnit un gangwar,asa ca verifica daca este al tau !"); GangZoneFlashForAll(ZoneID[i], GetTeamZoneColor(ZoneAttacker[i])); } } } } }
I'm using gTeam[MAX_PLAYERS];