| 1 |
Dialog 'Pre' block check handlers: |
| 2 |
|
| 3 |
Every .py file in this directory corresponds to a handler for a class of checks in a dialog file. |
| 4 |
Each file describes in its comments the check that it performs. |
| 5 |
|
| 6 |
When writing a new check, you have the variable 'verdict' which you are able to write to. |
| 7 |
It is passed in with the value 'True' In order to have a check be treated as 'passed' then |
| 8 |
ensure that this variable is still true when you are done, if you want to have your check fail |
| 9 |
then set the verdict to 'False' at the point where control goes back to your caller. |
| 10 |
|
| 11 |
The following variables are also avaiable to you: |
| 12 |
|
| 13 |
character, speaker, location |
| 14 |
which hold the CFObject of the player and the NPC and the location where tokens are being |
| 15 |
written to and read from. |
| 16 |
|
| 17 |
These should probably be treated as read-only by your check, otherwise you might cause strange |
| 18 |
side-effects on other checks. |
| 19 |
|
| 20 |
Other than that, there are no technical limits on what you can do with a check, although it is |
| 21 |
probably good form not to make drastic changes to the player's character. |