The AfterLife() function, with PunyInform, is called not only when the player is dead, but also after the quit command (in this case deadflag = GS_QUIT), which can cause problems if not taken into account.
In this case, the quit command does not work:
[ AfterLife;
deadflag = GS_PLAYING;
"You're back in business!";
];
I have to do:
[ AfterLife;
if (deadflag == GS_DEAD or GS_DEATHMESSAGE) {
deadflag = GS_PLAYING;
"You're back in business!";
}
];
[ AfterLife;
if (deadflag == GS_QUIT) @quit;
deadflag = GS_PLAYING;
"You're back in business!";
];
Adventureland game, designed by Scott Adams and ported to Infom6 (one of Inform 6's standard example games), highlights the issue:
The AfterLife() function, with PunyInform, is called not only when the player is dead, but also after the quit command (in this case deadflag = GS_QUIT), which can cause problems if not taken into account.
In this case, the quit command does not work:
I have to do:
Adventureland game, designed by Scott Adams and ported to Infom6 (one of Inform 6's standard example games), highlights the issue: