Second part of fix for "fee fie foe foo" and "fum", with test.
[open-adventure.git] / actions.c
index 09f7836b616fa9727ee7235c0338ff645e1bdc77..fe6daa10ea0004d9db5abd393659851021fc0196 100644 (file)
--- a/actions.c
+++ b/actions.c
@@ -187,9 +187,10 @@ static phase_codes_t attack(command_t command)
 }
 
 static phase_codes_t bigwords(vocab_t id)
-/*  FEE FIE FOE FOO (AND FUM).  Advance to next state if given in proper order.
- *  Look up foo in special section of vocab to determine which word we've got.
- *  Last word zips the eggs back to the giant room (unless already there). */
+/* Only called on FEE FIE FOE FOO (AND FUM).  Advance to next state if given
+ * in proper order. Look up foo in special section of vocab to determine which
+ * word we've got. Last word zips the eggs back to the giant room (unless 
+ * already there). */
 {
     if ((game.foobar == WORD_EMPTY && id == FEE) ||
         (game.foobar == FEE && id == FIE) ||
@@ -206,6 +207,8 @@ static phase_codes_t bigwords(vocab_t id)
             (TOTING(EGGS) && game.loc == objects[EGGS].plac)) {
             rspeak(NOTHING_HAPPENS);
             return GO_CLEAROBJ;
+       } else if (id == FUM) {
+           goto fum;
         } else {
             /*  Bring back troll if we steal the eggs back from him before
              *  crossing. */
@@ -222,12 +225,13 @@ static phase_codes_t bigwords(vocab_t id)
             return GO_CLEAROBJ;
         }
     } else {
+    fum:
         if (game.loc == LOC_GIANTROOM) {
             rspeak(START_OVER);
         } else {
-            /* This is new begavior in Open Adventure - sounds better when
+            /* This is new behavior in Open Adventure - sounds better when
              * player isn't in the Giant Room. */
-            rspeak(WELL_POINTLESS);
+            rspeak(NOTHING_HAPPENS);
         }
         game.foobar = WORD_EMPTY;
         return GO_CLEAROBJ;