예제 #1
0
 public override void UpdateGump(Gump g)
 {
     g.Children.Clear();
     Table2DInfoNode active = base.Inputs[0].Active as Table2DInfoNode;
     if (active == null)
     {
         GLabel toAdd = new GLabel("Select a spell type from the list above.", Engine.GetUniFont(1), GumpHues.WindowText, 0, 0);
         g.Children.Add(toAdd);
     }
     else
     {
         int num = 0;
         for (int i = 0; i < active.Descriptors.Length; i++)
         {
             TableGump gump = new TableGump(active.Descriptors[i]) {
                 Y = num
             };
             num += gump.Height + 10;
             g.Children.Add(gump);
         }
     }
 }
예제 #2
0
        public override void UpdateGump(Gump g)
        {
            g.Children.Clear();
            Table2DInfoNode active = base.Inputs[0].Active as Table2DInfoNode;

            if (active == null)
            {
                GLabel toAdd = new GLabel("Select a weapon type from the list above.", Engine.GetUniFont(1), GumpHues.WindowText, 0, 0);
                g.Children.Add(toAdd);
            }
            else
            {
                int num = 0;
                for (int i = 0; i < active.Descriptors.Length; i++)
                {
                    TableGump gump = new TableGump(active.Descriptors[i])
                    {
                        Y = num
                    };
                    num += gump.Height + 10;
                    g.Children.Add(gump);
                }
            }
        }