> For the complete documentation index, see [llms.txt](https://visualonecompany.gitbook.io/storyframeworkdocs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://visualonecompany.gitbook.io/storyframeworkdocs/core-components/markdown/unified-menu-container/codex.md).

# Codex

The Codex menu creates a simple but effective way for players to keep track of the progress throughout your narrative. Add entries for characters that the players have met, locations they've explored, etc.

***

Codex Entries can be created inside of the `CodexEntryVault_DT` data table.

<figure><img src="https://2310584459-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuiMQl6UzBr8OnuaoaiWO%2Fuploads%2FqPla8Ez0OQXCyJ6gEg6x%2Fimage.png?alt=media&amp;token=7a7d0778-5cdd-447d-a275-29ac29838c7e" alt=""><figcaption></figcaption></figure>

**Entry ID**\ <sup><mark style="color:$info;">A unique ID value for your Codex entry. This ID is used to give your Codex entry to the player.<mark style="color:$info;"></sup>\
**Entry Category ID**\ <sup><mark style="color:$info;">Codex entries get categorized and require a "Entry Category ID". Multiple different Codex entries created in this data table can share the same category by matching their "Entry Category ID".<mark style="color:$info;"></sup>\
**Entry Name**\ <sup><mark style="color:$info;">The display name of your Codex entry in the Codex menu.<mark style="color:$info;"></sup>\
**Entry Description**\ <sup><mark style="color:$info;">The description of your Codex entry inside of the Codex menu when your entry is selected.<mark style="color:$info;"></sup>\
**Entry Icon**\ <sup><mark style="color:$info;">The icon of your codex entry displayed on the actual entry inside of the Codex menu.<mark style="color:$info;"></sup>

***

Giving your custom Codex entries to the player can be done a few different ways. First of which is through the `AddEntry_Codex` Quick Action. The first entry in the `Properties` array when using Universal Action Properties should be the Entry ID of your custom Codex entry in the data table mentioned above.

<div align="left"><figure><img src="https://2310584459-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuiMQl6UzBr8OnuaoaiWO%2Fuploads%2FKwmfWd5JhjJg9n8gz04M%2Fimage.png?alt=media&amp;token=83c2937d-d033-44ac-ab13-f15997d29ade" alt=""><figcaption></figcaption></figure></div>

Alternatively, you're also able to manually add a Codex entry through blueprints by calling the `Add Codex Entry from Data Table` function from SF's inventory manager.

<div align="left"><figure><img src="https://2310584459-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuiMQl6UzBr8OnuaoaiWO%2Fuploads%2FDG9ssSnTu4uJGKJdFIfw%2FAddCodex.png?alt=media&amp;token=e594d835-7e33-48f0-ab1a-233e0e135e83" alt=""><figcaption></figcaption></figure></div>

***

Codex categories require an `FText` name to display inside of the Codex menu. This can be set inside of the Framework Settings data asset > System Defaults > Inventory > Codex Category Names array (left field should be the "Category ID" that you've given to your Codex entries, and the right field should be the text display name that is shown in the Codex menu).

<div align="left"><figure><img src="https://2310584459-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuiMQl6UzBr8OnuaoaiWO%2Fuploads%2FPuRKxLd4BvkZQMay8mV7%2Fimage.png?alt=media&amp;token=a18a7b8a-9257-4065-b9dd-7f5a15cb3a7a" alt=""><figcaption></figcaption></figure></div>

***

For custom logic, SF's inventory manager also contains a `OnCodexEntriesModified` event dispatcher than is called any time a Codex entry is added or removed.

<div align="left"><figure><img src="https://2310584459-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FuiMQl6UzBr8OnuaoaiWO%2Fuploads%2FL5alFDUcjBxCXMdfSQl8%2Fimage.png?alt=media&amp;token=781f4ad8-4125-48b8-a88c-928439067ebd" alt=""><figcaption></figcaption></figure></div>

***
