Debugging mode

Is there any way to turn debugging on and off during a game? I tried created a phrase that sets the DEBUG constant but since it’s not defined in a for release game it doesn’t compile.

Unfortunately not. The easiest workaround is to make your own debugging verbs all depend on some global variable, and then set that.

Here’s what I’m doing on my side (probably inspired by someone else):

Debugging is a truth state that varies.

Understand "debug on" as debugging on.
Understand "debug off" as debugging off.

Debugging on is an action out of world.
Debugging off is an action out of world.

Carry out debugging on:
	now debugging is true;
	say "Debugging is now on.";

Carry out debugging off:
	now debugging is false;
	say "Debugging is now off.";

To decide whether debugging is on:
	if the debugging is true, decide yes;
	decide no;

which then allows:

if debugging is true:
    say "[this value you want to check]";
    showme the contents of Table of stats;
    [...]