function OnWarpEnter()
	PlaySound("Sounds/SFX/A_Wind2.ogg",-1)
	SetMarker("Pi Ramses\\Temple U\\Warp_0046.wp",0,0)
	if  DjerStandIn_piU_012 then
		if not DjerBlocking_piU_012 then
			SetMarker("Pi Ramses\\Temple U\\Warp_0015.wp",0,0)
		end
	else
		SetMarker("Pi Ramses\\Temple U\\Warp_0015.wp",0,0)
	end
	if  DjerStandIn_piU_012 then
		if DjerBlocking_piU_012 then
			StartAnimationPart("O1U1",0,60,-1,true)
			SetMarker("O1U1",4,0)
		else
			StartAnimationPart("O1U1",180,210,-1,true)
		end
	end
end

function OnDialogFinished(dialogName)
	if dialogName=="OUVA1233" and DjerBlocking_piU_012  then
		StartAnimationPart("O1U1",120,180,1,true)
		DjerBlocking_piU_012 = false
		 DjerStandIn_piU_012 = false
		SetMarker("Pi Ramses\\Temple U\\Warp_0015.wp",0,0)
	elseif dialogName=="MAIA1230" then
		StartAnimationPart("O1U1",90,110,-1,true)
	elseif dialogName=="MAIA1232" then
		StartAnimationPart("O1U1",90,110,-1,true)
	end
	if dialogName=="OUVA1231"  or dialogName=="OUVA1476" or dialogName=="OUVA1478" then
		StartAnimationPart("O1U1",0,60,-1,true)
	end
	if dialogName=="MAIA1477" or dialogName=="MAIA1477" then
		StartAnimationPart("O1U1",90,110,-1,true)
	end
	if dialogName=="OUVA1480" then
		StartAnimationPart("O1U1",120,180,1,true)
		DjerBlocking_piU_012 = false
		 DjerStandIn_piU_012 = false
		SetMarker("Pi Ramses\\Temple U\\Warp_0015.wp",0,0)
	end
end

function OnAnimationFinished(objectName)
	if objectName=="O1U1" then
		StartAnimationPart("O1U1",180,210,-1,true)
	end
end

function OnWarpLeave()
end

function OnWarpObjectHit(objectName)
	if objectName == "O1U1" then
		SetMarker("O1U1",-1,0)
		if DjerBlocking_piU_012 then
			if MAYA_BEATED then
				StartAnimationPart("O1U1",90,110,-1,true)
				DrawText("OUVA1476","OUVA1476.ogg")
				DrawText("MAIA1477","MAIA1477.ogg")
				DrawText("OUVA1478","OUVA1478.ogg")
				DrawText("MAIA1479","MAIA1479.ogg")
				DrawText("OUVA1480","OUVA1480.ogg")
			else
				--StartAnimationPart("O1U1",116,170,-1,true)
				DrawText("MAIA1230","MAIA1230.ogg")
				DrawText("OUVA1231","OUVA1231.ogg")
				DrawText("MAIA1232","MAIA1232.ogg")
				DrawText("OUVA1233","OUVA1233.ogg")
			end
		end
------------------------------------------------------------
	elseif objectName == "O2T1" then

------------------------------------------------------------
	elseif objectName == "O4t1" then
	end
	if objectName=="3D\\Pi Ramses\\Temple U\\Warp_0046.wp" then
		ChangeWarp(objectName)
        end
	if objectName=="3D\\Pi Ramses\\Temple U\\Warp_0015.wp" then
		if not DjerBlocking_piU_012 then
			ChangeWarp(objectName)
		end
        end
end
