function thisMovie(movieName) {
  // IE and Netscape refer to the movie object differently.
  // This function returns the appropriate syntax depending on the browser.
  if (navigator.appName.indexOf ("Microsoft") !=-1) {
    return window[movieName]
  }	else {
    return document[movieName]
  }
}

// Checks if movie is completely loaded.
// Returns true if yes, false if no.
function movieIsLoaded (theMovie) {
  if (typeof(theMovie) != "undefined") {
    return theMovie.PercentLoaded() == 100;
  } else {
    return false;
  }
}

var s


function fSetTicker(mv) {
	current_value += difference;
    s = num2currency(current_value/100);
 	if (movieIsLoaded(thisMovie(mv))) {
		thisMovie(mv).SetVariable("/:sDisplay", s);
	} else {
		// nothing else.
	}
	window.setTimeout("fSetTicker('" + mv + "')",1000);
}


// We are also going to do a text based version for the viper lobby.
function fSetViperTicker() {
	var t = document.getElementById("progressiveJackpot").innerHTML;
	
	if(t) {
		if(isNaN(current_value)) { current_value=1000000; }
		current_value += difference;
		s = num2currency(current_value/100);
		
		if ((t != 'undefined') && (t != null)) {
			document.getElementById("progressiveJackpot").innerHTML = 'Jackpots Progressifs: ' + s;
		} else {
			// nothing else.
			document.getElementById("progressiveJackpot").innerHTML = 'Jackpots Progressifs';
		}
		window.setTimeout("fSetViperTicker()",1000);
	}
}

// We are also going to do a text based version for the progressives page.
function fSetProgressiveTicker() {
	var t = document.getElementById("progressiveJackpot").innerHTML;
	if(t) {
		current_value += difference;
		s = num2currency(current_value/100);
		if ((t != 'undefined') && (t != null)) {
			document.getElementById("progressiveJackpot").innerHTML = 'Jackpots Progressifs: ' + s;
		} else {
			// nothing else.
			document.getElementById("progressiveJackpot").innerHTML = 'Jackpots Progressifs';
		}
		
		window.setTimeout("fSetProgressiveTicker()",1000);
	}
}