Work with Files In-Game
Retrieving Player Files
Retrieve All Player Files
Retrieve all files associated with the player.
LootLockerSDKManager.GetAllPlayerFiles((response) =>
{
if (response.success)
{
Debug.Log("Successfully retrieved player files: " + response.items.Length);
}
else
{
Debug.Log("Error retrieving player storage");
}
});Example response:
Retrieve All Public Files From Another Player
Retrieve all (public) files associated with another player.
int playerId = 1;
LootLockerSDKManager.GetAllPlayerFiles(playerId, (response) =>
{
if (response.success)
{
Debug.Log("Successfully retrieved player files: " + response.items.Length);
}
else
{
Debug.Log("Error retrieving player storage");
}
});Example response:
Retrieve Single Player File
Retrieve a specific player file.
Uploading Player Files
Upload a Private Player File From Path
Upload a (private) player file from the file's path.
The Boolean "Is Public" should be set to false in this case, to upload a private file!
Example response:
Upload a Public Player File From Path
Upload a (public) player file from the file's path.
The Boolean "Is Public" should be set to true in this case, to upload a public file!
Upload a Private Player File Using FileStream
Upload a (private) file using FileStream.
Upload a Public Player File Using FileStream
Upload a (public) file using FileStream.
Upload a Private Player File Using Byte Array
Upload a (private) file using byte array.
Upload a Public Player File Using Byte Array
Upload a (public) file using byte array.
Updating Player Files
Update a Player File from Path
Update a player file from the file's path.
Be aware that if you update a file, make sure to include everything, even what you don't want to update, as you can update a file to contain nothing.
Example response:
Update a Player File Using Byte Array
Update a player file using byte array.
Update a Player File Using FileStream
Update a player file using FileStream.
Deleting Player Files
Delete Player File
Delete a player file.
Last updated
