SetTimerEx
#1

hi i have a problem.

Код:
GangWarTimer[zone] = SetTimerEx("EndGangWar",GANGWAR_LENGTH,false,"iii",zone, playerGang[killerid], playerGang[playerid],GetPlayerColor(killerid));
i dont can add GetPlayerColor(killerid), i can add but if the gangwar stops, the message comes white, and my color are not white.

my EndGangWar:

Код:
forward EndGangWar(zone, attacker, defender, color);
public EndGangWar(zone, attacker, defender, color)
{
	new str[128];
	if(ZoneInfo[zone][GangWarInProgress] == 1)
	{
		// send the message
		format(str, sizeof(str), "*** GangZone Message: 5 Minuten sind vergangen. %s haben ihre Gangzone von %s verteidigt.", Gangs[ defender ][gName], Gangs[ attacker ][gName] );
	  SendClientMessageToAll(color, str);

		// change the zone colour
		GangZoneStopFlashForAll( zone );
		GangZoneHideForAll( zone );
		GangZoneShowForAll( zone, color );

		// reset the counters
		Gangs[ defender ][UnderAttackCount] = 0;
		Gangs[ attacker ][UnderAttackCount] = 0;
		Gangs[ defender ][DefendCount] = 0;
		ZoneInfo[zone][GangWarInProgress] = 0;
		ZoneInfo[zone][ZoneAttackers] = -1;
	}
}
Reply
#2

pawn Код:
GangWarTimer[zone] = SetTimerEx("EndGangWar",GANGWAR_LENGTH,false,"iii",zone, playerGang[killerid], playerGang[playerid],GetPlayerColor(killerid));
"iii" - That's 3 integers

And you send 4 parameters:
  • zone
  • playerGang[killerid]
  • playerGang[playerid]
  • GetPlayerColor(killerid)
Reply
#3

"iii","iiii"
edit: again for later reply lol
Reply
#4

i've tested with iiii but than the timer dont go anymore
Reply
#5

Quote:
Originally Posted by Ribber
i've tested with iiii but than the timer dont go anymore
That's strange, try "dddd"
Reply
#6

Quote:
Originally Posted by yezizhu
Quote:
Originally Posted by Ribber
i've tested with iiii but than the timer dont go anymore
That's strange, try "dddd"
"i" is same as "d", so problem is not here.
Reply
#7

Quote:

"i" is same as "d", so problem is not here.

But where?
I have no idea why his function doesn't get called.
Reply
#8

lol i do not why, but now its working with iiii.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)