Exemplo n.º 1
0
        public override void Apply(Character me, Character other)
        {
            base.Apply(me, other);
            Effect effect = new EffectShield();

            me.Effects.Add(effect);
            effect.Init(me);
        }
Exemplo n.º 2
0
        public override SkillEffect[] CreateAdditionalSkillEffects(Skill sk, SkillEffect[] effects)
        {
            if (sk.GetSkillId() == SkillId.SneezeShot)
            {
                SkillEffect[] newEffects = new SkillEffect[1];
                newEffects[0] = new EffectShield(-0.5f, AddValueByLevel(DURATION, AMOUNT_LEVEL_ADD));

                return(newEffects);
            }

            return(null);
        }
Exemplo n.º 3
0
        public override SkillEffect[] CreateAdditionalSkillEffects(Skill sk, SkillEffect[] effects)
        {
            if (sk.GetSkillId() == SkillId.PoisonShot)
            {
                PoisonShot    ps         = sk as PoisonShot;
                SkillEffect[] newEffects = new SkillEffect[1];
                newEffects[0] = new EffectShield(-0.5f, ps.duration);

                return(newEffects);
            }

            return(null);
        }
Exemplo n.º 4
0
        public override SkillEffect[] CreateAdditionalSkillEffects(Skill sk, SkillEffect[] effects)
        {
            if (sk.GetSkillId() == SkillId.CellFury)
            {
                CellFury cf = sk as CellFury;

                SkillEffect[] ef = new SkillEffect[1];
                ef[0] = new EffectShield(AddValueByLevel(POWER, LEVEL_ADD) / 100f, cf.duration);
                return(ef);
            }

            return(null);
        }
Exemplo n.º 5
0
        public override SkillEffect[] CreateAdditionalSkillEffects(Skill sk, SkillEffect[] effects)
        {
            ActiveSkill aa = Owner.MeleeSkill;

            if (aa != null && sk.GetSkillId() == aa.GetSkillId())
            {
                if (sk.Owner.HasEffectOfSkill(SkillId.Haste))
                {
                    SkillEffect[] ef = new SkillEffect[1];
                    ef[0] = new EffectShield(1.0f, 1f).TargetOwner();
                    return(ef);
                }
            }

            return(null);
        }
Exemplo n.º 6
0
    public void ExcuteEffect(EffectBase effect, ESide side)
    {
        if (effect != null && effect is EffectShield)
        {
            EffectShield effectShield = effect as EffectShield;
            m_start   = true;
            m_endTime = effectShield.m_duringTime + Time.time;
            GameObject go = null;
            if (side == ESide.AI)
            {
                go = m_effectAI;
            }
            else if (side == ESide.Player)
            {
                go = m_effectPlayer;
            }

            if (go != null)
            {
                go.SetActive(true);
            }
        }
    }