Roblox Data
Use when writing, changing, debugging, or auditing Roblox player saves: DataStore, ProfileStore,…
by tabooharmony · MIT
The skill
Use when writing, changing, debugging, or auditing Roblox player saves: DataStore, ProfileStore, session locks, schemas, migrations.
roblox data persistence
When to Load
Load for player saves, migrations, retries, shutdowns, or session ownership. Leaderboards/messaging/world data: roblox-server-data; Open Cloud: roblox-cloud.
Quick Reference
- Define a serializable template and a version field before storing player state. Deep-copy templates so nested defaults are not shared; migrate, then reconcile missing fields against the template. Scope store names by environment (
PlayerData_Studio) so Studio writes stay out of production. - Use
UpdateAsyncfor read-modify-write; handle throttling and transient errors. - Prevent concurrent profile mutation with a session-ownership protocol.
- With ProfileStore:
StartSessionAsync,Profile.OnSessionEnd,EndSessionas documented; noStealfor normal loads;ProfileStore.Mockfor ephemeral Studio writes. - Save on meaningful changes and lifecycle boundaries;
PlayerRemovingalone is not sufficient;BindToClosefinishes pending work. - Store primitives/arrays/dictionaries; convert Instances/userdata/functions/cyclic tables first. Validate numbers (no NaN/inf), strings (
utf8.len), nested tables: one bad value fails the write. - RTBF: keep the user ID as a static substring in keys (
player_<UserId>) so{UserId}deletion templates match; hashed/random keys make erasure manual. GetAsyncserves a 4-second local cache (DataStoreGetOptions.UseCache, defaulttrue); verify writes withUseCache = false.- Poll
DataStoreService:GetRequestBudgetForRequestTypefor live headroom; quotas scale with concurrent users (experience reads: 300 + CCU x 40/min). - New code identifies users with
player.User(User.Id,DomainType,DomainId);UserIdremains valid, but never mix the two IDs in one key scheme. - First-session traces:
roblox-analytics§8.
Persistence workflows: references/full.md
Use this skill
Connect your agent to the Skill Store MCP server and ask for it by ref: tabooharmony/roblox-data-61806532759.
Details
- Publisher
- tabooharmony
- Category
- Software Development › Misc
- License
- MIT
- Updated
- 2026-10-14
References
More from tabooharmony
- Roblox Architecture Use when adding, moving, refactoring, or reviewing Roblox feature ownership, code layout, depende…
- Roblox Collaboration Mode Load FIRST for any Roblox task: build, change, fix, debug, review, audit, or plan.
- Roblox Luau Core Use when writing, editing, or debugging any Luau: tables, control flow, string patterns, scope, c…
- Roblox Luau Patterns Use when writing or refactoring Roblox Luau modules, object lifecycles, signals, task scheduling,…