enum pTeams { TEAM_POLICE, TEAM_SWAT, TEAM_ARMY, TEAM_AMCSI, TEAM_COLUMBIANO, TEAM_KINA, TEAM_TERRO }; new teamScore[MAX_PLAYERS][pTeams]; |
for(new i=0, m=GetMaxPlayers(); i<m; i++)//for(new i=0, m=GetMaxPlayers(); i<m; i++) { if(gTeam[playerid] == TEAM_POLICE) { teamScore[i][TEAM_POLICE]++; if(teamScore[i][TEAM_POLICE] >= 50) { GameTextForAll("~w~Corleones Won",5000,0); SetTimer("EndGM", 10000,0); } } if(gTeam[playerid] == TEAM_SWAT) { teamScore[i][TEAM_POLICE]++; if(teamScore[i][TEAM_POLICE] >= 50) { GameTextForAll("~w~Corleones Won",5000,0); SetTimer("EndGM", 10000,0); } } if(gTeam[playerid] == TEAM_ARMY) { teamScore[i][TEAM_ARMY]++; if(teamScore[i][TEAM_ARMY] >= 50) { GameTextForAll("~w~Corleones Won",5000,0); SetTimer("EndGM", 10000,0); } } if(gTeam[playerid] == TEAM_AMCSI) { teamScore[i][TEAM_AMCSI]++; if(teamScore[i][TEAM_AMCSI] >= 50) { GameTextForAll("~w~Corleones Won",5000,0); SetTimer("EndGM", 10000,0); } } if(gTeam[playerid] == TEAM_COLUMBIANO) { teamScore[i][TEAM_COLUMBIANO]++; if(teamScore[i][TEAM_COLUMBIANO] >= 50) { GameTextForAll("~w~Corleones Won",5000,0); SetTimer("EndGM", 10000,0); } } if(gTeam[playerid] == TEAM_TERRO) { teamScore[i][TEAM_TERRO]++; if(teamScore[i][TEAM_TERRO] >= 50) { GameTextForAll("~w~Corleones Won",5000,0); SetTimer("EndGM", 10000,0); } } if(gTeam[playerid] == TEAM_KINA) { teamScore[i][TEAM_KINA]++; if(teamScore[i][TEAM_KINA] >= 50) { GameTextForAll("~w~Corleones Won",5000,0); SetTimer("EndGM", 10000,0); } } } |
D:\LETONAK2\gamemodes\Gang-Wars.pwn(890) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(891) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(899) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(900) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(90 : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(909) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(917) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(91 : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(926) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(927) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(935) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(935) : error 032: array index out of bounds (variable "teamScore") D:\LETONAK2\gamemodes\Gang-Wars.pwn(936) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(936) : error 032: array index out of bounds (variable "teamScore") D:\LETONAK2\gamemodes\Gang-Wars.pwn(944) : warning 213: tag mismatch D:\LETONAK2\gamemodes\Gang-Wars.pwn(945) : warning 213: tag mismatch |
static gTeam[MAX_PLAYERS]; new gPlayerClass[MAX_PLAYERS]; |
/ Teams #define TEAM_POLICE 1 #define TEAM_SWAT 2 #define TEAM_ARMY 3 #define TEAM_AMCSI 4 #define TEAM_COLUMBIANO 5 #define TEAM_KINA 6 #define TEAM_TERRO 7 |
enum pTeams
{
TEAM_POLICE,
TEAM_SWAT,
TEAM_ARMY,
TEAM_AMCSI,
TEAM_COLUMBIANO,
TEAM_KINA,
TEAM_TERRO
};
new teamScore[pTeams];
if(gTeam[playerid] == TEAM_POLICE)
{
teamScore[TEAM_POLICE]++;
if(teamScore[TEAM_POLICE] >= 50)
{
GameTextForAll("~w~Corleones Won",5000,0);
SetTimer("EndGM", 10000,0);
}
}
//and so on...