Magic-number elimination.
[open-adventure.git] / actions.c
index 34d0e48ef8d291bbfd364bf0bedfb73908cebe3a..48e987f8e67f86d84504b29a5f465085ff0afe03 100644 (file)
--- a/actions.c
+++ b/actions.c
@@ -477,7 +477,7 @@ static int discard(token_t verb, token_t obj, bool just_do_it)
                     /* FIXME: Arithmetic on state numbers */
                     int k = 2 - game.prop[RUG];
                     game.prop[RUG] = k;
-                    if (k == 2)
+                    if (k == RUG_HOVER)
                         k = objects[SAPPH].plac;
                     move(RUG + NOBJECTS, k);
                 }
@@ -1136,8 +1136,6 @@ static int throw (struct command_t *command)
  *  (Only way to do so!)  Axe also special for dragon, bear, and
  *  troll.  Treasures special for troll. */
 {
-    if (TOTING(ROD2) && command->obj == ROD && !TOTING(ROD))
-        command->obj = ROD2;
     if (!TOTING(command->obj)) {
         rspeak(actions[command->verb].message);
         return GO_CLEAROBJ;