Exemplo n.º 1
0
        public override void CheckProgress()
        {
            if (System.From.Map == Map.Malas && System.From.InRange(new Point3D(1076, 450, -84), 5))
            {
                HordeMinionFamiliar hmf = Spells.Necromancy.SummonFamiliarSpell.Table[System.From] as HordeMinionFamiliar;

                if (hmf != null && hmf.InRange(System.From, 5) && hmf.TargetLocation == Point2D.Zero)
                {
                    System.From.SendLocalizedMessage(1060113);                       // You instinctively will your familiar to fetch the scroll for you.
                    hmf.TargetLocation = new Point2D(1076, 450);
                }
            }
        }
Exemplo n.º 2
0
        public override void CheckProgress()
        {
            if (this.System.From.Map == Map.Malas && this.System.From.InRange(new Point3D(1076, 450, -84), 5))
            {
                HordeMinionFamiliar hmf = Spells.Necromancy.SummonFamiliarSpell.Table[this.System.From] as HordeMinionFamiliar;

                if (hmf != null && hmf.InRange(this.System.From, 5) && !hmf.QuestOverride)
                {
                    this.System.From.SendLocalizedMessage(1060113); // You instinctively will your familiar to fetch the scroll for you.
                    //hmf.TargetLocation = new Point2D(1076, 450);

                    if (hmf.AIObject != null)
                    {
                        hmf.CurrentSpeed  = .2;
                        hmf.QuestOverride = true;
                        hmf.AIObject.MoveTo(new Point3D(1076, 450, -89), false, 0);
                    }
                }
            }
        }
Exemplo n.º 3
0
        public override void OnCast()
        {
            if (CheckSequence())
            {
                try
                {
                    BaseCreature creature = null;
                    if ((Core.UOAI || Core.UOAR) && Caster.Skills.SpiritSpeak.Value > 50 && (Caster.Skills.SpiritSpeak.Value / 100) >= Utility.RandomDouble())
                    {
                        creature = new HordeMinionFamiliar();
                        creature.ControlSlots = 3;
                    }
                    else
                    {
                        creature = (BaseCreature)Activator.CreateInstance(m_Types[Utility.Random(m_Types.Length)]);
                        creature.ControlSlots = 2;
                    }

                    TimeSpan duration;

                    if (Core.AOS)
                    {
                        duration = TimeSpan.FromSeconds((2 * Caster.Skills.Magery.Fixed) / 5);
                    }
                    else
                    {
                        duration = TimeSpan.FromSeconds(4.0 * Caster.Skills[SkillName.Magery].Value);
                    }

                    SpellHelper.Summon(creature, Caster, 0x215, duration, false, false);
                }
                catch (Exception ex) { EventSink.InvokeLogException(new LogExceptionEventArgs(ex)); }
            }

            FinishSequence();
        }