This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
codex [2022/06/17 22:15] – justin | codex [2022/12/22 18:17] (current) – justin | ||
---|---|---|---|
Line 8: | Line 8: | ||
codex[" | codex[" | ||
</ | </ | ||
- | The codex variable will contain a lookup with keys named " | + | The codex variable |
+ | ====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[" | ||
+ | </ | ||
+ | The script above creates an empty codex variable, then inserts a new key/value pair with a key of " | ||
+ | |||
+ | ~~NOTOC~~ |