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

◆ CanCatchNPC()

static ? bool Terraria.ModLoader.CombinedHooks.CanCatchNPC ( Player player,
NPC npc,
Item item )
inlinestatic

Definition at line 314 of file CombinedHooks.cs.

315 {
316 bool? ret = null;
317 if (Update(PlayerLoader.CanCatchNPC(player, npc, item)) && Update(ItemLoader.CanCatchNPC(item, npc, player)))
318 {
319 Update(NPCLoader.CanBeCaughtBy(npc, item, player));
320 }
321 else
322 _ = 0;
323 return ret;
324 bool Update(bool? b)
325 {
326 return !((!(ret ?? (ret = b))) ?? false);
327 }
328 }

References Terraria.ModLoader.NPCLoader.CanBeCaughtBy(), Terraria.ModLoader.ItemLoader.CanCatchNPC(), and Terraria.ModLoader.PlayerLoader.CanCatchNPC().

Referenced by Terraria.NPC.CheckCatchNPC().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: