Ejemplo n.º 1
0
        public override void GetContextMenuEntries(Mobile from, List <ContextMenuEntry> entries)
        {
            base.GetContextMenuEntries(from, entries);

            if (IsChildOf(from.Backpack))
            {
                SimpleContextMenuEntry entry1 = new SimpleContextMenuEntry(from, 1071507, m =>
                {
                    SummonAll = false;
                    InvalidateProperties();
                });     // Summon Most Recent Corpse Only

                SimpleContextMenuEntry entry2 = new SimpleContextMenuEntry(from, 1071508, m =>
                {
                    _SummonAll = true;
                    InvalidateProperties();
                });     // Summon All Corpses

                if (_SummonAll)
                {
                    entry2.Flags |= CMEFlags.Highlighted;
                }
                else
                {
                    entry1.Flags |= CMEFlags.Highlighted;
                }

                entry1.Enabled = !IsSummoning();
                entry2.Enabled = !IsSummoning();

                entries.Add(entry1);
                entries.Add(entry2);
            }
        }
Ejemplo n.º 2
0
        public override void GetContextMenuEntries(Mobile from, List <ContextMenuEntry> list)
        {
            base.GetContextMenuEntries(from, list);

            var menu = new SimpleContextMenuEntry(from, 1151948, m =>
            {
                if (m is PlayerMobile && IsChildOf(m.Backpack) && CheckCooldown(m))
                {
                    BaseGump.SendGump(new MasterySelectionGump(m as PlayerMobile, this));
                }
            });

            if (!IsChildOf(from.Backpack) || !CheckCooldown(from))
            {
                menu.Enabled = false;
            }

            list.Add(menu);
        }
Ejemplo n.º 3
0
        public override void GetContextMenuEntries(Mobile from, List <ContextMenuEntry> list)
        {
            base.GetContextMenuEntries(from, list);

            BaseHouse house = BaseHouse.FindHouseAt(this);

            var entry = new SimpleContextMenuEntry(from, 3000097, m =>
            {
                if (!Deleted)
                {
                    BaseGump.SendGump(new YahtzeeSetupGump(m as PlayerMobile, this));
                }
            });

            if (!IsChildOf(from.Backpack))
            {
                if (!IsLockedDown || house == null || !house.HasSecureAccess(from, Level))
                {
                    entry.Enabled = false;
                }
            }

            list.Add(entry);
        }