ResetonSpawn in LocalScript

Hello There,

I have this issue in my LocalScript for a loadingscreen and I want it to not Show up when you respawn.


local StarterGui = game:GetService("StarterGui")
local LoadingScreen = game.StarterGui.LocalScript.LoadingScreen
local PlayerGui = game.Players.LocalPlayer:WaitForChild("PlayerGui")

LoadingScreen.Frame.AssetLoaded.Visible = false 
LoadingScreen.Frame.LoadingAssets.Visible = true
game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack , false)
game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.EmotesMenu , false)

game.StarterPlayer.CharacterJumpPower = 0

StarterGui:SetCoreGuiEnabled("Chat", false)
StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.All, false)

LoadingScreen.Frame.LoadingAssets.Visible = false
LoadingScreen.Frame.AssetLoaded.Visible = true
StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.All, true)
LoadingScreen.Frame.AssetLoaded.Visible = true
game.StarterPlayer.CharacterJumpPower = 50
game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack , true)
StarterGui:SetCoreGuiEnabled("Chat", true)


LoadingScreen.ResetOnSpawn = false
script.Disable = true

If There’s Something I have to do then please tell me or please Correct me if there’s something worng with it.

Resetonspawn is at the bottom btw.

There should be a setting in the gui that says resetOnSpawn with a check box.

yeah but When the player respawns the gui still Shows.

Do you want me to Show you a Video Of the Loading screen when you respawn?

To clarify your screen gui, “LoadingScreen”, it should have a check box that says ResetOnSpawn. Uncheck that. When you make a screen gui it defaults to checked.

Oh sorry didn’t see your posts, yes a video would be helpful

1 Like

Okay Give a one min to make the Video

The Check marker is off btw

I know you just took the video, sorry but I jut tested it in studio. Do not change ResetOnSpawn in the script, it does not work in script you need to change the property of the screenGui.

Put the script inside the gui, not the gui in the script.

1 Like

Okay, I’ll try Both and see if it worked.

1 Like

Although it’s not really normal to put guis inside of scripts this has nothing to do with the situation.

Sorry if I came off rude, thanks for your help though. I tested your suggestion in studio and i didn’t see a big difference. Thanks for your help though!

Yeah there’s Nothing Sorry. Should I do events?

Nothing we said helped? You went into the screen gui properties and turned off ResetOnSpawn?

Yes I did and Nothing happened when I changed it.

Hmm, Ok hold on while I try to find a solution

Ok, so @RMofSBI was right, sorry about earlier you need to put the local script inside the screen gui. I don’t know what about it change but it changes for me.