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

@ -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 )
{