public RewardOptionGump( IRewardOption option, int title ) : base( 60, 36 )
		{
			m_Option = option;

			if ( m_Option != null )
				m_Option.GetOptions( m_Options );

			AddPage( 0 );

			AddBackground( 0, 0, 273, 324, 0x13BE );
			AddImageTiled( 10, 10, 253, 20, 0xA40 );
			AddImageTiled( 10, 40, 253, 244, 0xA40 );
			AddImageTiled( 10, 294, 253, 20, 0xA40 );
			AddAlphaRegion( 10, 10, 253, 304 );

			AddButton( 10, 294, 0xFB1, 0xFB2, 0, GumpButtonType.Reply, 0 );
			AddHtmlLocalized( 45, 296, 450, 20, 1060051, 0x7FFF, false, false ); // CANCEL

			if ( title > 0 )
				AddHtmlLocalized( 14, 12, 273, 20, title, 0x7FFF, false, false );
			else
				AddHtmlLocalized( 14, 12, 273, 20, 1080392, 0x7FFF, false, false ); // Select your choice from the menu below.

			AddPage( 1 );

			for ( int i = 0; i < m_Options.Count; i++ )
			{
				AddButton( 19, 49 + i * 24, 0x845, 0x846, ((RewardOption)m_Options[i]).ID, GumpButtonType.Reply, 0 );
				AddHtmlLocalized( 44, 47 + i * 24, 213, 20, ((RewardOption)m_Options[i]).Cliloc, 0x7FFF, false, false );
			}
		}
Exemple #2
0
        public RewardOptionGump(IRewardOption option, int title = 0) : base(60, 36)
        {
            m_Option = option;

            m_Option?.GetOptions(m_Options);

            AddPage(0);

            AddBackground(0, 0, 273, 324, 0x13BE);
            AddImageTiled(10, 10, 253, 20, 0xA40);
            AddImageTiled(10, 40, 253, 244, 0xA40);
            AddImageTiled(10, 294, 253, 20, 0xA40);
            AddAlphaRegion(10, 10, 253, 304);

            AddButton(10, 294, 0xFB1, 0xFB2, 0);
            AddHtmlLocalized(45, 296, 450, 20, 1060051, 0x7FFF); // CANCEL

            if (title > 0)
            {
                AddHtmlLocalized(14, 12, 273, 20, title, 0x7FFF);
            }
            else
            {
                AddHtmlLocalized(14, 12, 273, 20, 1080392, 0x7FFF); // Select your choice from the menu below.
            }
            AddPage(1);

            for (int i = 0; i < m_Options.Count; i++)
            {
                AddButton(19, 49 + i * 24, 0x845, 0x846, m_Options[i].ID);
                AddHtmlLocalized(44, 47 + i * 24, 213, 20, m_Options[i].Cliloc, 0x7FFF);
            }
        }
Exemple #3
0
        public RewardOptionGump(IRewardOption option, int title) : base(60, 36)
        {
            m_Option = option;

            if (m_Option != null)
            {
                m_Option.GetOptions(m_Options);
            }

            AddPage(0);

            int width  = m_Options.Width;
            int height = m_Options.Height;

            AddBackground(0, 0, width, height, 0x13BE);
            AddImageTiled(10, 10, width - 20, 20, 0xA40);
            AddImageTiled(10, 40, width - 20, height - 80, 0xA40);
            AddImageTiled(10, height - 30, width - 20, 20, 0xA40);
            AddAlphaRegion(10, 10, width - 20, height - 20);

            AddButton(10, height - 30, 0xFB1, 0xFB2, 0, GumpButtonType.Reply, 0);
            AddHtmlLocalized(45, height - 28, width - 20, 20, 1060051, 0x7FFF, false, false);               // CANCEL

            if (title > 0)
            {
                AddHtmlLocalized(14, 12, width - 20, 20, title, 0x7FFF, false, false);
            }
            else
            {
                AddHtmlLocalized(14, 12, width - 20, 20, 1080392, 0x7FFF, false, false);                   // Select your choice from the menu below.
            }
            AddPage(1);

            for (int i = 0; i < m_Options.Count; i++)
            {
                AddButton(19, 49 + i * 24, 0x845, 0x846, m_Options[i].ID, GumpButtonType.Reply, 0);
                if (m_Options[i].Cliloc > 0)
                {
                    AddHtmlLocalized(44, 47 + i * 24, width - 50, 20, m_Options[i].Cliloc, 0x7FFF, false, false);
                }
                else
                {
                    AddHtmlLocalized(44, 47 + i * 24, width - 50, 20, 1042971, m_Options[i].Name, 0x7FFF, false, false);
                }
            }
        }
