public EOPartyPanel(XNAPanel parent) : base(null, null, parent) { _setSize(parent.BackgroundImage.Width, parent.BackgroundImage.Height); m_removeTexture = GFXLoader.TextureFromResource(GFXTypes.PostLoginUI, 43); m_buttons = new List<XNAButton>(); //will tint this different colors for health bar and fill a rectangle m_healthBar = new Texture2D[4]; m_healthBar[HP_OUTLINE] = Game.Content.Load<Texture2D>("Party\\hp-outline"); m_healthBar[HP_RED] = Game.Content.Load<Texture2D>("Party\\hp-red"); m_healthBar[HP_YELLOW] = Game.Content.Load<Texture2D>("Party\\hp-yellow"); m_healthBar[HP_GREEN] = Game.Content.Load<Texture2D>("Party\\hp-green"); m_numMembers = new XNALabel(new Rectangle(455, 2, 27, 14), "Microsoft Sans Serif", 8.5f) { AutoSize = false, ForeColor = System.Drawing.Color.FromArgb(0xff, 0xc8, 0xc8, 0xc8), TextAlign = System.Drawing.ContentAlignment.MiddleRight }; m_numMembers.SetParent(this); m_scrollBar = new EOScrollBar(this, new Vector2(467, 20), new Vector2(16, 97), EOScrollBar.ScrollColors.LightOnMed) { LinesToRender = 7, Visible = true }; m_scrollBar.SetParent(this); World.IgnoreDialogs(m_scrollBar); }
public EOPartyPanel(XNAPanel parent) : base(null, null, parent) { _setSize(parent.BackgroundImage.Width, parent.BackgroundImage.Height); m_removeTexture = GFXLoader.TextureFromResource(GFXTypes.PostLoginUI, 43); m_buttons = new List <XNAButton>(); //will tint this different colors for health bar and fill a rectangle m_healthBar = new Texture2D[4]; m_healthBar[HP_OUTLINE] = Game.Content.Load <Texture2D>("Party\\hp-outline"); m_healthBar[HP_RED] = Game.Content.Load <Texture2D>("Party\\hp-red"); m_healthBar[HP_YELLOW] = Game.Content.Load <Texture2D>("Party\\hp-yellow"); m_healthBar[HP_GREEN] = Game.Content.Load <Texture2D>("Party\\hp-green"); m_numMembers = new XNALabel(new Rectangle(455, 2, 27, 14), "Microsoft Sans Serif", 8.5f) { AutoSize = false, ForeColor = System.Drawing.Color.FromArgb(0xff, 0xc8, 0xc8, 0xc8), TextAlign = System.Drawing.ContentAlignment.MiddleRight }; m_numMembers.SetParent(this); m_scrollBar = new EOScrollBar(this, new Vector2(467, 20), new Vector2(16, 97), EOScrollBar.ScrollColors.LightOnMed) { LinesToRender = 7, Visible = true }; m_scrollBar.SetParent(this); World.IgnoreDialogs(m_scrollBar); }
public EOOnlineList(XNAPanel parent) : base(null, null, parent) { m_onlineList = new List <ClientOnlineEntry>(); //this enables scrolling with mouse wheel and mouseover for parent _setSize(parent.BackgroundImage.Width, parent.BackgroundImage.Height); m_totalNumPlayers = new XNALabel(new Rectangle(455, 2, 27, 14), "Microsoft Sans Serif", 8.5f) { AutoSize = false, ForeColor = System.Drawing.Color.FromArgb(0xff, 0xc8, 0xc8, 0xc8), TextAlign = System.Drawing.ContentAlignment.MiddleRight }; m_totalNumPlayers.SetParent(this); m_scrollBar = new EOScrollBar(this, new Vector2(467, 20), new Vector2(16, 97), EOScrollBar.ScrollColors.LightOnMed) { LinesToRender = 7, Visible = true }; m_scrollBar.SetParent(this); m_scrollBar.IgnoreDialog(typeof(EOPaperdollDialog)); m_scrollBar.IgnoreDialog(typeof(EOChestDialog)); m_filterClick = new Rectangle(2 + DrawAreaWithOffset.X, 2 + DrawAreaWithOffset.Y, 14, 14); Texture2D weirdOffsets = GFXLoader.TextureFromResource(GFXTypes.PostLoginUI, 27, true); for (int i = 0; i < m_filterTextures.Length; ++i) { Rectangle offsetsSource = new Rectangle(i % 2 == 0 ? 0 : 12, i >= 2 ? 246 : 233, 12, 13); m_filterTextures[i] = new Texture2D(EOGame.Instance.GraphicsDevice, 12, 13); Color[] dat = new Color[12 * 13]; weirdOffsets.GetData(0, offsetsSource, dat, 0, dat.Length); m_filterTextures[i].SetData(dat); } }