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

◆ SetBiomeAffection()

NPCHappiness Terraria.ModLoader.NPCHappiness.SetBiomeAffection ( IShoppingBiome biome,
AffectionLevel affectionLevel )
inline

Definition at line 71 of file NPCHappiness.cs.

72 {
73 List<IShopPersonalityTrait> shopModifiers = Main.ShopHelper._database.GetOrCreateProfileByNPCID(NpcType).ShopModifiers;
76 if (biomePreferenceList == null)
77 {
78 if (removal)
79 {
80 return this;
81 }
83 }
86 if (existingEntry != null)
87 {
88 if (removal)
89 {
91 return this;
92 }
93 existingEntry.Affection = affectionLevel;
94 return this;
95 }
97 return this;
98 }

References Terraria.ModLoader.NPCHappiness.NpcType, and Terraria.Main.ShopHelper.

Referenced by Terraria.ModLoader.NPCHappiness.SetBiomeAffection< T >().

+ Here is the caller graph for this function: