function fx_zoom_init( time, extraArguments )
{
	document.fx_zoom_imagesCount	= 5
	var
		buildingsHandle = document.createElement( 'DIV' )

	buildingsHandle.id = "zoom"
	buildingsHandle.style.display = "none"
	buildingsHandle.innerHTML = "<img id='zoom0' /><img id='zoom1' />"
	additionalNodesHandle.appendChild( buildingsHandle )

	for( var i=0; i<document.fx_zoom_imagesCount; i++ )
		imagesToPreloadArray.push( "zoom"+ i +".gif" )
	preloadImages()

	progressBarIndex++
}


function fx_zoom_update( time, extraArguments )
{
	var
		timeRatio		= (time/2048)%document.fx_zoom_imagesCount
		imageBase		= Math.floor( timeRatio )
		zoomRatio		= timeRatio-imageBase

	document.getElementById('zoom').style.display = ""

	scale = .25+zoomRatio*.75
	with( document.getElementById('zoom1') )
	{
		newSrc	= imagesPreloaded["zoom"+((imageBase+1)%document.fx_zoom_imagesCount)+".gif"].src
		if( src!=newSrc )
			src = newSrc
		with( style )						// yeah! ^__^
		{
			width	= 64*scale+"em"
			height	= 48*scale+"em"
			top		= 32-32*scale+"em"
			left	= 24-24*scale+"em"
			opacity = zoomRatio
		}
	}

	scale = 1+zoomRatio
	with( document.getElementById('zoom0') )
	{
		newSrc	= imagesPreloaded["zoom"+imageBase+".gif"].src
		if( src!=newSrc )
			src = newSrc
		with( style )						// yeah! ^__^
		{
			width	= 64*scale+"em"
			height	= 48*scale+"em"
			top		= 32-32*scale+"em"
			left	= 24-24*scale+"em"
		}
	}


}


function fx_zoom_destroy()
{
	document.getElementById('zoom').style.display = "none"
}

