RobloxScripterAI
Discord ↗
Link Copied to Clipboard
×
"create small money simulator for purchasing products"
local MoneyProducts = { [12345] = {"Money", 100}, [12346] = {"Money", 1000}, [12347] = {"Crystals", 200}, } function AwardProduct(player, product_id) if MoneyProducts[product_id] then --If the product is money local MoneyType = MoneyProducts[product_id][1] --"Money", "Crystals" or "Jewels" local MoneyAmount = MoneyProducts[product_id][2] --Amount of money to be given to the player player.leaderstats[MoneyType].Value = player.leaderstats[MoneyType].Value MoneyAmount end end