Goat-Cheese and Sage Chicken

Example 280
★★★

Implementing a FULL SCORE command which lists more information than the regular SCORE command, adding times and rankings, as an extension of the example given in this chapter.

Some games provide a FULL SCORE command that gives more information about the player's achievements than SCORE alone. Supposing we wanted to include a FULL SCORE in our game that gave the kind of score reading described in this chapter:

"Goat-Cheese and Sage Chicken"
Use scoring.
The story headline is "An interactive recipe"
Table of Tasks Achieved
PointsCitationTime
3"sauteeing onions"a time
3"reconstituting apricots" 
1"flattening chicken" 
1"unwrapping goat cheese" 
To record (T - text) as achieved:
   choose row with a citation of T in the Table of Tasks Achieved;
   if there is no time entry:
      now time entry is the time of day;
      increase the score by the points entry.
Requesting the full score is an action out of world. Understand "full" or "full score" as requesting the full score.
Carry out requesting the full score:
   if the score is 0, say "You have achieved nothing towards supper." instead;
   repeat through the Table of Tasks Achieved in reverse time order:
      say "[time entry]: [citation entry] ([points entry])."
Table of Rankings
ScoreRank
0"Rank Amateur"
2"would-be Bobby Flay"
5"Alton Brown"
8"Julia Child"
The Kitchen is a room. The description of the Kitchen is "Equipped with many familiar friends: refrigerator, stove, oven; countertop; cabinet for pans and bowls, and a drawer for your tools."
The stove is scenery in the kitchen. It is a supporter. The oven is a container. It is part of the stove. It is closed and openable. The stove's switch is a device. It is switched on. It is part of the stove. The oven's dial is a device. It is switched off. It is part of the oven.
A thing can be heatproof.
Instead of putting something which is not heatproof on the stove when the stove's switch is switched on:
   say "You catch yourself just at the last minute: not a good idea to put [the noun] directly on the stove while it's turned on."
Instead of switching on the stove, try switching on the stove's switch. Instead of switching off the stove, try switching off the stove's switch. Instead of switching on the oven, try switching on the oven's dial. Instead of switching off the oven, try switching off the oven's dial.
Before switching on the oven's dial when the oven is open:
   say "(closing the oven so that it will heat properly)[command clarification break]";
   try closing the oven.
The frying pan is a heatproof unopenable open container on the stove.
The cabinet is a closed openable container in the kitchen. It is scenery. It contains an open unopenable container called a mixing bowl. It contains a portable supporter called a platter. An open unopenable heatproof container called a Calphalon baking dish is in the cabinet. The baking dish has the description "One of those marvelous pieces of kitchen equipment which goes on the stove or in the oven, as you will. The chief thing is never ever to touch it when it is hot, since the handles are metal and the heat retention excellent."
The counter is a supporter in the kitchen. It is scenery. The kettle is a heatproof openable closed container on the counter. Some water is in the kettle.
The water can be cool, warm, or boiling. The printed name of the water is "[water condition] water".
The refrigerator is a closed openable container in the kitchen. It is scenery. Understand "fridge" as the refrigerator.
An ingredient is a kind of thing.
Some onions, some apricots, and some sage are ingredients on the counter. A chicken breast, an egg, and goat cheese are ingredients in the refrigerator.
The goat cheese can be wrapped, snipped open, or unwrapped. The printed name of the goat cheese is "[goat cheese condition] goat cheese".
The sage can be unwashed, clean, or julienned. The sage is unwashed. The printed name of the sage is "[sage condition] sage".
The apricots can be dried, reconstituted, or chopped. The apricots are dried. The printed name of the apricots is "[apricots condition] apricots".
The chicken breast can be whole, flattened, stuffed, rolled, coated, browned, or baked. The printed name of the chicken breast is "[chicken breast condition] chicken breast".
The onions can be unpeeled, peeled, diced, sauteed, or burnt. [The printed name of the onions is "[onions condition] onions".]
The can of chicken broth is a closed container on the counter. The bottle of white cooking wine and the bottle of Thurston Wolfe PGV are a closed containers in the refrigerator.
The description of the Thurston Wolfe is "A Washington State Pinot Gris-Viognier, 2003. It is said to have 'peach aromas', and, startlingly, the untutored person can detect these without resorting to fantasy.
(It is also supposed to possess a delicate perfume and a moderate body; the label author at least stopped short of 'good sense of humor and likes long walks on the beach')."
Understand the commands "wash" and "rinse" as "clean".
Instead of rubbing the unwashed sage:
   now the sage is clean;
   say "You rinse off the sage. There -- ready to slice."
Instead of cutting the sage:
   say "You'd need to have a knife in hand, first."
