zeromonst

Make 'zeromonst' global instead of local to makemon.c.  Its address
isn't used as a special value like &zeroobj, but it is useful to
have available for initializing various pseudo-monsters.

modified:
  include/decl.h
  src/decl.c, makemon.c, mkobj.c, mplayer.c, teleport.c
This commit is contained in:
PatR
2016-03-26 16:42:24 -07:00
parent 862d37c77a
commit d6fa06f8e8
6 changed files with 15 additions and 12 deletions

View File

@@ -243,7 +243,8 @@ E NEARDATA struct obj *migrating_objs;
E NEARDATA struct obj *billobjs;
E NEARDATA struct obj *current_wand, *thrownobj, *kickedobj;
E NEARDATA struct obj zeroobj; /* init'd and defined in decl.c */
E NEARDATA struct obj zeroobj; /* for init; &zeroobj used as special value */
E NEARDATA anything zeroany; /* init'd and defined in decl.c */
#include "you.h"
@@ -256,7 +257,8 @@ E NEARDATA struct u_realtime urealtime;
#include "pm.h"
#endif
E NEARDATA struct monst youmonst; /* init'd and defined in decl.c */
E NEARDATA struct monst zeromonst; /* for init of new or temp monsters */
E NEARDATA struct monst youmonst; /* monster details when hero is poly'd */
E NEARDATA struct monst *mydogs, *migrating_mons;
E NEARDATA struct mvitals {