burrower now forces seeing the debuffs in its bestiary

This commit is contained in:
doze-zoze committed 2026-02-07 14:43:55 -06:00
1 parent 220beb26b5
commit 9609f44c33
2 files changed
+9 -4

No files matched your search

+3 -1
View File
@@ -25,6 +25,7 @@ using CalamityMod.NPCs.AstrumDeus;
using CalamityMod.NPCs.Bumblebirb;
using CalamityMod.NPCs.CalClone;
using CalamityMod.NPCs.CeaselessVoid;
using CalamityMod.NPCs.Deconstructors;
using CalamityMod.NPCs.DesertScourge;
using CalamityMod.NPCs.DevourerofGods;
using CalamityMod.NPCs.DraedonLabThings;
@@ -6069,7 +6070,8 @@ namespace CalamityMod.NPCs
];
// Insert the debuff info into the NPC's bestiary entry
bestiaryEntry.Info.Insert(0, new BestiaryDebuffInfo(elements));
bool force = npc.type == ModContent.NPCType<Burrower>(); //Force Burrower to always show the debuff section
bestiaryEntry.Info.Insert(0, new BestiaryDebuffInfo(elements,force));
// Add the Astral Infection to the Enchanted Nightcrawler's entry as it spawns there now
if (npc.type == NPCID.EnchantedNightcrawler)
+6 -3
View File
@@ -1,4 +1,5 @@
using Microsoft.Xna.Framework;
using System.Linq;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
using Terraria;
using Terraria.GameContent.Bestiary;
@@ -12,10 +13,12 @@ namespace CalamityMod.UI.DebuffSystem
public class BestiaryDebuffInfo : IBestiaryInfoElement, IBestiaryPrioritizedElement, ICategorizedBestiaryInfoElement
{
public string[] elements;
public bool force = false;
public BestiaryDebuffInfo(string[] elements)
public BestiaryDebuffInfo(string[] elements, bool force = false)
{
this.elements = elements;
this.force = force;
}
// Below base stats (damage/defense/etc)
@@ -26,7 +29,7 @@ namespace CalamityMod.UI.DebuffSystem
public UIElement ProvideUIElement(BestiaryUICollectionInfo info)
{
// Don't show debuff info until stats are unlocked
if (info.UnlockState < BestiaryEntryUnlockState.CanShowStats_2)
if (info.UnlockState < BestiaryEntryUnlockState.CanShowStats_2 && !force)
{
return null;
}