20. Find the cause when a value is wrong
Start with the exact ID, the current value and the action that writes it. That is usually faster than changing several settings at once.
| What you see | Check this first |
|---|---|
| The designer still says False after play | It shows the starting definition. Use get clock_wound in the running preview. |
| Points rise every time the object is used | The reward is unconditional, or an old add action remains after the guarded script call. |
| The second click appears to do nothing | Wait for the first interaction to finish. A busy interaction can ignore another click. |
| A condition fails despite the word true showing | Check for the String "true" rather than Boolean true. Displayed text can hide that difference. |
| A numeric comparison gives an odd result | Check that both values are numbers. If Compare needs {"$var":"score"}, not the literal String "score". |
| A GUI shows $$score literally | Check the ID, spelling and that the record exists. Test in gameplay, not only the authoring canvas. |
| Array entries have the wrong types | Use valid JSON. The quick separated-list form creates String members. |
| Appending makes a list inside the list | Append adds one member. An Array operand becomes one nested Array. |
| A new initial value does not appear | Apply and save, then test a fresh game. An old save can restore earlier data. |
| get returns <undefined> | Check the ID and whether a loaded save predates that variable. |
Change one thing, then run one known test. A label, a fresh get query and a single interaction are enough to narrow down most variable problems.
