Skip to content

Troubleshooting ​

Symptom-first fixes for common integration issues. For onboarding, start with Quick start; for API lookup, use Server functions or Client functions.

Client reads return nil ​

SymptomLikely causeWhat to do
Get / GetPath always nilServer never called Init for that playerCall PlayerState.Init(player) on PlayerAdded β€” Quick start Β· Initialization
nil right after joinReplica not ready yetWait for IsReady() or use OnChanged after ready β€” Client status
nil for a key you set on serverKey is under ServerOnlyRoots or not in DefaultDataCheck Data visibility Β· Server-only data
Wrong value or missing nested fieldTypo in key/path, or reading before server writeConfirm path strings; verify server Set / SetPath β€” Paths

Data never saves ​

SymptomLikely causeWhat to do
Changes lost on rejoinWrites only in memory; profile never savedSaves run on leave, shutdown, and SaveData β€” ensure Init succeeded β€” Setup Β· Events
Specific keys never persistListed in RuntimeNonPersistentRoots (session data)Session roots replicate but strip before save β€” Session data
Custom save logic skippedBeforeSave handler error or early returnReview BeforeSave

Client cannot write saved data ​

This is expected. PlayerState does not ship client→server write remotes.

SymptomLikely causeWhat to do
Client script calls Set (or similar)Client API is read-onlyAdd your own RemoteEvent; validate on server; call server APIs β€” Client writes via remotes Β· API overview

Init fails or player has no profile ​

SymptomLikely causeWhat to do
Init returns falseProfileStore / config error, or player left during loadCheck server output; review PlayerStateConfig and DefaultData β€” Configuration Β· Setup
Missing keys after joinKey not in DefaultData templateAdd defaults in DefaultData; use Reconcile behaviour as documented in Setup
Require errorsWrong module path after moving the modelUse canonical paths from Installation

Leaderboard empty or wrong ​

SymptomLikely causeWhat to do
No entriesLeaderboard disabled or stat path mismatchLeaderboard configuration
Player rank missingStat not updated on server, or read before readyUpdate via server APIs; check timing β€” Server leaderboard

OnChanged never fires ​

SymptomLikely causeWhat to do
No callbacksSubscribed on wrong side (server vs client) or wrong pathChange listeners guide
Fires once then stopsDisconnected connection, or path does not match writesMatch exact key/path; use server OnChanged for server-driven tests
Never fires on joinSubscribed before IsReady without handling initial stateWait for ready or read current value after subscribe β€” Client listeners

Feedback ​

Issue typeWhere to report
Documentation errors, typos, broken linksplayerstate_documentation on GitHub (use Suggest an edit on any page)
Module behaviour in your gameCreator Store asset β€” there is no separate public module repo linked from these docs

PlayerState - High-Performance Roblox Data Management