Ad
Still have questions? Join our Discord server and get real time help.
Log in to vote
-2

How To Teleport A player After Humanoid Clicked "Enter Game" Button In Gui?

Asked by 6 years ago

Here is What I have for When You Enter Game Menu Pops Up

script.Parent.AncestryChanged:connect(function () if script.Parent.Parent ~= game.Workspace.GameStart then for i = 1, 125 do -- 125 to make sure it covers the whole screen (needed if you have weapons or tools) otherwise 100 is fine. script.Parent.FrameBlackout.Size = script.Parent.FrameBlackout.Size + UDim2.new(0.01,0,0.01,0) wait() end script.Parent.FrameMain.Visible = true child = script.Parent.FrameMain:GetChildren() for i = 1,#child do child[i].Visible = true wait(0.25) end end end)

This is What have when He presses enter Game

script.Parent.AncestryChanged:connect(function () if script.Parent.Parent ~= game.Workspace.GameStart then for i = 1, 125 do -- 125 to make sure it covers the whole screen (needed if you have weapons or tools) otherwise 100 is fine. script.Parent.FrameBlackout.Size = script.Parent.FrameBlackout.Size + UDim2.new(0.01,0,0.01,0) wait() end script.Parent.FrameMain.Visible = true child = script.Parent.FrameMain:GetChildren() for i = 1,#child do child[i].Visible = true wait(0.25) end end end)

1 answer

Log in to vote
0
Answered by
drahsid5 250 Moderation Voter
6 years ago

Why're you using UDim2 to teleport a player? Use CFrame or :MoveTo()

Ad

Answer this question