Instead of cutting the clean sage when the player is carrying the butcher knife:
   now the sage is julienned;
   say "You slice the sage into thin strips."
Instead of cutting the unwashed sage:
   say "It came from the garden, so it won't have any strange chemicals on it, but you should still give it a rinse for dirt and bugs and so on before using it."
Instead of doing something other than examining or rubbing with the unwashed sage:
   say "It needs to be washed off."
Understand "peel [something]" as peeling.
Peeling is an action applying to one thing.
Instead of peeling the unpeeled onions:
   now the onions are peeled;
   say "You tear away the shining outer skin of the onions, leaving them pale and nekkid. Poor things."
Instead of cutting the diced onions:
   say "That seems unnecessary now."
Instead of cutting the sauteed onions:
   say "Too late; you're well past that stage."
Instead of cutting the burnt onions:
   say "There's no rescuing 'em -- the carbon isn't going to flake off, you know."
Instead of cutting the unpeeled onions:
   say "It would help to peel them first."
Instead of cutting the peeled onions:
   say "You'd need to have a knife in hand, first."
Instead of cutting the peeled onions when the player is carrying the butcher knife:
   now the onions are diced;
   say "You dice the onions neatly. Your own skill brings tears to your eyes."
Instead of opening the goat cheese:
   try peeling the goat cheese instead.
Instead of peeling the unwrapped goat cheese:
   say "The goat cheese is already unwrapped. (Stay focused, stay focused...)"
Before peeling the wrapped goat cheese when the shears are held by the player:
   try cutting the goat cheese.
Instead of peeling the snipped open goat cheese:
   now the goat cheese is unwrapped;
   record "unwrapping goat cheese" as achieved;
   say "Ah, success. The goat cheese is now free of its packet."
Instead of peeling the wrapped goat cheese:
   say "It would help to have a pair of scissors or something -- the packet resists being torn."
Instead of cutting the goat cheese:
   say "No need, at this point."
Before cutting the wrapped goat cheese when the shears are not held by the player and the shears are visible:
   say "(first picking up the shears)[command clarification break]";
   try taking the shears.
Instead of cutting the wrapped goat cheese:
   say "Something to cut with would be useful."
Instead of cutting the wrapped goat cheese when the shears are held by the player:
   now the goat cheese is snipped open;
   say "You neatly snip through the packaging with the shears."
Instead of examining the whole chicken breast:
   say "It is still entire and has yet to be pounded flat."
Instead of examining the flattened chicken breast:
   say "It has been hammered to a thickness of about a half inch. (The recipe said a quarter inch but you're pretty sure it was joking. You have never been able to achieve a quarter inch.)"
Instead of attacking the whole chicken breast:
   say "You need something heavy enough to flatten it with."
Instead of attacking the whole chicken breast when the player is holding the wooden mallet:
   now the chicken breast is flattened;
   record "flattening chicken" as achieved;
   say "You hammer away at the chicken breast, turning all your aggressions into culinary goodness. Several minutes pass. When you are done you have a broad flat chickeny pancake suitable for wrapping about a stuffing."
Before printing the name of onions:
   say "[onions condition] ".
The drawer is an openable closed container. It is part of the counter.
A tool is a kind of thing. A spatula, a spoon, a wooden mallet, some shears, and a ball of twine are tools in the drawer. A butcher knife is a tool carried by the player. Understand "scissors" as the shears.
Instead of burning something:
   say "You'll have to do that the hard way."
Some steam is fixed in place. "Dense clouds of steam fill the room."
Some smoke is fixed in place. "Smoke is beginning to collect near the ceiling."
Sauteeing Onions is a scene. Sauteeing Onions begins when the diced onions are in a hot container.
Definition: a container is hot if it is on the stove and the stove's switch is switched on.
Instead of touching the hot pan:
   say "Ow!"
Scorching Onions is a scene.
Preheating the Oven is a scene. Preheating the Oven begins when the oven's dial is heating.
Definition: a oven's dial is heating if the oven's dial has been switched on for exactly one turn.
Preheating the Oven ends when the time since Preheating the Oven began is five minutes.
When Preheating the Oven begins:
   say "The oven begins to warm up."
When Preheating the Oven ends:
   say "The oven beeps to inform you that it has reached the desired hotness."
Every turn during Sauteeing Onions:
   say "The onions sizzle in the pan."
Every turn during Scorching Onions:
   say "The onions are past their prime and are getting blacker by the moment."
Every turn during Hearing the Kettle Whistle:
   say "The kettle continues to whistle."
Instead of listening to during Hearing the Kettle Whistle:
   say "The only thing you can really hear just at the moment is the kettle."
