I'm making a Tycoon and I have made a leaderstat that is called 'Cash'. I'm trying to make a Gui that shows the amount of cash you have but I can't figure out how to do it. Please give a solution because everything I'm doing isn't working.
✓ ANSWER ACCEPTED
How do you display a Leaderstat Value in a Gui?
1 answer
✓ Accepted answer
Make a localscript inside the gui, and change the text to the value of 'Cash' everytime the value changes
example script :
local player = game.Players.LocalPlayer
local Cash = player:WaitForChild("leaderstats"):WaitForChild("Cash")
Cash.Changed:connect(function()
script.Parent.Text = Cash.Value
end)
3 comments
0
It's still not working.
0
what is not working? any error in the output windows? saying "it doesnt work" doesnt help me help you
0
It is not displaying the value. I found this in the Ouput window. https://gyazo.com/99d8179fe7af6a92f7b7ce81d0e2847d
This discussion is preserved as it was. New answers, comments, and votes are closed.

9 comments
c
Try it again changed the script a bit
Thanks!!!
Can you mark my answer as answer? so i got some point and the post will be marked as "answered"
How do I do that?
Look around my answer there should be a button to mark it
It says I need 25 Reputation to upvote. Is that it?
ah nvm its fine
it should be "Accept answer" button at the bottom