Hello, im trying to make a script that whenever a player collides with a part. It will make the player move to a specific part with an offset before teleporting them (sort of like a cutscene i guess). Which is mostly working but the issue is that the player can simply disrupt the :MoveTo() by using their movement keys. Is there a way to stop the player being able to move for a moment but still being able to use :MoveTo()
(the script im using to teleport is a server script, Would i have to use remoteevents to do it or is there a way i can do it through the server?)
local Players = game:GetService("Players")
local localPlayer = Players.LocalPlayer
local PlayerScripts = localPlayer:WaitForChild("PlayerScripts")
local PlayerModule = require(PlayerScripts:WaitForChild("PlayerModule"))
local Controls = PlayerModule:GetControls()
Controls:Disable()
task.wait(5)
local character = localPlayer.Character
character.Humanoid:MoveTo(Vector3.new(10000,0,0))