]> granicus.if.org Git - nethack/commitdiff
more monster alignment
authornethack.rankin <nethack.rankin>
Thu, 6 Oct 2005 03:45:20 +0000 (03:45 +0000)
committernethack.rankin <nethack.rankin>
Thu, 6 Oct 2005 03:45:20 +0000 (03:45 +0000)
     Simplify is_lminion(); as a result, several source files no longer
need access to epri.h.  (mondata.c already could have lived without it;
eshk.h as well.)

Makefile dependency changes:
  mondata.{c,o} -- doesn't need epri.h or eshk.h
  monmove.{c,o} -- doesn't need epri.h
  wizard.{c,o}  -- ditto
  pline.{c,o}   -- ditto (yesterday's patch)

include/mondata.h
src/mondata.c
src/monmove.c
src/wizard.c

index 81c0c86b1ef00f0d24995bc51c60c33f43eb1b9e..9c63715f86d861d7589e0f121cde002e19e6d2e5 100644 (file)
@@ -1,4 +1,4 @@
-/*     SCCS Id: @(#)mondata.h  3.5     2005/01/31      */
+/*     SCCS Id: @(#)mondata.h  3.5     2005/10/05      */
 /* Copyright (c) 1989 Mike Threepoint                            */
 /* NetHack may be freely redistributed.  See license for details. */
 
 #define resists_ston(mon)      (((mon)->mintrinsics & MR_STONE) != 0)
 
 #define is_lminion(mon)                (is_minion((mon)->data) && \
-                                (mon)->data->maligntyp >= A_COALIGNED && \
-                                ((mon)->data != &mons[PM_ANGEL] || \
-                                 EPRI(mon)->shralign > 0))
-
+                                mon_aligntyp(mon) == A_LAWFUL)
 #define is_flyer(ptr)          (((ptr)->mflags1 & M1_FLY) != 0L)
 #define is_floater(ptr)                ((ptr)->mlet == S_EYE)
 #define is_clinger(ptr)                (((ptr)->mflags1 & M1_CLING) != 0L)
index 5f7d2ce8025086e9dab3c33b70df2bd443323818..9a219ac1426b6ab686c24325a6f10e5bc1cacc74 100644 (file)
@@ -1,10 +1,8 @@
-/*     SCCS Id: @(#)mondata.c  3.5     2005/09/01      */
+/*     SCCS Id: @(#)mondata.c  3.5     2005/10/05      */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /* NetHack may be freely redistributed.  See license for details. */
 
 #include "hack.h"
-#include "eshk.h"
-#include "epri.h"
 
 /*     These routines provide basic data for any type of monster. */
 
index f43549b6b10770b6881219731dcabe75e7f927c9..c757ec8b469208890fbc67c9a0cbc656edd4c4a3 100644 (file)
@@ -1,11 +1,10 @@
-/*     SCCS Id: @(#)monmove.c  3.5     2005/06/22      */
+/*     SCCS Id: @(#)monmove.c  3.5     2005/10/05      */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /* NetHack may be freely redistributed.  See license for details. */
 
 #include "hack.h"
 #include "mfndpos.h"
 #include "artifact.h"
-#include "epri.h"
 
 extern boolean notonhead;
 
index 8017a767c8b1af668a15441616d02f5786ecc28a..62f5c3eb30e58c6230fef1afe095a2d918c053e9 100644 (file)
@@ -1,4 +1,4 @@
-/*     SCCS Id: @(#)wizard.c   3.5     2005/03/19      */
+/*     SCCS Id: @(#)wizard.c   3.5     2005/10/05      */
 /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
 /* NetHack may be freely redistributed.  See license for details. */
 
@@ -9,7 +9,6 @@
 
 #include "hack.h"
 #include "qtext.h"
-#include "epri.h"
 
 extern const int monstr[];