Healthbars shouldn't spawn for boss brains unless they're visible.

This commit is contained in:
Mari the Deer 2022-09-19 01:02:40 +02:00
commit 6e3a6bb0e3
2 changed files with 8 additions and 4 deletions

View file

@ -1,3 +1,3 @@
[default]
SWWM_MODVER="\cyDEMOLITIONIST \cw1.3pre r477 \cu(Mon 19 Sep 01:02:21 CEST 2022)\c-";
SWWM_SHORTVER="\cw1.3pre r477 \cu(2022-09-19 01:02:21)\c-";
SWWM_MODVER="\cyDEMOLITIONIST \cw1.3pre r478 \cu(Mon 19 Sep 01:02:40 CEST 2022)\c-";
SWWM_SHORTVER="\cw1.3pre r478 \cu(2022-09-19 01:02:40)\c-";

View file

@ -233,8 +233,12 @@ Class SWWMQuickCombatTracker : Inventory
static SWWMQuickCombatTracker Update( SWWMHandler hnd, PlayerInfo p, Actor target, int damage = 0 )
{
if ( target.bNODAMAGE ) return null; // no-damage entities get no healthbars
if ( target is 'LampMoth' ) return null; // also don't give healthbars to moths
// no-damage entities get no healthbars
if ( target.bNODAMAGE ) return null;
// also don't give healthbars to moths
if ( target is 'LampMoth' ) return null;
// don't give them to boss brains unless visible
if ( (target is 'BossBrain') && !p.Camera.CheckSight(target,SF_IGNOREVISIBILITY|SF_IGNOREWATERBOUNDARY) ) return null;
SWWMQuickCombatTracker t = null;
for ( Inventory i=target.inv; i; i=i.inv )
{