Ejemplo n.º 1
0
        internal void InvokePlayerHealEvent(Player player, ref float amount, ref bool allow)
        {
            var ev = new PlayerHealEventArgs()
            {
                Player = player, Amount = amount, Allow = allow
            };

            PlayerHealEvent?.Invoke(ev);

            amount = ev.Amount;
            allow  = ev.Allow;
        }
Ejemplo n.º 2
0
        internal static void InvokePlayerHealEvent(Player player, ref float amount, out bool allow)
        {
            allow = true;
            if (PlayerHealEvent == null)
            {
                return;
            }

            var ev = new PlayerHealEvent
            {
                Player = player,
                Amount = amount,
                Allow  = allow
            };

            PlayerHealEvent.Invoke(ev);

            allow  = ev.Allow;
            amount = ev.Amount;
        }