This is a shop that makes your walkspeed 20 when you buy it (it is a GUI).
player = script.Parent.Parent.Parent.Parent.Parent
coins = player.leaderstats.Coins
price = 50
h = game.Workspace:FindFirstChild("Humanoid")
function buy()
if coins.Value >= price then
coins.Value = coins.Value - price
h.Walkspeed = 20
else
print 'Player has not enough money to buy!'
end
end
script.Parent.MouseButton1Down:connect(buy)

5 comments
But it still doesn't work how do I find the nuyer himself?
You already found the buyer. I updated the script. When you write Walkspeed, the "s" needs to be capitalized.
Also, I'd be happy to check out your game! I'm kinda curious as to what you are making. :P
It's not ready but ill give you credits for helping me in the shop.
Ok, thanks!