示例#1
0
        protected override void OnTick()
        {
            if (Weapon != null)
            {
                Weapon.EnchantedWeilder = null;
            }

            EnchantSpell.RemoveEnchantment(Owner);
        }
示例#2
0
        public override void OnResponse(NetState sender, RelayInfo info)
        {
            AosWeaponAttribute attr = AosWeaponAttribute.HitLightning;

            switch (info.ButtonID)
            {
                default:
                    m_Caster.SendLocalizedMessage(1080132); //You decide not to enchant your weapon.
                    return;
                case 1: //Hit Lightning
                    {
                        attr = AosWeaponAttribute.HitLightning;
                        break;
                    }
                case 2: //Hit Fireball
                    {
                        attr = AosWeaponAttribute.HitFireball;
                        break;
                    }
                case 3: //Hit Harm
                    {
                        attr = AosWeaponAttribute.HitHarm;
                        break;
                    }
                case 4: //Hit Magic Arrow
                    {
                        attr = AosWeaponAttribute.HitMagicArrow;
                        break;
                    }
                case 5: //Hit Dispel
                    {
                        attr = AosWeaponAttribute.HitDispel;
                        break;
                    }
            }

            Spell spell = new EnchantSpell(m_Caster, m_Scroll, m_Weapon, attr);
            spell.Cast();
        }
示例#3
0
 protected override void OnTick()
 {
     EnchantSpell.RemoveEnchantment(Owner);
 }