Hello all,
I’m trying to create an elevator for my game, but I’m not sure how to prevent players from clipping through the floor when the TweenService animation plays. (To clarify, I used the TweenService animator plugin.)
I would like to know if there is a way to anchor the player to the part (it is named “Elevator” so the player doesn’t clip, and the script executes the rest of itself before eventually un-anchoring the player.
animator = require(script.Parent.Elevator.Animator)
script.Parent.Button.ClickDetector.MouseClick:Connect(function()
script.Parent.Button.ClickDetector.MaxActivationDistance = 0
wait(0.1)
script.Parent.Elevator.ElevatorWhirr:Play()
wait(0.1)
animator.ElevatorDown:Play()
wait(10)
script.Parent.Elevator.ElevatorWhirr:Play()
wait(0.1)
animator.ElevatorUp:Play()
script.Parent.Button.ClickDetector.MaxActivationDistance = 32
end)
I’m not 100% sure what to do, as I’m still learning. Can someone give me any pointers on what I can do here?