Exemple #1
0
    public static void Apply(GameObject target)
    {
        EtherealStatus targetStatus = target.GetComponent <EtherealStatus>();

        if (targetStatus != null)
        {
            targetStatus.Apply();
        }
    }
Exemple #2
0
        private void Hit(GameObject target)
        {
            if (target != null)
            {
                Hurtbox otherHurtbox = target.GetComponent <Hurtbox>();

                if (otherHurtbox != null && !sourceTeam.IsAgainst(otherHurtbox.Team))
                {
                    otherHurtbox.GetHealed(healAmount);

                    onHeal.Invoke();

                    if (makeTargetEthereal)
                    {
                        EtherealStatus.Apply(target);
                    }

                    if (destroySelfOnHit)
                    {
                        Destroy(gameObject);
                    }
                }
            }
        }