! Through the Looking-Glass ! An Inform tutorial by Gareth Rees ! All rights given away ! Version 2 Constant Story "THROUGH THE LOOKING GLASS"; Constant Headline "^An Interactive Tutorial^by Gareth Rees^"; Constant DEBUG; Include "parser"; Include "verblib"; Include "grammar"; [ Initialise; location = Drawing_Room; print "^^^^^It's a cold winter day outside, but in the looking-glass house it's summer. All you need to do is pretend there's a way of getting through into it somehow...^^"; ]; [ UntangleSub; "What curious ideas you have!"; ]; Verb "roll" "untangle" "wind" * noun -> Untangle * "up" noun -> Untangle * noun "up" -> Untangle; Object Drawing_Room "Drawing room" has light with name "snow", description "The gentle sound of snow against the window pane suggests that it's cold outside, and you're glad to be here in the warmth. The drawing-room is reflected in the large looking-glass on the wall above the mantelpiece, and a very comfortable room it is too, with a warm hearth, a soft rug and an arm-chair that you can curl up and sleep in."; Object red_queen "red queen" with name "red" "queen", description "She's a fierce little chess piece."; Object chess_board "chess board" Drawing_Room has supporter with name "chess" "board" "checker" "chequer" "chessboard", initial "An abandoned chess board lies on the floor.", description "It's left here from the game you were playing just now, but the pieces are all missing - the kittens will insist on playing with them."; Object hearth "hearth" Drawing_Room has scenery with name "hearth" "fire" "place" "fireplace", description "Looking at the hearth, you wonder if they have a hearth in the looking-glass house. You can never tell by looking, unless your fire smokes, and then smoke comes up in the looking-glass room too - but that may be only pretence, just to make it look as if they had a fire."; Object rug "rug" Drawing_Room has concealed static supporter enterable ! general if you've found the red queen under it with name "hearthrug" "hearth-rug" "rug" "indian" "arabian" "beautiful" "soft", description "It's a beautiful rug, made in some far off country, perhaps India or Araby, wherever those might be.", before [; Take: "The rug is much too large and heavy for you to carry."; Push,Pull: "But a hearth-rug is meant to be next to the hearth!"; LookUnder: if (player in self) "You try to lift up a corner of the rug, but fail. After a while, you realise that this is because you are standing on it. How curious the world is!"; if (self hasnt general) { give self general; move red_queen to player; "You lift up a corner of the rug and, peering underneath, discover the red queen from the chess set."; } ]; Object armchair "arm-chair" Drawing_Room has static concealed supporter enterable ! general if its by the mantelpiece with name "arm" "chair" "armchair" "arm-chair", description "It's a huge arm-chair, the perfect place for a kitten or a little girl to curl up in and doze.", before [; Push,Pull: ! code to check for the kittens if (self has general) { give self ~general; "You push the arm-chair away from the hearth."; } give self general; "You push the arm-chair over to the hearth."; ]; Object mantelpiece "mantelpiece" Drawing_Room has concealed supporter enterable with name "mantel" "mantelpiece", description "It's higher off the ground than your head, but it looks wide enough and sturdy enough to support you.", before [; Enter,Climb: if (player notin armchair) "The mantelpiece is much too high to climb up onto."; if (armchair hasnt general) "You can't reach the mantelpiece from here."; if (children(player) > 0) "Your hands are too full."; PutOn,LetGo: if (player notin self && (player notin armchair || armchair hasnt general)) "The mantelpiece is so high that you can't reach."; ]; Object mirror "looking-glass" Drawing_Room has static concealed with name "mirror" "looking" "glass" "looking-glass", description [; if (player in mantelpiece) "Strangely, the glass is beginning to melt away, just like a bright silvery mist."; if (player in armchair) "In the looking-glass you can see the drawing-room of the looking-glass house. What you can see is very much the same as this drawing-room, only all reversed, left for right. But you are sure that out of the corners of the glass, where you can't see, the looking-glass world is quite different from yours."; "In the looking-glass you can see the ceiling of the drawing-room of the looking-glass house. It looks much the same as the ceiling of your drawing-room."; ], before [; if (action ~= ##Examine && player notin mantelpiece) "You can't reach the looking-glass from where you're standing."; Touch,Pull,Push: "Your hand goes right through the silvery mist!"; Enter: ! Really, move Alice to the looking-glass house. deadflag = 2; "Your hand goes right through the silvery mist, and in another moment the rest of you follows, and you are through the glass..."; ]; Object worsted "ball of worsted" Drawing_Room ! general if its in a tangle with name "ball" "of" "worsted" "fine" "blue" "wool", initial "A discarded ball of worsted lies on the floor here.", description [; if (self has general) "It's in a terrible tangle. All that time you spent rolling it up, and now look at it!"; "It's a ball of fine blue wool, all rolled up in preparation for some embroidery."; ], before [; Untangle: "You're as quick as can be at rolling up balls of wool, though you say so yourself! Soon it's neat and tidy again."; ];