function mini_create ()
	init_mini(1);
	create_mini(19,64,30,170,80,754,664,1,2,10,0,-1);
	--create_mini(8128);
end;
-- mini_start=false
canmenu=false
flag = true;

OpenPlushes();

function gameinput (sender,id,attachedID)
MiniInterfaceHandler( sender, id );
	if sender == 33 then	
		CreateWindow(CWX,CWY,"666",242,nil,100,230);			
	return; end;
if sender==26 then
RemoveWindow(8,2.8,"DestroyMyWindow")
end
if sender==777 and flags.mini_complete then
clear_satelite_leaf("lava");	
end



	if sender == 30 then
	if mini_start then
			StopAllEffects()
			StopMusic()
			setstatemenu()
			mini_start=false;
	return;end
		BlockCursor(false)
		flags.start_draw = false;
		SetCurrentLeaf("lava",22,0);	
			ReturnHiddenObjects()      
			DeleteRenderTarget(2234)  
			DeleteRenderTarget(2235) 
			leafobj={}	
		OpenPlushes()
			
				set_visible_object(10,false);
				set_visible_object(1000,false);
				set_visible_object(77,false);
				set_visible_object(7,false);	
	return; end;
	
	
	
	if sender==10 then	
	mini_start=false;	
		speciale_action(2,obj.lavaFlow.id,true);
		StartAnimation(obj.lavaFlow.id);
		AlternateTimer("ff",3000);
		playeffect("116")
		flags.mini_complete=true
		BlockCursor(true)
	return; end;
	
	
	if sender==1 then
		MiniInterfaceHandler( sender, id );
		if id > 0 and id < 65 then
			check_mini_game_puzzle(id,7);	
			playeffect("138")
		end;		
	return; end;	
end;

function ff()
	flags.mini1 = true;
	leafobj={2235}
	GetRenderTarget(2235,"rendertar1");	
		function rendertar1(tex_name,tex_id)
			FlipVertical(2235);
			SetAlfa(2235,0,1,0,"vasea3353523")
			SetObjectPosition(2235,0,-256);
			LeaveObjectsOnReder("leafobj");
			ClosePlushes();	
		
		return end
	plushes_were_closed = true;
return;end