nickmattinson / ZXYZ

Top-Down 2D Dungeon Crawler
1 stars 0 forks source link

EnemyShootThroughWalls #103

Closed MikeMMattinson closed 2 months ago

MikeMMattinson commented 2 months ago

Prevent enemy from shooting at player through walls.

git fetch origin
git checkout 103-enemyshootthroughwalls
MikeMMattinson commented 2 months ago

image

MikeMMattinson commented 2 months ago

you can see blue enemy is within range and clear line of sight, so shooting at player. There are two other enemies that are trying to attack the player but they are out of range. one of them has clear line of sight, the other does not.