v2.2.0: crystal guardians no longer show heal particles out of FOV

This commit is contained in:
Evan Debenham
2023-10-05 11:02:41 -04:00
parent 88f916088c
commit 28ebf264f9

View File

@@ -69,7 +69,9 @@ public class CrystalGuardian extends Mob{
if (recovering){
throwItems();
HP = Math.min(HT, HP+5);
sprite.emitter().burst(Speck.factory(Speck.HEALING), 1);
if (Dungeon.level.heroFOV[pos]) {
sprite.emitter().burst(Speck.factory(Speck.HEALING), 1);
}
if (HP == HT){
recovering = false;
if (sprite instanceof CrystalGuardianSprite) ((CrystalGuardianSprite) sprite).endCrumple();