Example #1
0
        public static void ToGate(Mobile target)
        {
            if (TrickOrTreat.CheckMobile(target))
            {
                target.SendLocalizedMessage(1113972); /* Your naughty twin teleports you away with a naughty laugh! */

                target.MoveToWorld(RandomMoongate(target), target.Map);
            }
        }
Example #2
0
        public NaughtyTwin(Mobile from)
            : base(AIType.AI_Melee, FightMode.None, 10, 1, 0.2, 0.4)
        {
            if (TrickOrTreat.CheckMobile(from))
            {
                Body = from.Body;

                m_From = from;
                Name   = String.Format("{0}\'s Naughty Twin", from.Name);

                Timer.DelayCall <Mobile>(TrickOrTreat.OneSecond, Utility.RandomBool() ? new TimerStateCallback <Mobile>(StealCandy) : new TimerStateCallback <Mobile>(ToGate), m_From);
            }
        }
Example #3
0
        public static void StealCandy(Mobile target)
        {
            if (TrickOrTreat.CheckMobile(target))
            {
                Item item = FindCandyTypes(target);

                target.SendLocalizedMessage(1113967); /* Your naughty twin steals some of your candy. */

                if (item != null && !item.Deleted)
                {
                    item.Delete();
                }
            }
        }
Example #4
0
        public static void Bleeding(Mobile m_From)
        {
            if (TrickOrTreat.CheckMobile(m_From))
            {
                if (m_From.Location != Point3D.Zero)
                {
                    int amount = Utility.RandomMinMax(3, 7);

                    for (int i = 0; i < amount; i++)
                    {
                        new Blood(Utility.RandomMinMax(0x122C, 0x122F)).MoveToWorld(RandomPointOneAway(m_From.X, m_From.Y, m_From.Z, m_From.Map), m_From.Map);
                    }
                }
            }
        }
Example #5
0
        public static Item FindCandyTypes(Mobile target)
        {
            Type[] types = { typeof(WrappedCandy), typeof(Lollipops), typeof(NougatSwirl), typeof(Taffy), typeof(JellyBeans) };

            if (TrickOrTreat.CheckMobile(target))
            {
                for (int i = 0; i < types.Length; i++)
                {
                    Item item = target.Backpack.FindItemByType(types[i]);

                    if (item != null)
                    {
                        return(item);
                    }
                }
            }
            return(null);
        }