Update README.md

This commit is contained in:
Nick Walton 2020-06-27 20:13:53 -06:00 committed by GitHub
parent e957136d7e
commit 1426f2ee2e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -13,6 +13,10 @@ https://www.codecademy.com/courses/introduction-to-javascript
### History ### History
You have access to (but can't modify) the `history` object which is a list of the previous actions of the player and of the AI. You have access to (but can't modify) the `history` object which is a list of the previous actions of the player and of the AI.
### Memory
You have access to (but can't modify) the `memory` object which is the current user defined memory.
You can modify the memory the game uses by settings the `state.memory.context` value. This will replace the user defined memory.
### Quests ### Quests
You can modify the quests property to change the quests of the adventure mid game. You can modify the quests property to change the quests of the adventure mid game.
@ -32,7 +36,7 @@ You can modify worldEntries with the below functions
### State ### State
The `state` variable can be used to store information that's persistent across function calls. The `state` variable can be used to store information that's persistent across function calls.
* The `state.memory.context` value will be added to the games memory if exists * The `state.memory.context` value will replace the user defined memory if it exists
* The `state.message` value will be displayed as a extra message in the game (if it exists) * The `state.message` value will be displayed as a extra message in the game (if it exists)
* You can set any variable on state to store and modify adventures throughout an adventure. * You can set any variable on state to store and modify adventures throughout an adventure.