i've gotten inspired by the haunted staircase and the 2nd monster if you look at it behind you you die how can i do this? i dont see any tutorials on youtube
deathPart = part -- Pass there your part, that part if you place cursor on it you will die. local plr = game.Players.LocalPlayer -- define localplayer local mouse = plr:GetMouse() -- get player's mouse while wait() do -- make infinite checking loop if mouse.Target == deathPart then -- if player cursor is placed on deathPart. Make them watch from first person or make invisible or barely visible part across whole area you want them to die when they look there. plr.Character.Humanoid.Health = 0 -- kill player end end
https://developer.roblox.com/en-us/api-reference/function/Camera/WorldToScreenPoint
that one might help, i wont help everything but try to do it