Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Local script in starter GUI doesn’t make loading screen appear?

Asked by
Nozazxe 107
4 years ago

So I have a loading screen that appears when a player joins. For now I’m just making it stay on the screen so I can see if it appears when I join. But it doesn’t. Here’s the script.

1game.Players.PlayerAdded:Connect(function(player)
2player.PlayerGui.Loading.Enabled = true
3end)

2 answers

Log in to vote
1
Answered by 4 years ago

Try removing line 1 and line 3, 'PlayerAdded' has never worked for me, and instead, just let the script run whenever it's ready (which is when you start the game). Instead, add a variable at the start of the script saying: player = game.Players.LocalPlayer; so that the script looks more like this:

1local player = game.Players.LocalPlayer
2 
3player.PlayerGui.Loading.Enabled = true
0
Damn, my grammar stopped for a sec. ROOBLOXJakob123 22 — 4y
0
Thank you. Nozazxe 107 — 4y
Ad
Log in to vote
0
Answered by 4 years ago
Edited 4 years ago

You can make an easier Loading screen. You can make a screengui (and frame) and put this localscript: EDIT: Forgot to change the speed and jump power back xD

1local h = character:WaitForChild("Humanoid")
2h.jumpPower = 0 -- sets the jump power to 0 so the character can't jump
3h.WalkSpeed = 0-- sets the speed to 0 so the character can't move
4wait(7) -- wait 7 seconds
5h.JumpPower = 50 -- considering you use the default jump power
6h.WalkSpeed = 16 -- considering you use the default speed
7script.Parent.Frame.Visible = false -- after 7 seconds, remove the loading screen

you should estimate the seconds you have to wait by how big the game is (is it a big game or is it something like a small project?)

let me know if there are any problems!

0
i need it to be disabled so i can see my other GUI, so i need a script that enables it on join. Also, I use "repeat wait(3) until game:IsLoaded()", so i dont need to calculate the wait time. Nozazxe 107 — 4y
0
oh, sorry. qMrSpooky 20 — 4y

Answer this question