Instead of smelling the Kitchen during Sauteeing Onions:
   try smelling the onions.
Instead of smelling the onions during Sauteeing Onions:
   say "The onions smell marvelous."
Instead of opening the oven during Preheating the Oven:
   say "It'll never heat if you open it up while it's warming."
Heating Kettle is a scene. Heating Kettle begins when the hot kettle contains cool water.
Before printing the name of the kettle when the kettle is hot:
   say "hot "
When Heating Kettle begins:
   say "The kettle begins to heat up."
Heating Kettle ends when the time since Heating Kettle began is 7 minutes.
Hearing the Kettle Whistle is a scene. Hearing the Kettle Whistle begins when Heating Kettle ends. Hearing the Kettle Whistle ends when the kettle is not hot.
When Hearing the Kettle Whistle begins:
   now the water is boiling;
   say "The kettle begins to burble and whistle shrilly."
When Hearing the Kettle Whistle ends:
   say "The kettle's screaming dies off."
Idling is a scene. Idling begins when play begins. Idling ends when Sauteeing Onions begins.
Sauteeing Onions ends in disaster when Scorching Onions begins.
Sauteeing Onions ends in success when the onions are sauteed and onions are not in a hot container.
Definition: a thing is alone if it is in a container which contains exactly one thing.
Sauteeing Onions ends in mixture when the sauteed onions are not alone.
When Sauteeing Onions ends in mixture:
   say "The mixture of things in [the holder of the onions] stops them cooking quite so fast."
When Sauteeing Onions ends in success:
   say "Nice work with the onions."
Every turn:
   if diced onions have been in a hot pan for ten turns:
      say "The onions are starting to look ready.";
      now the onions are sauteed.
Scorching Onions begins when Sauteeing Onions ends in disaster. Scorching Onions begins when the alone sauteed onions are in a hot container.
Scorching Onions ends horribly when the time since Scorching Onions began is three minutes. Scorching Onions ends in reprieve when the sauteed onions are not in a hot container. Scorching Onions ends in mixture when the sauteed onions are not alone.
When Scorching Onions ends in mixture:
   record "sauteeing onions" as achieved;
   say "The mixture of things in [the holder of the onions] stops them cooking quite so fast."
When Scorching Onions ends horribly:
   move smoke to Kitchen;
   now the onions are burnt.
When Scorching Onions ends in reprieve:
   record "sauteeing onions" as achieved;
   say "You've got the onions off heat before they can scorch -- a good sign."
Instead of taking the onions when the onions are in the pan: try taking the pan.
Instead of smelling in the presence of the smoke:
   say "The scent of the late disaster lingers in the air."
Reconstituting the Apricots is a scene.
Reconstituting the Apricots begins when the dried apricots are in a container which contains boiling water.
When Reconstituting the Apricots begins:
   say "The apricots slowly begin to plump up again."
Reconstituting the Apricots ends when the dried apricots are not in a container which contains boiling water.
Every turn:
   if dried apricots have been in a container which contains boiling water for ten turns:
      say "The apricots have turned plump(ish).";
      now the apricots are reconstituted;
      record "reconstituting apricots" as achieved.
Test sautee with "peel onions / cut onions / get onions / put onions in pan / get sage / wash sage / cut sage / wait / wait / wait / wait / wait / wait / wait / get pan".
Test apricots with "get kettle / open kettle / get apricots / put apricots in kettle / put kettle on stove / wait / wait / wait / wait / wait / wait / wait / wait / wait / wait / wait / wait / wait / wait / wait / wait / wait".
Test chicken with "open refrigerator / get chicken / open drawer / get mallet / hit breast".
Test cheese with "get scissors / get cheese / unwrap cheese".
Test me with "full score / test sautee / full score / test apricots / full score / test chicken / full score / test cheese / full score".
Test me with "full score / test sautee / full score / test apricots / full score / test chicken / full score / test cheese / full score".
Kitchen
Equipped with many familiar friends: refrigerator, stove, oven; countertop; cabinet for pans and bowls, and a drawer for your tools.

On the stove is a frying pan (empty).

On the counter are a kettle (closed), some unpeeled onions, some dried apricots, some unwashed sage and a can of chicken broth (closed).

>(Testing.)

>[1] full score
You have achieved nothing towards supper.

>[2] test sautee
(Testing.)

>[3] peel onions
You tear away the shining outer skin of the onions, leaving them pale and nekkid. Poor things.

>[4] cut onions
You dice the onions neatly. Your own skill brings tears to your eyes.

>[5] get onions
Taken.

>[6] put onions in pan
You put the diced onions into the frying pan.

