Context: When the player buys this item, his money output will go to 2x
Hello. I’m trying to make a shop system where if you buy a certain item your money drop amount would increase to you getting double instead of 1.
local upgradeBought = rs:WaitForChild("remoteEvents").upgradeBoughtLitter local MoneySound = workspace.MoneySound upgradeBought.OnServerEvent:Connect(function(player, price) local leaderstats = player:WaitForChild("leaderstats") local cash = leaderstats:WaitForChild("money") if cash.Value >= price then cash.Value -= price local LitterBox = rs:WaitForChild("Litter Box"):Clone() LitterBox.Parent = workspace MoneySound:Play() print("367423") end end)
i have added a boolvalue inside the
upgradeBoughtLitter remote but I have no idea how to access it and set it to true. Could someone please explain to me how to access a boolvalue and to check if its true? Thanks.