DataStoreOptions
Object used to provide additional parameters to DataStoreService:GetDataStore().
| Memory category | Instances |
|---|
Member index 2
Description
A configuration object passed as the third argument to
DataStoreService:GetDataStore() to customize how the returned
DataStore behaves. Create one with Instance.new("DataStoreOptions"),
set its properties, then pass it to GetDataStore. Currently the only
behavioral property is DataStoreOptions.AllScopes.
History 7
Members 2
AllScopes
| Type | Default | |
|---|---|---|
| bool | false | |
When set to true, the DataStore returned by
DataStoreService:GetDataStore() operates across all scopes instead
of a single scope. The scope parameter (second argument) to
GetDataStore must be an empty string ("") when this property is
enabled; passing a non-empty scope throws an error.
In all-scopes mode, every key is prefixed with its scope and a slash
separator. For example, DataStore:ListKeysAsync() returns keys
such as global/player_data_1234 or houses/house3. When you create or
access a key, you must include the scope prefix in the format
scope/keyname; omitting the slash throws an error.
Default value is false.
| Thread safety | ReadSafe |
|---|---|
| Category | Data |
| Loaded/Saved | true |
SetExperimentalFeatures
| Parameters (1) | ||
|---|---|---|
| experimentalFeatures | Dictionary | |
| Returns (1) | ||
| null | ||
Accepts a dictionary of feature-name keys mapped to boolean values and stores them on this DataStoreOptions instance. Calling this method has no observable effect on runtime behavior.
| Thread safety | Unsafe |
|---|
History 2
- 573 Change ReturnType of SetExperimentalFeatures from void to null
- 489 Add SetExperimentalFeatures