Removed helper function
authorNHOrus <jy6x2b32pie9@yahoo.com>
Mon, 3 Jul 2017 02:59:57 +0000 (05:59 +0300)
committerNHOrus <jy6x2b32pie9@yahoo.com>
Mon, 3 Jul 2017 02:59:57 +0000 (05:59 +0300)
actions.c

index a6f686d5115477059387e896308e65a9d498e08d..44fc2012e3f7f8085b6db7f2e03c033f926bd2ff 100644 (file)
--- a/actions.c
+++ b/actions.c
@@ -1083,16 +1083,6 @@ static int wake(token_t verb, token_t obj)
     }
 }
 
-static token_t birdspeak(void)
-{
-    switch (game.prop[BIRD]) {
-    case BIRD_CAGED:
-        return CAGE_FLY;
-    default:
-        return FREE_FLY;
-    }
-}
-
 static int wave(token_t verb, token_t obj)
 /* Wave.  No effect unless waving rod at fissure or at bird. */
 {
@@ -1111,15 +1101,15 @@ static int wave(token_t verb, token_t obj)
         return GO_CLEAROBJ;
     } else {
         if (game.closed) {
-            rspeak(birdspeak());
+            rspeak((game.prop[BIRD] == BIRD_CAGED) ? CAGE_FLY : FREE_FLY);
             return GO_DWARFWAKE;
         }
         if (game.closng || !AT(FISSURE)) {
-            rspeak(birdspeak());
+            rspeak((game.prop[BIRD] == BIRD_CAGED) ? CAGE_FLY : FREE_FLY);
             return GO_CLEAROBJ;
         }
         if (HERE(BIRD))
-            rspeak(birdspeak());
+            rspeak((game.prop[BIRD] == BIRD_CAGED) ? CAGE_FLY : FREE_FLY);
 
         /* FIXME: Arithemetic on property values */
         game.prop[FISSURE] = 1 - game.prop[FISSURE];