of     1   

Scarvis
#141180131Tuesday, July 22, 2014 6:01 PM GMT

So I want to make a GUI that displays the ammunition for my weapon, but it doesn't show the current ammo I have it so its guiText, guiBar = game.StarterGui.TOASTAmmoGUI.Label, game.StarterGui.ToastAmmoGUI.Bar How do I fix it so the Label will change when a shots fired, PS the properties do change in the GUI, just not the text seen by the player
ninja900500
#141180990Tuesday, July 22, 2014 6:10 PM GMT

CurrentAmmo.Changed:connect(function() AmmoGui.Text = CurrentAmmo.."/"..MaxAmmo end)
Scarvis
#141182276Tuesday, July 22, 2014 6:26 PM GMT

Here is all my thingies in order; gui.Text = "["..ammo.."]" end local function keyPressed(mouse,key) if not reloading and key=='r' and ammo~=clipSize then handle.Reload:Play() mouse.Icon = cursorReload gui.Text = "[REL]" reloading = true wait(reloadTime) ammo = clipSize mouse.Icon = cursorNormal gui.Text = "["..ammo.."]" reloading = false end end mouse.Button1Down:connect(function() mouseClicked(mouse) end) mouse.Button1Up:connect(function() mouseDown = false end) mouse.KeyDown:connect(function(key) keyPressed(mouse, key) end) gui.Text = reloading and "[REL]" or "["..ammo.."]" mouse.Icon = cursorNormal hitSound.Parent = player.PlayerGui equipped=true end) tool.Unequipped:connect(function() mouseDown = false deathCon:disconnect() hitSound.Parent = nil equipped = false end)
ninja900500
#141182352Tuesday, July 22, 2014 6:27 PM GMT

Use .Changed:connect(function().
Goulstem
#141182435Tuesday, July 22, 2014 6:28 PM GMT

Changed isn't reliable.
Goulstem
#141182542Tuesday, July 22, 2014 6:29 PM GMT

Use something like.. game:GetService('RunService').RenderStepped:connect(function() Gui.AmmoStuffs.Text = Ammo.ValueStuffs end)
ninja900500
#141182619Tuesday, July 22, 2014 6:30 PM GMT

Both works the same way, just renderstepped is like always updating it even if your ammo is the same value.
Scarvis
#141186047Tuesday, July 22, 2014 7:06 PM GMT

Neither works
ninja900500
#141186589Tuesday, July 22, 2014 7:12 PM GMT

This guy deserves help. Bump.
UncleTaz
#141186804Tuesday, July 22, 2014 7:14 PM GMT

What is "tool"
Scarvis
#141186831Tuesday, July 22, 2014 7:14 PM GMT

local tool = script.Parent
Scarvis
#141187697Tuesday, July 22, 2014 7:24 PM GMT

b1
Scarvis
#141200657Tuesday, July 22, 2014 9:29 PM GMT

b2
Scarvis
#141203078Tuesday, July 22, 2014 9:52 PM GMT

b3

    of     1