XboxConnectedStorage - stingray.XboxConnectedStorage namespace reference - Stingray Lua API Reference

Description

Used to communicated with the ConnectedStorage (save data) system on Xbox One.

Functions

Parameters

storage_id :

integer

The ID of the storage space to delete from.

container :

string

The container in the storage space to delete.

Returns

integer

An ID that can be used to track the status of the operation using status().

This is an async operation, use status() to track progress. You must call finish() when you are done with the task.

Parameters

read_id :

integer

The ID of the operation you are done with.

Returns
This function does not return any values.

You should call this exactly once for each operation call (regardless of whether that call completed successfully or not).

Parameters

user_id :

integer

The user whose storage space we are querying.

Returns

integer

An ID identifying the storage space.

This is an async operation. You can check its status with status() You can use the storage space when the operation has completed. When you are done with the storage space you should call finish() to free all resources with the storage space.

Parameters

storage_id :

integer

The ID of the storage space to read from.

container_prefix :

string?

Optional prefix for containers to search for. If not specified, will return all coontainers.

The ? notation indicates that this type is optional: there may be zero or one instances of it.
Returns

integer

An ID that can be used to track the progress of the operation.

If no prefix is specified, returns information about all containters.

Parameters

query_id :

integer

The ID of the read operation (returned by query()).

Returns

table

A table with the result of the query operation. The returned table has a table with data for each container with the fields "display_name", "name", "needs_sync" and "total_size".

The data is only available until you call finish().

Parameters

storage_id :

integer

The ID of the storage space to read from.

container :

string

The name of the container to read from.

reads :

table

A table of strings with the keys that should be read from the container.

Returns

integer

An ID that can be used to track the progress of the operation.

get_storage_space() must have completed for the storage_id before you call this function.

This is an async operation. Use status() to track the progress of the operation. When you are done you should call finish() to complete the operation.

Parameters

read_id :

integer

The ID of the read operation (returned by read()).

Returns

table

A table with the result of the read operation.

The data is only available until you call finish();

Parameters

id :

integer

The ID of the async operation.

Returns

integer

The status (UNKNOWN, STARTED, COMPLETED, CANCELED, ERROR) of the operation.

Parameters

storage_id :

integer

The ID of the storage space to write data to.

container :

string

The container in the storage space to write to.

display_name :

string

The display name that will be shown for the container.

writes :

table

A table with keys (strings) and values (strings) to write to the container. This can be nil if you just want to delete data.

deletes :

table

A table with names of keys to delete from the container. This can be nil if you just want to write data.

Returns

integer

An ID that can be used to track the status of the operation using status().

A number of values are written under the specified keys. Keys can also be deleted using this function. You can only call this function if get_storage_space() has completed successfully for the storage space.

This is an async operation, use status() to track progress. You must call finish() when you are done with the task.

The constants in this group can be returned as the status of asynchronous operations.

CANCELED : integer

The operation was cancelled by the user.

COMPLETED : integer

The operation has completed successfully.

ERROR : integer

An error occurred while performing the operation.

It has been started but not yet completed.

UNKNOWN : integer

The operation is unknown to the system, either because it has never been started or because it has been finished.