So im making a new simulator game, but the old shop scripts from tutorials dont work after some updates of roblox... Please tell me how i can make a shop
✓ ANSWER ACCEPTED
How do i make the script behind a simulator shop?
1 answer
✓ Accepted answer
Ok ill help you with some things
local Cash = script.Parent.Parent.Parent.Parent.Parent -- Script > Textbutton > Frame > ScreenGui > PlayerGui > Player
local Item = game.Lighting.Item
local Backpack = script.Parent.Parent.Parent.Parent.Parent.Backpack
script.Parent.MouseButton1Click:Connect(function()
if Cash.Value >= 5000 then -- Item costs 5000 Cash
Item.Clone(Backpack)
Cash.Value = Cash.Value - 5000
elseif Cash.Value < 5000 then
script.Parent.Text = "Item costs too much!"
wait(1.5)
script.Parent.Text = "Item - 5000 Cash"
end)
If something doesn't work tell me
This discussion is preserved as it was. New answers, comments, and votes are closed.

1 comment
I forgot that Cash has to be script.Parent.Parent.Parent.Parent.Parent.leaderstats.Cash