public static bool AlertPlayer(Animal __instance, ref Player newPlayer, ref bool sendToPack) { // Attacking player var cancel = false; OnAnimalAttackingPlayer?.Invoke(__instance, ref newPlayer, ref sendToPack, ref cancel); return !cancel; }
private static bool AlertPlayer(Animal __instance, ref Player newPlayer, ref bool sendToPack) { // Attacking player bool cancel = false; OnAnimalAttackingPlayer?.Invoke(__instance, ref newPlayer, ref sendToPack, out cancel); return(!cancel); }