Prompt · Leaderstats · Updated November 2026
Leaderstats and an economy module
The built-in leaderboard folder with Coins and Rebirths, plus a server economy module that is the only thing allowed to change them.
The prompt
Set up leaderstats for my game: on PlayerAdded create a Folder named exactly leaderstats with Coins (IntValue) and Rebirths (IntValue) loaded from the player's data. Create ServerScriptService.Modules.Economy with AddCoins(player, delta, reason) that validates a finite integer, never goes below zero, applies multipliers to positive earnings, updates the data cache and the leaderstat, and fires a CoinsChanged remote; plus CanAfford and Buy. Nothing else in the game may set Coins directly. Playtest, call AddCoins from the server, confirm the leaderboard updates, screenshot.The button opens Forge with this prompt already in the message box. Nothing is sent until you press Send, and the credit price shows first. Forge needs a Windows PC with Roblox Studio and the free Forge Bridge; Mac support is planned.
What Forge builds
- A leaderstats folder with the exact name Roblox looks for and IntValues for whole numbers.
- A single economy module as the source of truth, with a reason string logged per change.
- Multipliers (passes, rebirths, timed boosts) applied inside AddCoins only.
- A CoinsChanged remote the HUD and number pops listen to.
- A server-side proof: the stat is read before and after and asserted, not just a clean console.
Typical credits
On Sonnet 5.5 this prompt usually runs 40 to 200 credits ($0.40–2.00), more if the playtest catches mistakes that need fixing. One credit is one cent, the price is shown before each message, and credits never expire. Opus 5.5 and Fable 5.2 cost more per message and are worth it for a stubborn bug, not for a first build.
| What you ask for | Typical credits |
|---|---|
| This prompt | 40–200 |
| One build step (a button, a HUD fix, a lighting pass) | 20–150 credits ($0.20–1.50) |
| One game system (a shop, saving, a round loop) | 100–600 credits ($1–6) |
| A complete game, following a guide's full sequence | 2,500–6,000 credits ($25–60) |
Full ranges, packs and the optional membership are on the pricing page. New accounts get free trial credits when they first pair the Bridge (Roblox accounts older than 30 days). No card is needed.
How to run it
- Open your place in Roblox Studio and turn on Assistant ▸ ⋯ ▸ Manage MCP Servers ▸ Enable Studio as MCP server.
- Run the Forge Bridge on the same PC and confirm the pairing in the Forge web app; the sidebar shows your place name in green.
- Press Build this in Forge above (or copy the prompt and paste it), read the price, press Send.
- Forge reads your place first, builds, playtests, reads the console and sends a screenshot. Reply with changes; it remembers your place between messages.
Questions
Why only four stats on the leaderboard?
Roblox shows at most four leaderstats. Keep hidden stats such as Strength in the data module instead.
Can a leaderstat show 1.2M instead of 1200000?
Use a StringValue for formatted text; the economy module keeps the real number in data.
Related prompts and guides
- Rebirth with a permanent multiplier: A rebirth button with a scaling cost, a two-step preview, a server-side reset that keeps the right things, and a Rebirths leaderstat.
- Egg hatching with weighted odds: Eggs with weighted pet tables, odds shown on the egg, a server-side roll with luck, a hatch reveal and a paid-random policy check.
- VFX pass for pickups, purchases and hatches: ForgeFX installed once and wired to the moments that matter: pickups, buys, hatches, hits, rebirths, with budgets and reduced motion.
- Roblox leaderstats script with AI: the full step-by-step sequence this prompt belongs to.
- Pricing: packs from $10, what a whole game costs, membership perks.
- All prompts: every genre and system in the library.