This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionLast revisionBoth sides next revision | ||
codex [2022/05/17 22:15] – justin | codex [2022/12/22 18:16] – justin | ||
---|---|---|---|
Line 2: | Line 2: | ||
---- | ---- | ||
- | A **codex** is a data type with its data stored as key/value pairs. | + | A **codex** is a data type with its data stored as key/value pairs. |
- | ====Examples:==== | + | ====Example:==== |
<code bauxite> | <code bauxite> | ||
codex[" | codex[" | ||
</ | </ | ||
- | (Description | + | The codex variable above will contain a lookup with keys named " |
+ | ====Modifying a Value:==== | ||
+ | <code bauxite> | ||
+ | $my_codex = codex[" | ||
+ | $my_codex[" | ||
+ | </ | ||
+ | The script above creates a codex variable containing lookups for an item ID and a numeric count value, then modifies the count to 10. | ||
+ | |||
+ | ====Inserting a Value:==== | ||
+ | <code bauxite> | ||
+ | $my_codex = codex[]; | ||
+ | $my_codex[" | ||
+ | </ | ||
+ | |||
+ | ~~NOTOC~~ |