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

How to stop a Gui from resetting when a Player dies?

Asked by 10 years ago

So I have this Problem. I made a simple script the use loop and changes the Texts in the Textlabel. So I wondering how can I make the script continue the loop after the Player has resetted.

v = 10
while true do
    script.Parent.Text = "1"
    wait(v)
    script.Parent.Text = "2"
    wait(v)
    script.Parent.Text = "3"
    wait(v)
end

If you could help I would very much appreciate it :)

1 answer

Log in to vote
3
Answered by
BlackJPI 2658 Snack Break Moderation Voter Community Moderator
10 years ago

This is actually much easier than you probably thought it was! Roblox has a hidden property of StarterGui called ResetPlayerGuiOnSpawn that when set to true resets the gui on spawn. If you set it to false, the gui will not reset!

game:GetService("StarterGui").ResetPlayerGuiOnSpawn = false
0
Are you kidding me... ForeverDev 155 — 10y
0
Sorry I pasted this inside my script and the Gui still reset after I die. faruque7722 5 — 10y
0
I'm pretty sure you would need to make it a localscript that's parent is the screengui. Relatch 550 — 10y
0
Yes, it must be in a local script BlackJPI 2658 — 10y
View all comments (7 more)
0
Wondering if there's a method of doing this without this. It's possible by Kohl's Infinite Admin.. Nickoakz 231 — 8y
0
It's possible yeah, you just have to manually copy/paste the gui's and make sure all of your functions account for the duration when the gui's reset BlackJPI 2658 — 8y
0
Where will i put the script? screengui? startergui? Minecrafter09031031 16 — 5y
0
I put it in a Local Script child of the StarterGUI, but my GUI still resets after death Xzenerne 0 — 5y
0
Xzenerne, mine still resets as well. Exact command in a Local Script child of the StarterGUI. No clue what im doing wrong buttermanz 0 — 5y
0
Getting this too. Keeps resetting no matter what the parent is. StarterGui, ScreenGui, Frame, TextLabel. I even tried an intValue with the parent as a TextLabel RAM_BN0 0 — 4y
0
It should be in a normal script in ServerScriptService. olympic4 0 — 4y
Ad

Answer this question