In my roblox game, I am making a shop gui except it does not take away gold. It will give them the extra speed as long as they have enough gold.
player = script.Parent.Parent.Parent.Parent.Parent.Parent
Gold = player.leaderstats.Gold.Value
cost = 25
script.Parent.MouseButton1Click:connect(function()
if Gold>=cost then
Gold = Gold - cost
player.GuardSpeed.Value = player.GuardSpeed.Value + 1
end
end)
Can anyone help?

1 comment
Anyone? :(