public static bool CanBeHitByNPC(Player player, NPC npc, ref int cooldownSlot) { foreach (ModPlayer modPlayer in player.modPlayers) { if (!modPlayer.CanBeHitByNPC(npc, ref cooldownSlot)) { return false; } } return true; }