missile light sources
Throwing or kicking a lit lamp, lit candle, or lit potion of oil wasn't giving off any light as it travelled to its destination. Now it does, and dungeon features, objects, or monsters that are temporarily seen as it moves from square to square till appear on the map. In the monster case, they go away as soon as the light moves beyond range, but when it finishes moving the "remembered, unseen monster" glyph will be drawn at their location. I think that part has some room for improvement, but mapping temporarily seen terrain features is the primary impetus for this change. Also, any message delivery while the "lit missile" travelled still showed its light around the hero. Noticeable for lamps or stacks of sufficient candles if hero has no other light source. This cannibalizes the monst->mburied bit for temporarily seeing a monster. It has been present but unused for ages. I needed to replace a couple of vision macros to make sure they didn't examine it any more so that overloading for transient lighting doesn't introduce any vision oddities. For version $NEXT, monst->mtemplit can be given its own bit. It is only set during bhit() execution and cleared by the time that returns, so has no effect on save files.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* NetHack 3.6 rm.h $NHDT-Date: 1547255911 2019/01/12 01:18:31 $ $NHDT-Branch: NetHack-3.6.2-beta01 $:$NHDT-Revision: 1.60 $ */
|
||||
/* NetHack 3.6 rm.h $NHDT-Date: 1559994624 2019/06/08 11:50:24 $ $NHDT-Branch: NetHack-3.6 $:$NHDT-Revision: 1.61 $ */
|
||||
/* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
|
||||
/*-Copyright (c) Pasi Kallinen, 2017. */
|
||||
/* NetHack may be freely redistributed. See license for details. */
|
||||
@@ -624,12 +624,16 @@ extern dlevel_t level; /* structure describing the current level */
|
||||
/*
|
||||
* Macros for encapsulation of level.monsters references.
|
||||
*/
|
||||
#if 0
|
||||
#define MON_AT(x, y) \
|
||||
(level.monsters[x][y] != (struct monst *) 0 \
|
||||
&& !(level.monsters[x][y])->mburied)
|
||||
#define MON_BURIED_AT(x, y) \
|
||||
(level.monsters[x][y] != (struct monst *) 0 \
|
||||
&& (level.monsters[x][y])->mburied)
|
||||
#else /* without 'mburied' */
|
||||
#define MON_AT(x, y) (level.monsters[x][y] != (struct monst *) 0)
|
||||
#endif
|
||||
#ifdef EXTRA_SANITY_CHECKS
|
||||
#define place_worm_seg(m, x, y) \
|
||||
do { \
|
||||
|
||||
Reference in New Issue
Block a user