# Player Samples

## Player Names

While it is possible to retrieve [Player Names](/players/names.md) from 1st part platform IDs (when authenticating with [Platform Login](/the-basics/core-concepts/players.md#authenticating-players)), you can also optionally let players set their own name or display their public UID. It is also possible to make sure each player's name is unique.

This sample can be found in our [SDK](/the-basics/sdks.md#unity-sdk) under the name `3 - PlayerNames`

This sample demonstrates allowing the player to set their own player name.

### In-Engine

Enter your name in the field and click `Set player name` to set your player name.

<figure><img src="/files/scij05nkiE4DP9thC22z" alt=""><figcaption></figcaption></figure>

### Web Console

Navigate to Settings -> Game Settings to select if your game should accept unique player names.

<figure><img src="/files/NeVydRIQ4bMDRtApFTTC" alt=""><figcaption></figcaption></figure>

## Player Storage

With LootLocker you can store [key/value pairs](https://github.com/lootlocker/gitbook-sync/blob/main/players/storage/README.md) in a player's profile. These pairs can be created, updated or deleted directly from your game, or manually through the Web Console.

This sample can be found in our [SDK](/the-basics/sdks.md#unity-sdk) under the name `4 - PlayerStorage`

This SDK Sample demonstrates creating, updating and deleting key/value pairs.

### In-Engine

To create a new key, enter a value in the lower `key` and `value` field and click the `Create/Update key/value` button. The new key/value should be displayed in the table on the right side.

To update a value, enter the correct key and value in the `key` and `value` field and click `Create/Update key/value`.

To delete a key/value, enter the key in the upper `key` field and click `Delete key/value`.

<figure><img src="/files/ljynqzVkafPVZGHP8a9X" alt=""><figcaption></figcaption></figure>

### Web Console

Through LootLocker's Web Console it is possible view the key/values that have been stored in the player's profile. You can search for players in the [Player Manager](/players/managing-players.md) and view their key/values under the `Storage` tab.

<figure><img src="/files/Za5xGrmDYahs8ZTpKNkL" alt=""><figcaption></figcaption></figure>

## Player Files

LootLocker allows you to easily store files of any type in the [player's profile](/players/files.md). Stored files can be downloaded from a URL. Each file stores up to 5 revisions when updated which can be reverted through the Web Console.

This sample can be found in our [SDK](/the-basics/sdks.md#unity-sdk) under the name `7 - Player Files`

In this SDK Sample you can upload a file to the player's profile, update it with a new file, and then download the file from LootLocker's servers.

### In-Engine

To upload a new file, click the `Upload/Update File` button. To update a file, select a file and then use the File ID field to indicate which file this new file will be replacing. To download an uploaded file, enter the file ID from the list on the right side and click `Download File`.

<figure><img src="/files/C8U9tzi4lKh8PTVugb3z" alt=""><figcaption></figcaption></figure>

### Web Console

Through LootLocker's Web Console it is possible view files uploaded to a player's profile, download them, revert the file to previous revisions, or manually upload files from your computer. You can search for players in the [Player Manager](https://github.com/lootlocker/gitbook-sync/blob/main/players/managing-players/player-console-overview.md) and view their uploaded files under the `Files` tab.

<figure><img src="/files/4EEdAdNRYEneHxppVCV8" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.lootlocker.com/the-basics/samples/player-samples.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
