public GSkillGump(Skill skill, int y, int width, bool showReal) : base(4, y) { this.m_yBase = y; this.m_Skill = skill; if (skill.Action) { this.m_Name = new GUsableSkillName(skill); } else { this.m_Name = new GLabel(skill.Name, Engine.GetUniFont(1), Hues.Bright, 20, 0); } this.m_Name.X -= this.m_Name.Image.xMin; this.m_Name.Y -= this.m_Name.Image.yMin; this.m_Width = width; this.m_Height = this.m_Name.Image.yMax - this.m_Name.Image.yMin; base.m_Children.Add(this.m_Name); float num = showReal ? this.m_Skill.Real : this.m_Skill.Value; this.m_Value = new GLabel(num.ToString("F1"), Engine.GetUniFont(1), Hues.Bright, 0, 0); this.m_Value.X = (this.m_Width - 0x18) - this.m_Value.Image.xMax; this.m_Value.Y -= this.m_Value.Image.yMin; if ((this.m_Value.Image.yMax - this.m_Value.Image.yMin) > this.m_Height) { this.m_Height = this.m_Value.Image.yMax - this.m_Value.Image.yMin; } base.m_Children.Add(this.m_Value); this.m_Lock = new GThreeToggle(Engine.m_SkillUp, Engine.m_SkillDown, Engine.m_SkillLocked, (int) this.m_Skill.Lock, this.m_Width - 4, 0); this.m_Lock.OnStateChange = new OnStateChange(this.Lock_OnStateChange); this.UpdateLock(); base.m_Children.Add(this.m_Lock); }
public GSkillGump(Skill skill, int y, int width, bool showReal) : base(4, y) { this.m_yBase = y; this.m_Skill = skill; if (skill.Action) { this.m_Name = new GUsableSkillName(skill); } else { this.m_Name = new GLabel(skill.Name, Engine.GetUniFont(1), Hues.Bright, 20, 0); } this.m_Name.X -= this.m_Name.Image.xMin; this.m_Name.Y -= this.m_Name.Image.yMin; this.m_Width = width; this.m_Height = this.m_Name.Image.yMax - this.m_Name.Image.yMin; base.m_Children.Add(this.m_Name); float num = showReal ? this.m_Skill.Real : this.m_Skill.Value; this.m_Value = new GLabel(num.ToString("F1"), Engine.GetUniFont(1), Hues.Bright, 0, 0); this.m_Value.X = (this.m_Width - 0x18) - this.m_Value.Image.xMax; this.m_Value.Y -= this.m_Value.Image.yMin; if ((this.m_Value.Image.yMax - this.m_Value.Image.yMin) > this.m_Height) { this.m_Height = this.m_Value.Image.yMax - this.m_Value.Image.yMin; } base.m_Children.Add(this.m_Value); this.m_Lock = new GThreeToggle(Engine.m_SkillUp, Engine.m_SkillDown, Engine.m_SkillLocked, (int)this.m_Skill.Lock, this.m_Width - 4, 0); this.m_Lock.OnStateChange = new OnStateChange(this.Lock_OnStateChange); this.UpdateLock(); base.m_Children.Add(this.m_Lock); }