02.11.2013, 17:58
Hello,
I am trying to make a countdown in a textdraw but i havent succeded in doing so, ive tried ****** for help but i found nothing that helped me. so can someone help me make this? it counts down from 1 min.
this is my code so far: (this code works in game so all i need is to display the 1 min countdown for each round in a textdraw "TL"
I am trying to make a countdown in a textdraw but i havent succeded in doing so, ive tried ****** for help but i found nothing that helped me. so can someone help me make this? it counts down from 1 min.
this is my code so far: (this code works in game so all i need is to display the 1 min countdown for each round in a textdraw "TL"
pawn Код:
//TD
new PlayerText:TL[MAX_PLAYERS];
//ROUND CHANGE
new RoundChange;
//ROUND/TIMER
forward StartedNewRound();
forward NewRoundTimer(playerid);
forward CountDown(playerid);
pawn Код:
//this is all under ongamemodeinit
SetTimer("NewRoundTimer",90000,true); //i want this timer displaying in the textdraw TL
//NEW ROUND
public NewRoundTimer(playerid)
{
GameTextForAll("~w~Starting new ~g~round!",4000,3);
SetTimer("StartedNewRound",4000,false);
TogglePlayerControllable(playerid,0);
return 1;
}
public StartedNewRound()
{
for(new i = 0; i < MAX_PLAYERS; i++) {
SpawnPlayer ( i ) ;
switch ( RoundChange ) {
case 0:
{
GameTextForAll("~r~Survive!",3000,3);
}
}
}
return 1;
}