After saving the game

[code]Include Basic Screen Effects by Emily Short.

check saving the game:
clear the screen;
say line break;
say line break;
say line break;
center “CONTINUE?”;
center “Do you wish to continue playing??”;
center “(unsaved progress will be lost)”;
say line break;
center “>”;
if player consents:
clear the screen;
say line break;
say line break;
say line break;
try looking;
otherwise:
say line break;
center “THANK YOU FOR PLAYING”;
say line break;
stop game abruptly.[/code]

this ALMOST does what i want it to… except it should SAVE and THEN do the thing.

This does the thing and then saves. so it’s wrong for me.

and since saving the game is an action out of world and they’re excempt from before, instead of and after rules i’m gonna need some dark sorcery or at least some good advice.

If’n ye cannae use an “after” rule, ye should try a “report”, cully.

Accent? What accent? Och, mebbe I’ve bin reedin’ too much Order of the Stick. And Thor knows what else.

EDIT - The sane part of my brain told me to tell you that if you change “Check” to “Report” it’ll work as intended. Nothing else needs changing. I’m sure there are more technical reasons for this, but basically, if you can’t use Before, try check; if you can’t use After, try report. Sledgehammer tactic; always works for me. Then when I hit the bugs I take the hammer to it again. Did I mention I never actually completed an IF game? Wonder why.

I tried that…

HOWEVER
when i restore a game, it asks me if i want to continue playing… which shouldn’t happen, ideally. it should just restore the game and do only that.

Well spotted, grasshopper. I’ll defer you to someone who actually knows a thing or two about it then. They’re usually around.

Hello. I’m someone who knows a thing or two about it, at least more than the person who posted above, which was past me. I know quite a bit more than past me, because I fiddled around.

Not that way. Pervert.

Anyway, I tried something that seemed like lunacy and it worked. Enjoy!

[code]Include Basic Screen Effects by Emily Short.

save the game rule response (B) is “[fancy_savegame]”.

To say fancy_savegame:
clear the screen;
say line break;
say line break;
say line break;
center “CONTINUE?”;
center “Do you wish to continue playing??”;
center “(unsaved progress will be lost)”;
say line break;
center “>”;
if player consents:
clear the screen;
say line break;
say line break;
say line break;
try looking;
otherwise:
say line break;
center “THANK YOU FOR PLAYING”;
say line break;
stop game abruptly.[/code]

Basically, I tapped into the response that displays ONLY after saving the game (it doesn’t display after restoring). And I added some code to it using a “to say” phrase. Gotta love I7’s flexibility. I didn’t think it would let me, to be honest.

perfect!

Why, thank you. I’ve always strived for perfection. In fact, in all respects, I have always struggled, humbly and modesty, towards the perfection I always felt was my veritable DUTY to-

…oh. You mean the code.

Yes, it’s nice. Serviceable. It does the job. It is, in fact, adequately suited for the necessary task it has to perform.

[sniff]

If you’re wondering about the code running after restore:

When you restore a game, it puts it in exactly the same state it was in when you saved, except for one value being changed. The current action at that point was “saving the game”, and it just finished its carry out stage, so now it’s going on to the Report rules. Those rules check that one value (the number returned from the save opcode) to see what message to print.

Putting code in a response like that…it should work. I feel like there should be a better way to do it but I can’t think of any without going down into I6. So as long as you don’t reference that particular response elsewhere it should be fine.

Yeah, that’s what I was bumping my head against. I dove into the Standard Rules, thinking maybe I could rewrite the whole rule to include that tidbit, and I found out it just maps to an I6 action. No go, out of my depth.

Then I realised I could “hack” it into the response. I also felt there should be a better way - but this works! It’s a neat trick.

That’s right, rub it in, why don’t you! Bring in the frickin’ salt!

SPOILER ALERT: It is possible I’m derailing this thread too far.

So I’ll just sit in the corner over there.

Alone.

Incomplete.

Imperfect.

(It’s an experiment. I want to see whether it’s possible to drown in self-pity if it gets up to ridiculous levels. If you never hear from me again, well, I’ve succeeded)

you need others to complete you to become perfect. so “alone” isn’t going to get you anywhere.

Hence the self-pity experiment. Now stop hijacking your own thread before I bawl bitter tears at you.