コード例 #1
0
        public RepairBenchGump(Mobile from, RepairBench addon)
            : base(100, 100)
        {
            m_Addon = addon;

            StopTimer(from);

            m_Timer = Timer.DelayCall(TimeSpan.FromMinutes(1), new TimerStateCallback(CloseGump), from);

            AddPage(0);

            AddBackground(0, 0, 370, 470, 0x6DB);

            AddImage(82, 0, 0x6E4);
            AddHtmlLocalized(10, 10, 350, 18, 1114513, "#1158860", 0x0, false, false);     // <DIV ALIGN=CENTER>~1_TOKEN~</DIV>

            AddHtmlLocalized(70, 57, 120, 20, 1114513, "#1158878", 0x7FE0, false, false);  // <DIV ALIGN=CENTER>~1_TOKEN~</DIV>
            AddHtmlLocalized(213, 57, 190, 20, 1158879, 0x7FE0, false, false);             // Charges

            AddItem(20, 80, 0x1EB8);
            AddTooltip(1044097);
            AddButton(70, 97, 0x15E1, 0x15E5, 12, GumpButtonType.Reply, 0);
            AddLabel(113, 97, 0x5F, String.Format("{0:F1}", GetSkillValue(RepairSkillType.Tinkering)));
            AddLabel(218, 97, 0x5F, String.Format("{0}", GetCharges(RepairSkillType.Tinkering)));
            AddButton(318, 97, 0x2716, 0x2716, 22, GumpButtonType.Reply, 0);

            AddItem(20, 125, 0x0FB4);
            AddTooltip(1044067);
            AddButton(70, 137, 0x15E1, 0x15E5, 10, GumpButtonType.Reply, 0);
            AddLabel(113, 137, 0x5F, String.Format("{0:F1}", GetSkillValue(RepairSkillType.Smithing)));
            AddLabel(218, 137, 0x5F, String.Format("{0}", GetCharges(RepairSkillType.Smithing)));
            AddButton(318, 137, 0x2716, 0x2716, 20, GumpButtonType.Reply, 0);

            AddItem(20, 170, 0x1034);
            AddTooltip(1044071);
            AddButton(70, 177, 0x15E1, 0x15E5, 13, GumpButtonType.Reply, 0);
            AddLabel(113, 177, 0x5F, String.Format("{0:F1}", GetSkillValue(RepairSkillType.Carpentry)));
            AddLabel(218, 177, 0x5F, String.Format("{0}", GetCharges(RepairSkillType.Carpentry)));
            AddButton(318, 177, 0x2716, 0x2716, 23, GumpButtonType.Reply, 0);

            AddItem(20, 215, 0x0F9D);
            AddTooltip(1044094);
            AddButton(70, 217, 0x15E1, 0x15E5, 11, GumpButtonType.Reply, 0);
            AddLabel(113, 217, 0x5F, String.Format("{0:F1}", GetSkillValue(RepairSkillType.Tailoring)));
            AddLabel(218, 217, 0x5F, String.Format("{0}", GetCharges(RepairSkillType.Tailoring)));
            AddButton(318, 217, 0x2716, 0x2716, 21, GumpButtonType.Reply, 0);

            AddItem(20, 350, 0x1022);
            AddTooltip(1015156);
            AddButton(70, 337, 0x15E1, 0x15E5, 14, GumpButtonType.Reply, 0);
            AddLabel(113, 337, 0x5F, String.Format("{0:F1}", GetSkillValue(RepairSkillType.Fletching)));
            AddLabel(218, 337, 0x5F, String.Format("{0}", GetCharges(RepairSkillType.Fletching)));
            AddButton(318, 337, 0x2716, 0x2716, 24, GumpButtonType.Reply, 0);

            AddButton(70, 407, 0x15E1, 0x15E5, 1, GumpButtonType.Reply, 0);
            AddHtmlLocalized(95, 407, 200, 30, 1153100, 0x7FFF, false, false);             // Add Charges
        }
コード例 #2
0
        public ConfirmRemoveGump(RepairBench addon, RepairSkillType skill)
            : base(340, 340)
        {
            m_Addon = addon;
            m_Skill = skill;

            AddPage(0);

            AddBackground(0, 0, 291, 113, 0x13BE);
            AddImageTiled(5, 5, 280, 80, 0xA40);
            AddHtmlLocalized(9, 9, 272, 80, 1158874, String.Format("#{0}", addon.Tools.Find(x => x.Skill == skill).Cliloc), 0x7FFF, false, false);             // Are you sure you wish to remove all the ~1_SKILL~ charges from the bench? This action will delete all existing charges and will not refund any deeds.

            AddButton(5, 87, 0xFB1, 0xFB2, 0, GumpButtonType.Reply, 0);
            AddHtmlLocalized(40, 89, 100, 20, 1060051, 0x7FFF, false, false);             // CANCEL

            AddButton(160, 87, 0xFB7, 0xFB8, 1, GumpButtonType.Reply, 0);
            AddHtmlLocalized(195, 89, 120, 20, 1006044, 0x7FFF, false, false);             // OK
        }
コード例 #3
0
 public InternalTarget(Mobile from, RepairBenchGump g, RepairBench addon)
     : base(-1, false, TargetFlags.None)
 {
     m_Addon = addon;
     m_Gump  = g;
 }