I was thinking a while true like
While true do
wait(Introgui)
game.Workspace.Music:Play()
I was thinking a while true like
While true do
wait(Introgui)
game.Workspace.Music:Play()
We spoke in chat and you told me that the GUI is only visible for 20 seconds. So this script will prevent a player from moving (They can still jump) for 20 seconds...
game.Players.PlayerAdded:connect(function(plr)
plr.CharacterAdded:connect(function(character)
wait(.2)
local hoid = character:WaitForChild("Humanoid")
hoid.WalkSpeed = 0
wait(20)
hoid.WalkSpeed = 16
end)
end)
It should be a normal script inside of Workshop. If this helps please accept my answer, and if you have any questions please do ask :)
EDIT: The problem was the humanoid had not yet loaded while the script was trying to run. You could either add a small wait() at the start but could still run the risk of it not loading in time so this way is a much safer method.
This discussion is preserved as it was. New answers, comments, and votes are closed.
3 comments
It only works on roblox studio.
Ah sorry. I guess it's because the script is trying to run but the player's humanoid hasn't yet loaded. Answer edited :)
Everytime I die it redoes this process is there a way to make it do this script once when a player enters?