You can write your topic however you want, but you need to answer these questions:
- I Want to have a working jumpscare animation, the first time getting killed it works perfectly however after that the animation doesnt play, i have the jumpscare on action, ive tried to load the animation in the player dying function and have tried to create a new instance of the animation
here is the script
game.Players.PlayerAdded:Connect(function(Player)
local Camera = workspace.CurrentCamera
local character = Player.Character or Player.CharacterAdded:Wait()
wait(1)
Player.Character:WaitForChild("Humanoid").Died:Connect(function(player)
local attack = Instance.new("Animation")
attack.AnimationId = "rbxassetid://13819115010"
local attackAnim = script.Parent.Animator:LoadAnimation(attack)
attackAnim:Play()
workspace.CurrentCamera.CameraType = Enum.CameraType.Custom
end)
end)