Roblox game systems that don't lose saves or Robux.
16 tested Luau modules for what nearly every experience needs: session-locked saves, purchases that never double-grant, codes, daily and playtime rewards, leaderboards, egg rolls with pity, inventory, currency and rebirths, and remote guards that stop exploiters. Drag one file into Studio. 3 modules are free.
- 16 modules · 2,228 lines
- 66 automated tests
- 1 example simulator server
- 75¢ a system ($12 one-time)
Try it: real Luau, running in your browser
This runs the free Studwright modules (Format, Signal, Cleanup) in the real Luau VM compiled to WebAssembly. Edit the code and press Run.
Output appears here.
What's in the kit
Server modules use DataStoreService or MarketplaceService. Shared modules run on both sides. Tap a module for its usage.
Tested like a live game, before you ship it
Every build runs 66 tests in a real Luau VM against a Roblox engine mock with a virtual clock, DataStore outages and two servers fighting over one save. The tests ship in the kit, so you can run them yourself.
Results from the build of 1 Oct 2026 (luau-web 1.4.0).
Studwright Luau Kit 1.0: everything in one zip
16 ModuleScripts as a drag-in Studwright.rbxmx and as .luau files for Rojo, an example server that wires saves, leaderstats, a code, daily rewards, a Developer Product, rebirths and guarded remotes, API.md with every function, the 66 tests and a plain-English licence.
- SaveData: session lock, retries, migrations, autosave, BindToClose, Erase for deletion requests
- Receipts: ProcessReceipt that saves before it says granted, and never grants twice
- Codes, DailyRewards (UTC streaks, grace days), PlaytimeRewards
- Leaderboard: leaderstats + global top lists, throttled writes, huge-number encoding
- LootTable (luck, pity, odds text), Inventory (stacks, slots, equip), Currency (multipliers, rebirths)
- RemoteGuard: rate limits + type checks that reject NaN, inf, long strings and extra args
- Cooldown, StateMachine, Spring, plus the free Signal, Cleanup and Format
A safe save in 8 lines
local SaveData = require(game.ReplicatedStorage.Studwright.SaveData)
local store = SaveData.new({ name = "PlayerData_v1", template = { Coins = 0, Pets = {} } })
game.Players.PlayerAdded:Connect(function(player)
local profile = store:Load(player) -- session-locked; nil if the player left
if not profile then return end
profile.Data.Coins += 100 -- autosaves, saves on leave and on shutdown
end)
Install: drag Studwright.rbxmx onto ReplicatedStorage (or copy the folder into your Rojo project). Turn on "Enable Studio Access to API Services" to test saves in Studio.
FAQ
How does it stop item duplication when players hop servers?
SaveData session-locks every save through UpdateAsync, so only one server owns a player's data at a time. If a player joins a new server before the old one finished saving, the new server waits and retries until the lock is released. A lock older than 30 minutes (a crashed server) is taken over. A server that finds its lock taken stops writing and kicks the player rather than overwrite newer data. All of this is covered by tests with two simulated servers.
Can a Developer Product be granted twice?
No. Receipts keeps the last 100 PurchaseIds in the player's save and only answers PurchaseGranted after the save holding that PurchaseId succeeded. When Roblox retries a receipt, it's acknowledged without a second grant. If the buyer isn't on this server yet, or saving fails, it answers NotProcessedYet and Roblox tries again later.
Why not a free library?
Good free libraries exist for single jobs, and ProfileStore is a popular free choice for saves. Studwright is for when you want the whole set of everyday systems in one consistent style that already work together (saves feed receipts, codes, rewards and leaderboards), with tests you can run and one example server that shows the wiring.
Why not a single-system kit?
Single systems sell for $4.29 to $20 each on itch.io (prices seen 1 Oct 2026: codes $4.99, time rewards $4.99, leaderstats $7.99, pet system $14.99, inventory $20). Studwright gives you 16 systems for $12, about 75 cents each, all sharing one save.
Does it include UI or models?
No, Studwright is server and shared code. For buttons, panels and icons get Glintpane, or the Builder Bundle with both plus 120 sound effects.
Can I use it in a paid or monetised experience?
Yes. Royalty-free in unlimited experiences, including ones that earn Robux and DevEx, for yourself or for clients, with no credit needed. You can't resell or share the modules themselves.
Rojo, Wally, strict mode?
The zip has a default.project.json for Rojo and the modules as .luau files. They run in Roblox's default (non-strict) type mode and use modern Luau (task, generalized iteration, compound assignment).
How do I get the files after buying?
Polar emails a receipt with the download link straight away, and the zip stays in your Polar customer portal for later versions. It's a one-time purchase.