Make mimics mimicing walls or trees also block light

This commit is contained in:
Pasi Kallinen
2016-01-06 01:44:18 +02:00
parent a049cd070b
commit db4120012d
5 changed files with 15 additions and 6 deletions

View File

@@ -159,6 +159,16 @@ struct monst {
#define is_vampshifter(mon) \
((mon)->cham == PM_VAMPIRE || (mon)->cham == PM_VAMPIRE_LORD \
|| (mon)->cham == PM_VLAD_THE_IMPALER)
/* mimic appearances that block vision/light */
#define is_lightblocker_mappear(mon) \
(is_obj_mappear(mon, BOULDER) || \
((mon)->m_ap_type == M_AP_FURNITURE \
&& ((mon)->mappearance == S_hcdoor \
|| (mon)->mappearance == S_vcdoor \
|| (mon)->mappearance < S_ndoor /* = walls */ \
|| (mon)->mappearance == S_tree)))
#define is_door_mappear(mon) ((mon)->m_ap_type == M_AP_FURNITURE \
&& ((mon)->mappearance == S_hcdoor || (mon)->mappearance == S_vcdoor))
#define is_obj_mappear(mon,otyp) ((mon)->m_ap_type == M_AP_OBJECT \