/*
Copyright by Stitz+Betz GmbH, Dortmund 2006
*/
function Starter() {
	
	
	document.getElementById("Side").style.visibility = "hidden";
	document.getElementById("Nrw").style.visibility = "hidden";
	document.getElementById("Nrw_txt").style.visibility = "hidden";
	document.getElementById("Nrw_Imgmap").style.visibility = "hidden";
	document.small_map.src="/img/son/eur-ger-rg.gif";
	
	document.getElementById("Marl").style.visibility = "hidden";
	document.getElementById("GKScholven").style.visibility = "hidden";
	document.getElementById("GKHorst").style.visibility = "hidden";
	document.getElementById("Castrop").style.visibility = "hidden";
	document.getElementById("Dorsten").style.visibility = "hidden";
	
	document.getElementById("Technomarl").style.visibility = "hidden";
	document.getElementById("Dortmund").style.visibility = "hidden";
	//document.getElementById("Bottrop").style.visibility = "hidden";
	
	
	
	document.getElementById("StartMap").style.visibility = "visible";
	document.getElementById("Welcome").style.visibility = "visible";
	
	aktiv = window.setInterval("moveLook()",1);
	}

var PosX = 430;
var PosY = 350;
var a = 1;
var b = 1;

var j = 300;
var k = 50;

var wait = 400;

var stepper1 = 5;

	
var p = 0;
var i = 0;
var stepper2 = 20;
var stepper3 = 5;
var stepper4 = 5;

var MapStX = 200, MapStY = 160, MapStHeight = 475, MapStWidth = 790;

var MapTaX = 806, MapTaY = 160, MapTaHeight = 96, MapTaWidth = 160;

var MapX = MapStX;
var MapY = MapStY;
var MapWidth = MapStWidth;
var MapHeight = MapStHeight;

var WelStX = 430, WelStY = 350, WelStHeight = 50, WelStWidth = 300;
var WelTaX = 806, WelTaY = 256, WelTaHeight = 27, WelTaWidth = 160;

var WelX = WelStX;
var WelY = WelStY;
var WelWidth = WelStWidth;
var WelHeight = WelStHeight;

var GerStX = 460, GerStY = 412, GerStHeight = 2, GerStWidth = 2;
var GerTaX = 250, GerTaY = 155, GerTaHeight = 500, GerTaWidth = 531;

var GerX = GerStX;
var GerY = GerStY;
var GerWidth = GerStWidth;
var GerHeight = GerStHeight;

var Pause=0;

var NrwStX = 350, NrwStY = 302, NrwStHeight = 2, NrwStWidth = 2;
var NrwTaX = 210, NrwTaY = 206, NrwTaHeight = 355, NrwTaWidth = 590;

var NrwX = NrwStX;
var NrwY = NrwStY;
var NrwWidth = NrwStWidth;
var NrwHeight = NrwStHeight;
 
var Nrw1StX = 260, Nrw1StY = 243, Nrw1StHeight = 150, Nrw1StWidth = 214;
var Nrw1TaX = 250, Nrw1TaY = 155, Nrw1TaHeight = 355, Nrw1TaWidth = 590;

var Nrw1X = Nrw1StX;
var Nrw1Y = Nrw1StY;
var Nrw1Width = Nrw1StWidth;
var Nrw1Height = Nrw1StHeight;

var Pause1=0;
var pa = 0;

