local luaCutscenesUtils = require("#Celeste.Mod.MaxHelpingHand.Module.LuaCutscenesUtils")

function onTalk()
	if getFlag("mewo_whitespace_talkedfourtimes") then
		disableMovement()
		coroutine.yield(luaCutscenesUtils.SayWithDifferentFont("OMORI_GAME", "CBR_WhiteSpace_MewoInt1"))
	else 
		if getFlag("mewo_whitespace_talkedthrice") then
			disableMovement()
			coroutine.yield(luaCutscenesUtils.SayWithDifferentFont("OMORI_GAME", "CBR_WhiteSpace_MewoInt5"))
			setFlag("mewo_whitespace_talkedfourtimes")
		else 
			if getFlag("mewo_whitespace_talkedtwice") then
				disableMovement()
				coroutine.yield(luaCutscenesUtils.SayWithDifferentFont("OMORI_GAME", "CBR_WhiteSpace_MewoInt4"))
				setFlag("mewo_whitespace_talkedthrice")
			else 
			if getFlag("mewo_whitespace_talkedonce") then
				disableMovement()
				coroutine.yield(luaCutscenesUtils.SayWithDifferentFont("OMORI_GAME", "CBR_WhiteSpace_MewoInt3"))
				setFlag("mewo_whitespace_talkedtwice")
			else
				disableMovement()
				coroutine.yield(luaCutscenesUtils.SayWithDifferentFont("OMORI_GAME", "CBR_WhiteSpace_MewoInt2"))
				setFlag("mewo_whitespace_talkedonce")
				end
			end
		end
	end
end

function onEnd(room, wasSkipped)
   enableMovement()
end