TModLoader v1.4.4.9
TModLoader source code documentation
Loading...
Searching...
No Matches

◆ GetTextureNPCShouldUse()

Asset< Texture2D > Terraria.GameContent.Profiles.LegacyNPCProfile.GetTextureNPCShouldUse ( NPC npc)
inline

Implements Terraria.GameContent.ITownNPCProfile.

Definition at line 94 of file Profiles.cs.

95 {
96 if (npc.IsABestiaryIconDummy && !npc.ForcePartyHatOn)
97 {
98 return _defaultNoAlt;
99 }
100 if (npc.altTexture == 1)
101 {
102 return _defaultParty;
103 }
104 return _defaultNoAlt;
105 }

References Terraria.GameContent.Profiles.LegacyNPCProfile._defaultNoAlt, Terraria.GameContent.Profiles.LegacyNPCProfile._defaultParty, Terraria.NPC.altTexture, Terraria.NPC.ForcePartyHatOn, and Terraria.NPC.IsABestiaryIconDummy.