local U=game.Players.LocalPlayer local H=U.Character;(H:WaitForChild("\072\117\109\097\110\111\105\100")).Died:Connect(function()wait()script.Parent.BackgroundTransparency=0 U.CameraMode=0 U.CameraMaxZoomDistance=3 U.CameraMinZoomDistance=3 wait(1)script.Parent.Deathsound:Play()wait(1)script.Parent.Visible=true U.CameraMaxZoomDistance=.5 U.CameraMinZoomDistance=.5 U.CameraMode=1 wait(3)script.Parent.BackgroundTransparency=.1 wait(.3)script.Parent.BackgroundTransparency=.2 wait(.3)script.Parent.BackgroundTransparency=.3 wait(.2)script.Parent.BackgroundTransparency=.4 wait(.2)script.Parent.BackgroundTransparency=.6 wait(.1)script.Parent.BackgroundTransparency=.8 wait(.1)script.Parent.BackgroundTransparency=1 script.Parent.Visible=false end)


local player = game.Players.LocalPlayer
local char = player.Character
char:WaitForChild("Humanoid").Died:Connect(function() --check if player got oofed
	wait()
	script.Parent.BackgroundTransparency = 0 -- make it not transparent(just to be 100% sure it will be visible after)
	player.CameraMode = 0 -- set third person
	player.CameraMaxZoomDistance = 3 -- lock the camera zoom
    player.CameraMinZoomDistance = 3
	wait(1)
	script.Parent.Deathsound:Play() -- play the sound
	wait(1)
	script.Parent.Visible = true -- make screen go black xd
	player.CameraMaxZoomDistance = 0.5 --reset the zoom
	player.CameraMinZoomDistance = 0.5
	player.CameraMode = 1 -- set first person
	wait(3) -- screen fade out UwU
	script.Parent.BackgroundTransparency = 0.1
	wait(0.3)
	script.Parent.BackgroundTransparency = 0.2
	wait(0.3)
	script.Parent.BackgroundTransparency = 0.3
	wait(0.2)
	script.Parent.BackgroundTransparency = 0.4
	wait(0.2)
	script.Parent.BackgroundTransparency = 0.6
	wait(0.1)
	script.Parent.BackgroundTransparency = 0.8
	wait(0.1)
	script.Parent.BackgroundTransparency = 1
	script.Parent.Visible = false -- make it invisible(just to be sure again)
end)
