So i have a gui that has a textlabel that says "16/416", i need it to increase the number by how much my walkspeed increases if that makes sense.. So i need the label to say "(my walkspeed)/416" depending on my walkspeed. I've tried with putting a Numbervalue in my TextLabel, but didn't know where the local script should go, nor what code should be inside of it. Any help is appreciated. Thank you in advance.
It is pretty easy. Just put this LocalScript into "StarterPlayerScripts"
1 | local textlabel = --Location of Label |
2 | local hum = game.Players.LocalPlayer.Character.Humanoid |
3 | while true do |
4 | wait( 0.1 ) |
5 | textlabel.Text = hum.WalkSpeed .. "/416" |
6 | end |
I did not test this, so it may not work.
Here is a working script to use.
PLACE THE LOCALSCRIPT INSIDE THE TEXTLABEL!
1 | local label = script.Parent |
2 | local player = game.Players.LocalPlayer.Character:Wait() and game.Players.LocalPlayer.Character |
3 |
4 | while wait() do |
5 | label.Text = player.WalkSpeed.. "/416" |
6 | end ) |