var movTimer;
var movIndex=0;
var movObj = new Object();
var changeVar;
function MoveObject(start, change, duration, transType, target)
	{
	movObj.Begin=start;
	movObj.Change=change;
	movObj.Duration=duration;
	changeVar = target;
	movObj.transType = transType;
	movIndex=0;
	clearInterval(movTimer);
	movTimer = setInterval("TransitionValue()", 50);
	}
function TransitionValue()
	{
	switch (movObj.transType)
		{
		case "easeInStrong":
			changeVar.top = easeInStrong(movIndex, movObj.Begin, movObj.Change, movObj.Duration)+"px";
			break;
		case "easeOutStrong":
			changeVar.top = easeOutStrong(movIndex, movObj.Begin, movObj.Change, movObj.Duration)+"px";
			break;
		case "easeInOutStrong":
			changeVar.top = easeInOutStrong(movIndex, movObj.Begin, movObj.Change, movObj.Duration)+"px";
			break;
		case "easeInRegular":
			changeVar.top = easeInRegular(movIndex, movObj.Begin, movObj.Change, movObj.Duration)+"px";
			break;
		case "easeOutRegular":
			changeVar.top = easeOutRegular(movIndex, movObj.Begin, movObj.Change, movObj.Duration)+"px";
			break;
		case "easeInOutRegular":
			changeVar.top = easeInOutRegular(movIndex, movObj.Begin, movObj.Change, movObj.Duration)+"px";
			break;
		case "easeNone":
			changeVar.top = easeNone(movIndex, movObj.Begin, movObj.Change, movObj.Duration)+"px";
			break;
		}
	movIndex+=50;
	if (movIndex >= movObj.Duration) clearInterval(movTimer);
	}
// Transition Functions
// @param t Specifies the current time, between 0 and duration inclusive.
// @param b Specifies the initial value of the animation property.
// @param c Specifies the total change in the animation property.
// @param d Specifies the duration of the motion.

//Strong
	function easeInStrong(t, b, c, d)	{return c * (t /= d) * t * t * t * t + b;}
	function easeOutStrong(t, b, c, d) {return c * ((t = t / d - 1) * t * t * t * t + 1) + b;}
	function easeInOutStrong(t, b, c, d)
		{
		if ((t /= d / 2) < 1)	return c / 2 * t * t * t * t * t + b;
		return c / 2 * ((t -= 2) * t * t * t * t + 2) + b;
		}
//Regular
	function easeInRegular(t, b, c, d) {return c * (t /= d) * t + b;}
	function easeOutRegular(t, b, c, d)	{return -c * (t /= d) * (t - 2) + b;}
	function easeInOutRegular(t, b, c, d)	
		{
		if ((t /= d / 2) < 1)	return c / 2 * t * t + b;
		return -c / 2 * ((--t) * (t - 2) - 1) + b;
		}
//None
	function easeNone(t, b, c, d) {return c * t / d + b;}
