Hello,
Using the below timer function(total time to play the game), i want to make the graphical representation of the time i.e., As the time decreases the graph has to come down(decrease). How can i link timer to the graph.
thanks for any help.
Timer(code):
------------
text time_txt{
Code:
}
var seconds = 60; // number of seconds to be counted down
var temp_seconds;
function c_d()
{
time_txt.visible = on;
while(seconds > 0)
{
sleep (1);
seconds -= 1;
temp = int(seconds / 60); // compute the number of minutes
str_for_num(time_str, temp);
str_cat (time_str, " : ");
temp_seconds = seconds - temp * 60; // compute the remainder (the number of seconds)
str_for_num(temp_str, temp_seconds);
if (temp_seconds < 10)
{
str_cat (time_str, "0"); // add a zero (if needed)
}
str_cat (time_str, temp_str);
}