This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
remember [2013/12/17 20:06] l created |
remember [2017/10/09 20:39] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
+ | <- [[function|About Functions]] --------- [[if|Displaying Text Conditionally]]-> | ||
+ | |||
===== <<remember>> and <<forget>> ===== | ===== <<remember>> and <<forget>> ===== | ||
====Motivating example==== | ====Motivating example==== | ||
- | Variables are reset every time the reader restarts a story. If you'd like to remember the value of a variable after the game, use the ''<<remember>>'' macro. It works exactly the same way as ''<<set>>'', except it stores the variable in browser storage that remains between sessions. | + | Variables are reset every time the reader restarts a story. If you'd like to remember the value of a variable after the game, use the [[<<remember>>]] macro. It works exactly the same way as [[<<set>>]], except it stores the variable in browser storage that remains between sessions. |
<code> | <code> | ||
Line 21: | Line 23: | ||
<<forget $meals>> | <<forget $meals>> | ||
</code> | </code> | ||
+ | |||
+ | <- [[function|About Functions]] --------- [[if|Displaying Text Conditionally]]-> |