Running timer and timer with offset

Hello all,

I’m trying to set up two timers in that dare feed the time in minutes and seconds from the server.

Basically, I’ve got a master running timer in seconds and minutes but also want to have a second cloned timer that is feed some seconds via flashVars to add to the the master time.

Both of these timers once set by the sever time feed in, and with one being offset, are called every second by a setInterval function call so they count up.

Setting up the master running timer isn’t a problem but with my coding skills is a little messy…

_global.masterRunningTimeInMinutes = 59;
_global.masterRunningTimeInSeconds = 55;

 if (_global.masterRunningTimeInSeconds>0 && _global.masterRunningTimeInSeconds<59) {
 	} else {
 		_global.masterRunningTimeInSeconds = 0;
		if (_global.masterRunningTimeInMinutes>=0 && _global.masterRunningTimeInMinutes<=58) {
		} else if (_global.masterRunningTimeInMinutes>=59 && _global.masterRunningTimeInSeconds>=0) {
 			_global.masterRunningTimeInMinutes = 0;
 	if (_global.masterRunningTimeInSeconds<10) {
		_global.masterRunningTimeInSeconds = &quot;0&quot;+_global.masterRunningTimeInSeconds;

_root.runningTime.text = "v"+_global.masterRunningTimeInMinutes+":"+_global.masterRunningTimeInSeconds;

Ideally I wanted to to get the master running time to display MM:SS so if anyone can help with that that would be great!

I suppose the real problem I’m having is is setting up the pattern for determining the cloned time with the offset.

This is becoming a real headache but if anyone can help I would really appreciate it! Basically I just wanted to have the running time with the cloned time always a certain amount of seconds ahead.

Many thanks, amp3