Exemple #4
0
        public RewardOptionGump(IRewardOption option, int title)
            : base(60, 36)
        {
            m_Option = option;

            if (m_Option != null)
            {
                m_Option.GetOptions(m_Options);
            }

            AddPage(0);

            AddBackground(0, 0, 273, 324, 0x13BE);
            AddImageTiled(10, 10, 253, 20, 0xA40);
            AddImageTiled(10, 40, 253, 244, 0xA40);
            AddImageTiled(10, 294, 253, 20, 0xA40);
            AddAlphaRegion(10, 10, 253, 304);

            AddButton(10, 294, 0xFB1, 0xFB2, 0, GumpButtonType.Reply, 0);
            AddHtmlLocalized(45, 296, 450, 20, 1060051, 0x7FFF, false, false); // CANCEL

            if (title > 0)
            {
                AddHtmlLocalized(14, 12, 273, 20, title, 0x7FFF, false, false);
            }
            else
            {
                AddHtmlLocalized(14, 12, 273, 20, 1080392, 0x7FFF, false, false); // Select your choice from the menu below.
            }
            AddPage(1);

            for (int i = 0; i < m_Options.Count; i++)
            {
                AddButton(19, 49 + i * 24, 0x845, 0x846, m_Options[i].ID, GumpButtonType.Reply, 0);

                if (m_Options[i].Cliloc.Number > 0)
                {
                    AddHtmlLocalized(44, 47 + i * 24, 213, 20, m_Options[i].Cliloc.Number, 0x7FFF, false, false);
                }
                else
                {
                    AddHtml(44, 47 + i * 24, 213, 20, String.Format("<basefont color=#FFFFFF>{0}", m_Options[i].Text), false, false);
                }
            }
        }
Exemple #5
0
        public RewardOptionMenu(IRewardOption option, string title)
            : base(title != null && title.Length > 0 ? title : "Select your choice from the menu below.", null)
        {
            m_Option = option;

            if (m_Option != null)
            {
                m_Option.GetOptions(m_Options);
            }

            List <String> answer = new List <String>();

            for (int i = 0; i < m_Options.Count; i++)
            {
                answer.Add(m_Options[i].Text);
            }

            Answers = answer.ToArray();
        }
Exemple #6
0
        public AddonOptionGump(IRewardOption option, int title, int bgw, int bgh)
            : base(50, 50)
        {
            m_Option = option;

            if (m_Option != null)
            {
                m_Option.GetOptions(m_Options);
            }

            AddPage(0);

            AddBackground(0, 0, bgw, bgh, 0xA28);

            if (title > 0)
            {
                AddHtmlLocalized(30, 30, 240, 20, 1113302, String.Format("#{0}", title), 0x0, false, false); // <CENTER>~1_VAL~</CENTER>
            }
            else
            {
                AddHtmlLocalized(30, 30, 240, 20, 1113302, "#1080392", 0x0, false, false); // Select your choice from the menu below.
            }
            for (int i = 0; i < m_Options.Count; i++)
            {
                AddButton(30, 70 + i * 20, 0xFA5, 0xFA7, m_Options[i].ID, GumpButtonType.Reply, 0);

                if (m_Options[i].Cliloc.Number > 0)
                {
                    AddHtmlLocalized(70, 70 + i * 20, 150, 20, m_Options[i].Cliloc.Number, 0x0, false, false);
                }
                else
                {
                    AddHtml(70, 70 + i * 20, 150, 20, String.Format("<basefont color=#000000>{0}", m_Options[i].Text), false, false);
                }
            }
        }