Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //no topo:
- new gzplayer[MAX_GZS+1];
- //public
- public ZoneCheckpointChecker()
- {
- for(new i; i < MAX_PLAYERS; i++)
- {
- if(!IsPlayerConnected(i))continue;
- if(CPS_GetPlayerCheckpoint(i) > 0 && CPS_GetPlayerCheckpoint(i) <= 50 &&
- CoresDasGangZones[CPS_GetPlayerCheckpoint(i)-1] != CoresDosSkins[gTeam[i]] && (gzplayer[CPS_GetPlayerCheckpoint(i)-1] == i || !gzatack[GPS_GetPlayerCheckpoint(i)-1]))
- {
- if(CPzone[i][CPS_GetPlayerCheckpoint(i)] < 30)
- {
- if(CPzone[i][CPS_GetPlayerCheckpoint(i)] == 5)
- {
- for(new j; j < MAX_PLAYERS; j++)
- {
- if(gTeam[j] == CPS_GetPlayerCheckpoint(i)-1)GameTextForPlayer(j," ~N~ ~N~ ~N~ ~N~ ~N~ ~N~ ~N~ ~R~Uma area da sua Gang esta sendo atacada!",5000,5);
- }
- }
- CPzone[i][CPS_GetPlayerCheckpoint(i)]++;
- GZatack[CPS_GetPlayerCheckpoint(i)-1] = 1;
- new tmp[10];
- format(tmp,sizeof tmp,"~R~%2d / 30",CPzone[i][CPS_GetPlayerCheckpoint(i)]);
- GameTextForPlayer(i,tmp,1001,4);
- GangZoneFlashForAll(CPS_GetPlayerCheckpoint(i)-1,CoresDosSkins[gTeam[i]]);
- }
- else if(CPzone[i][CPS_GetPlayerCheckpoint(i)] == 30)
- {
- PlayerPlaySound(i,1057,0.0,0.0,0.0);
- GameTextForPlayer(i,"~R~Kill-Kill: ~G~GangZone dominada!",5000,5);
- SendClientMessage(i,RECOMPENSA,"[Kill-Kill RECOMPENSA]: Voc� ganhou 10 Mil por dominar essa GangZone!");
- GivePlayerMoney(i,10000);
- GZatack[CPS_GetPlayerCheckpoint(i)-1] = 0;
- CPzone[i][CPS_GetPlayerCheckpoint(i)] = 0;
- CoresDasGangZones[CPS_GetPlayerCheckpoint(i)-1] = CoresDosSkins[gTeam[i]];
- GangZoneStopFlashForAll(CPS_GetPlayerCheckpoint(i)-1);
- GangZoneHideForAll(CPS_GetPlayerCheckpoint(i)-1);
- GangZoneShowForAll(CPS_GetPlayerCheckpoint(i)-1,CoresDasGangZones[gTeam[i]]);
- new string[256];
- format(string,sizeof string,"[Kill-Kill GANGZONE]: A Gang %s perdeu o territ�rio para a Gang %s!",NomesDasGangs[CPS_GetPlayerCheckpoint(i)-1],NomesDasGangs[gTeam[i]]);
- SendClientMessageToAll(GANGZONE,string);
- }
- }
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment