SetCameraFocusX(15);
SetCameraFocusY(0);
SetCameraFocusZ(0);
SetCameraRadius(550);
SetCameraElevationAngle(56);
SetCameraAzimuthAngle(150);
SetCameraPitch(27);
SetCameraRoll(10);
FogBoop;
ascent(let pos in 0..3)
{
	StageBG(pos);
}

task FogBoop{
let radius = 0;
loop(3000){
SetFogParam(0, radius, 0, 0, 0);
radius+=2;;
wait(1);
}
}


task StageBG(pos){
	let position = (pos-1) * 1000;
	let path=GetCurrentScriptDirectory~"img/ReflectionCave.mqo";
	let obj = ObjMesh_Create();
	ObjMesh_Load(obj, path);
	Obj_SetRenderPriorityI(obj, 20);
	let frameInvisible = 0;
	loop{
	if(bspell==true){
	Obj_SetVisible(obj, false);
	}
		Obj_SetVisible(obj, true);
		ObjRender_SetZ(obj, position);
		position++;
		if(position > 1000){position -= 3000;}
		yield;
		}
}