Fix monster visbility

This commit is contained in:
Miloslav Číž 2020-08-22 22:34:18 +02:00
parent 68285eebfa
commit 53301eca94
2 changed files with 3 additions and 2 deletions

View File

@ -184,6 +184,7 @@ done:
- add universal corpse sprite? - add universal corpse sprite?
- if space left, try blurring (lerp) the level background, see how it looks - if space left, try blurring (lerp) the level background, see how it looks
- replace textures in distace with constant color for performance (setting)? - replace textures in distace with constant color for performance (setting)?
- enemies close to a wall often don't get drawn
scratched: scratched:
- try to make z-buffer 3 line instead of 1D, possibly like this (to keep - try to make z-buffer 3 line instead of 1D, possibly like this (to keep

2
main.c
View File

@ -199,7 +199,7 @@ typedef struct
#define SFG_MR_TYPE(mr) \ #define SFG_MR_TYPE(mr) \
(SFG_MONSTER_INDEX_TO_TYPE(((mr).stateType & SFG_MONSTER_MASK_TYPE) >> 4)) (SFG_MONSTER_INDEX_TO_TYPE(((mr).stateType & SFG_MONSTER_MASK_TYPE) >> 4))
#define SFG_MONSTER_COORD_TO_RCL_UNITS(c) (c * 256) #define SFG_MONSTER_COORD_TO_RCL_UNITS(c) ((RCL_UNITS_PER_SQUARE / 8) + c * 256)
#define SFG_MONSTER_COORD_TO_SQUARES(c) (c / 4) #define SFG_MONSTER_COORD_TO_SQUARES(c) (c / 4)
#define SFG_ELEMENT_COORD_TO_RCL_UNITS(c) \ #define SFG_ELEMENT_COORD_TO_RCL_UNITS(c) \