16.02.2015, 19:06
A estrutura eu ja fiz, sу que tem um problema e nгo sei como resolve-lo, mesmo eu ja ter dominado o cp, consigo dominar ele novamente. Vou deixar o CODE abaixo
Se tiverem ideia, pra melhorar o code tambem eu agredeзo
pawn Код:
forward bS_DominarTimer(playerid);
public bS_DominarTimer(playerid){
if(IsPlayerInCheckpoint(playerid)){
DominandobS[playerid]++;
new string[100];
new str[103];
format(string, sizeof(string), "~n~~n~~n~~n~~n~~n~~n~~n~~w~Dominando... ~w~%i~b~/~w~20", DominandobS[playerid]);
GameTextForPlayer(playerid, string, 3000, 3);
GangZoneFlashForAll(CPS_GetPlayerCheckpoint(playerid), GetPlayerColor(playerid));
if(DominandobS[playerid] >= 20){
DominandobS[playerid] = 1;
KillTimer(bS_DominandoTimer[playerid]);
format(string, sizeof(string), "~n~~n~~n~~n~~n~~n~~n~~n~~w~Dominado!", DominandobS[playerid]);
GangZoneStopFlashForAll(CPS_GetPlayerCheckpoint(playerid));
GangZoneHideForAll(CPS_GetPlayerCheckpoint(playerid));
GangZoneShowForAll(CPS_GetPlayerCheckpoint(playerid), GetPlayerColor(playerid));
format(str, sizeof(str), "%s dominou mas um territorio de SanFierro Wargrounds", GetName(playerid));
CallRemoteFunction("GivePlayerCash", "ii", playerid, 250);
SendClientMessageToAll(cinza,str);
GameTextForPlayer(playerid, string, 5000, 3);
return 1;}