The onions sizzle in the pan.

>[7] get sage
It needs to be washed off.

The onions sizzle in the pan.

>[8] wash sage
You rinse off the sage. There -- ready to slice.

The onions sizzle in the pan.

>[9] cut sage
You slice the sage into thin strips.

The onions sizzle in the pan.

>[10] wait
Time passes.

The onions sizzle in the pan.

>[11] wait
Time passes.

The onions sizzle in the pan.

>[12] wait
Time passes.

The onions sizzle in the pan.

>[13] wait
Time passes.

The onions sizzle in the pan.

>[14] wait
Time passes.

The onions sizzle in the pan.

>[15] wait
Time passes.

The onions sizzle in the pan.

>[16] wait
Time passes.

The onions sizzle in the pan.

The onions are starting to look ready.

>[17] get pan
Taken.

You've got the onions off heat before they can scorch -- a good sign.

[Your score has just gone up by three points.]

>[18] full score
9:14 am: sauteeing onions (3).

>[19] test apricots
(Testing.)

>[20] get kettle
Taken.

>[21] open kettle
You open the kettle, revealing some cool water.

>[22] get apricots
Taken.

>[23] put apricots in kettle
You put the dried apricots into the kettle.

>[24] put kettle on stove
You put the hot kettle on the stove.

The kettle begins to heat up.

>[25] wait
Time passes.

>[26] wait
Time passes.

>[27] wait
Time passes.

>[28] wait
Time passes.

>[29] wait
Time passes.

>[30] wait
Time passes.

The kettle begins to burble and whistle shrilly.

The apricots slowly begin to plump up again.

>[31] wait
Time passes.

The kettle continues to whistle.

>[32] wait
Time passes.

The kettle continues to whistle.

>[33] wait
Time passes.

The kettle continues to whistle.

>[34] wait
Time passes.

The kettle continues to whistle.

>[35] wait
Time passes.

The kettle continues to whistle.

>[36] wait
Time passes.

The kettle continues to whistle.

>[37] wait
Time passes.

The kettle continues to whistle.

>[38] wait
Time passes.

The kettle continues to whistle.

>[39] wait
Time passes.

The kettle continues to whistle.

>[40] wait
Time passes.

The kettle continues to whistle.

>[41] wait
Time passes.

The kettle continues to whistle.

The apricots have turned plump(ish).

[Your score has just gone up by three points.]

>[42] full score
9:36 am: reconstituting apricots (3).
9:14 am: sauteeing onions (3).

>[43] test chicken
(Testing.)

>[44] open refrigerator
You open the refrigerator, revealing a whole chicken breast, an egg, wrapped goat cheese, a bottle of white cooking wine and a bottle of Thurston Wolfe PGV.

The kettle continues to whistle.

>[45] get chicken
Which do you mean, the can of chicken broth or the whole chicken breast?

>[46] open drawer
You open the drawer, revealing a spatula, a spoon, a wooden mallet, some shears and a ball of twine.

The kettle continues to whistle.

>[47] get mallet
Taken.

The kettle continues to whistle.

>[48] hit breast
You hammer away at the chicken breast, turning all your aggressions into culinary goodness. Several minutes pass. When you are done you have a broad flat chickeny pancake suitable for wrapping about a stuffing.

The kettle continues to whistle.

[Your score has just gone up by one point.]

>[49] full score
9:40 am: flattening chicken (1).
9:36 am: reconstituting apricots (3).
9:14 am: sauteeing onions (3).

>[50] test cheese
(Testing.)

>[51] get scissors
Taken.

The kettle continues to whistle.

>[52] get cheese
Taken.

The kettle continues to whistle.

>[53] unwrap cheese
You neatly snip through the packaging with the shears.

Ah, success. The goat cheese is now free of its packet.

The kettle continues to whistle.

[Your score has just gone up by one point.]

>[54] full score
9:43 am: unwrapping goat cheese (1).
9:40 am: flattening chicken (1).
9:36 am: reconstituting apricots (3).
9:14 am: sauteeing onions (3).

And… at that point you're a lot less close to being done than you think. The filling -- onions, sage, apricot, and cheese -- must be assembled and put in the chicken breasts; these tied up in string; each roll dipped in egg yolk and rolled in panko crumbs; these arranged in the Calphalon pan and baked. Then later, the whole retrieved from the oven, and the breasts transferred to a plate while we deglaze the pan and concoct the sauce with the chicken broth, wine, butter, etc. Then the chicken is sliced and plated, and the sauce poured over top. Usually one also wants a side dish or two. A number of things can go interestingly wrong in this process, of course, and implementing it would require, among other things, an intelligent management of all the possible mixtures that result.