function moveLook() {
	
	i = i + stepper1;
	// Welcome	
	document.wilkom.width = a + i;
	document.wilkom.height = b + (i*0.16);
	
	document.getElementById("Welcome").style.left = PosX + ((j/2)-(i/2));
	
	if (i>=j && i<=(j+wait))
		{
		
		}
	
	// Walk to side 
	if (i>=(j+wait)) {
		stepper1 = 0;
		
		Steps = (MapTaX-MapStX)/stepper2;

		MapX = MapX + stepper2;
		document.getElementById("StartMap").style.left = MapX;
		
		MapWidth = MapWidth - ((MapStWidth-MapTaWidth)/Steps);
		document.StartMapP.width = MapWidth;
		
		MapHeight = MapHeight - ((MapStHeight-MapTaHeight)/Steps);
		document.StartMapP.height = MapHeight;
		
		WelX = WelX + ((WelTaX-WelStX)/Steps);
		document.getElementById("Welcome").style.left = WelX;
		
		WelY = WelY - ((WelStY-WelTaY)/Steps);
		document.getElementById("Welcome").style.top = WelY;
		
		WelWidth = WelWidth - ((WelStWidth-WelTaWidth)/Steps);
		document.wilkom.width = WelWidth;
		
		WelHeight = WelHeight - ((WelStHeight-WelTaHeight)/Steps);
		document.wilkom.height = WelHeight;
		
		
		if (MapX>=MapTaX) {
			document.getElementById("Side").style.visibility = "visible";
			document.getElementById("StartMap").style.visibility = "hidden";
			document.getElementById("Welcome").style.visibility = "hidden";
			stepper2 = 0;
			Steps = 0;
			
			document.getElementById("Europe").style.visibility = "visible";
			Pause=Pause+1;
			if (Pause>=70)	{
			
			
			
				document.getElementById("Germany").style.visibility = "visible";
				
				Steps3 = (GerTaWidth-GerStWidth)/stepper3;
				
				GerWidth = GerWidth + stepper3;
				GerHeight = GerHeight + ((GerTaHeight-GerStHeight)/Steps3)
				
				GerX = GerX + ((GerTaX-GerStX)/Steps3)
				GerY = GerY + ((GerTaY-GerStY)/Steps3)
				
				document.Germany_im.width = GerWidth;
				document.Germany_im.height =  GerHeight;
				
				
				document.getElementById("Germany").style.left = GerX;
				document.getElementById("Germany").style.top = GerY;
				
				if (GerWidth>GerTaWidth) {
					document.getElementById("Europe").style.visibility = "hidden";
					stepper3=0;
					Pause1=Pause1+1;
					if (Pause1>=10)	{
						
						document.getElementById("Nrw").style.visibility = "visible";
						
						
						Steps4 = (NrwTaWidth-NrwStWidth)/stepper4;
				
						NrwWidth = NrwWidth + stepper4;
						
						
						
						NrwHeight = NrwHeight + ((NrwTaHeight-NrwStHeight)/Steps4);
				
						NrwX = NrwX + ((NrwTaX-NrwStX)/Steps4);
						NrwY = NrwY + ((NrwTaY-NrwStY)/Steps4);
				
						document.Nrw_im.width = NrwWidth;
						document.Nrw_im.height =  NrwHeight;
						
						document.getElementById("Nrw").style.left = NrwX;
						document.getElementById("Nrw").style.top = NrwY;
						
						if (Pause1>=70) {
							document.getElementById("Germany").style.visibility = "hidden";
							
							}
						
						
						if (NrwWidth>NrwTaWidth) {
							document.getElementById("Nrw_txt").style.visibility = "visible";
							document.getElementById("Nrw_Imgmap").style.visibility = "visible";
							document.getElementById("Nrw").style.visibility = "hidden";
							document.small_map.src="/img/son/eur-ger-rg.gif";
							// #######################################################################
							
							document.getElementById("Marl").style.visibility = "visible";
							document.getElementById("GKScholven").style.visibility = "visible";
							document.getElementById("GKHorst").style.visibility = "visible";
							document.getElementById("Castrop").style.visibility = "visible";
							document.getElementById("Dorsten").style.visibility = "visible";
							document.getElementById("Technomarl").style.visibility = "visible";
							document.getElementById("Dortmund").style.visibility = "visible";
							//document.getElementById("Bottrop").style.visibility = "visible";
							
							// #######################################################################
							window.clearInterval(aktiv);
					
							}
						}
					}
				}
			}
		}
	}
