change gy.youmonst
Add a pointer to struct you, and put umonst there. Eliminate the youmonst struct in gy. The naming convention better matches the other u related fields, and u.umonst has the same level of indirection as other monst pointers. The u.umonst pointer is cleared prior to saving the parent u (struct you), and u.umonst is reestablished upon restore. Invalidates existing saves and bones due to the presence of the added pointer field in struct you.
This commit is contained in:
+3
-3
@@ -253,11 +253,11 @@
|
||||
((int) U_AP_TYPE == M_AP_NOTHING) \
|
||||
? hero_glyph \
|
||||
: ((int) U_AP_TYPE == M_AP_FURNITURE) \
|
||||
? cmap_to_glyph((int) gy.youmonst.mappearance) \
|
||||
? cmap_to_glyph((int) u.umonst->mappearance) \
|
||||
: ((int) U_AP_TYPE == M_AP_OBJECT) \
|
||||
? objnum_to_glyph((int) gy.youmonst.mappearance) \
|
||||
? objnum_to_glyph((int) u.umonst->mappearance) \
|
||||
/* else U_AP_TYPE == M_AP_MONSTER */ \
|
||||
: monnum_to_glyph((int) gy.youmonst.mappearance, Ugender)))
|
||||
: monnum_to_glyph((int) u.umonst->mappearance, Ugender)))
|
||||
|
||||
/*
|
||||
* NetHack glyphs
|
||||
|
||||
Reference in New Issue
Block a user