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

Screen GUI Label Text Help?

Asked by 5 years ago
Edited 5 years ago

Script goes fine, but when player resets or respawns the value goes back to 0. Any help or suggestions?

[Local Script in screen GUI inside text label]

1local player = game.Players.LocalPlayer
2local crops = player.Inventory:WaitForChild("Crops")
3 
4crops:GetPropertyChangedSignal("Value"):Connect(function()
5    script.Parent.Text = crops.Value
6end)

2 answers

Log in to vote
1
Answered by
Lakodex 711 Moderation Voter
5 years ago

This is actually not a script problem. Do these instructions

Click on the ScreenGUI and unclick ResetOnSpawn. Simple

0
I agree TheRealPotatoChips 793 — 5y
0
Thanks User#29320 0 — 5y
Ad
Log in to vote
0
Answered by 5 years ago

Maybe a while true do loop

01local player = game.Player
02local crops = player.Inventory:WaitForChild("Crops")
03 
04 
05function Update()
06    script.Parent.Text = crops.Value
07end
08 
09 
10while true do
11    Update()
12end
0
You Tried. Lakodex 711 — 5y
0
im new to scripting User#22145 0 — 5y
0
No hate man. I was to, Lets get hooked up and I'll teach you. Here's my discord : Devamspion#7812 Lakodex 711 — 5y
0
Dosent Work User#22145 0 — 5y
0
Omg, i really did this lol. Im laughing at how bad this is User#22145 0 — 4y

Answer this question