PDA

View Full Version : i need help ( ZOmbie Apocalypse Script)


ReD_HunTeR
12/11/2013, 03:04 PM
in Zombie Apocalypse Script, the count took much time to get another word EX: 20(after 10 sec) 15 ....
I need someone to help me with it and it must be fast like 20 19 18 (takes only one sec init).. if anyone can help ill rep+

Nourdin
12/11/2013, 03:09 PM
Can you send me the piece of code that is stated in your script? (Only the timer + the count script)

I'll try something out.

ReD_HunTeR
12/11/2013, 03:51 PM
i'm just noob scripter so if you want full gamemode here (http://forum.sa-mp.com/showthread.php?t=389797) you go, Common help me asap

ReD_HunTeR
12/11/2013, 04:51 PM
Ok HEre you go,
function OnMapUpdate()
{
time -= 8;

new str[64];
format(str,sizeof(str),"%d",time);
TextDrawSetString(TimeLeft,str);

if(time <= 0) TextDrawSetString(TimeLeft," ..."),KillTimer(mapvar),KillTimer(balvar),SetTimer("ShowCheckpoint",MAX_SHOW_CP_TIME,false);
return 1;
}


function OnMapBalance()
{
if(playerOnline >= 2)
{
if(GetTeamPlayersAlive(TEAM_HUMAN) == 0)
{
KillTimer(balvar);
KillTimer(mapvar);
TextDrawSetString(TimeLeft,"~r~Zombies win");
SetTimer("EndMap",4000,false); // Cannot use MAX_END_TIME Because of MAX_END_TIME is set to 1 minute not 4 seconds *NOTE TO ME*
foreach(Player,i)
{
if(team[i] == TEAM_ZOMBIE)
{
pInfo[i][pXP] += 30;
GivePlayerXP(i,30);
}
}
}
}
return 1;
}

TimeLeft = TextDrawCreate(22.000000, 251.000000, "240");
TextDrawBackgroundColor(TimeLeft,0x00ff0066);
TextDrawLetterSize(TimeLeft,1.000000,3.300000);
TextDrawFont(TimeLeft,3);


this code if found as " TimeLeft " i need to make it faster..