Roblox Wiki
Register
Advertisement
Roblox Wiki
Discontinued
This article is about a discontinued feature.

Data persistence was a method for saving data from one play session to another. On July 14, 2016, in Roblox version 252 (July 2016), all data persistence features were marked as deprecated or discontinued. However, though their usage had already been discouraged prior due to reported data loss in experiences that used data persistence between May 28 and May 29, 2014.[1] As of May 2021, data persistence has been disabled in all experiences. For new work, Data Stores should be used instead.

Data persistence functions are in the Player light iconPlayer dark iconPlayer object.

:WaitForDataReady() 
:LoadBoolean(String key) 
:LoadNumber(String key) 
:LoadString(String key) 
:LoadInstance(String key) 
:SaveBoolean(String key,Bool value) 
:SaveNumber(String key,Number value) 
:SaveString(String key,String value) 
:SaveInstance(String key,Object value)

:WaitForDataReady()[]

Used to make sure all data is ready, use this before any other Data Persistence code!

:Load[Type](String key)[]

:LoadBoolean(String key) 
:LoadNumber(String key) 
:LoadString(String key) 
:LoadInstance(String key)

Load data of the given type from the given key in the player.

:Save[Type](String key,[Type] value)[]

:SaveBoolean(String key,Bool value) 
:SaveNumber(String key,Number value) 
:SaveString(String key,String value) 
:SaveInstance(String key,Object value)

Saves data of the given type to the given key in the player.

Limitations[]

Due to the player and place specific nature of data saved using data persistence, players were required to be in-game to load or save their data, and data could not be loaded or saved across multiple places in the same universe.

References[]

  1. Lucas, Keith; Miller, Adam; Kapoulkine, Arseny (2014, May 30). "Yesterday’s Data Persistence Error: An Explanation". From Roblox Blog. Accessed June 24, 2023. Archived from the original on April 3, 2015.
Advertisement