Ejemplo n.º 1
0
                protected void FillData(Icons.ID starticon, Kernel_bin.Stat statatk, Kernel_bin.Stat statdef)
                {
                    byte pos = 0;

                    Contents[0] = statatk;
                    getColor(pos, out byte palette, out Font.ColorID _colorid, out bool unlocked);
                    FF8String name = Kernel_bin.MagicData[Memory.State.Characters[Character].Stat_J[statatk]].Name;

                    if (name.Length == 0)
                    {
                        name = Misc[Items._];
                    }
                    ITEM[pos, 0] = new IGMDataItem_Icon(starticon, new Rectangle(SIZE[pos].X, SIZE[pos].Y, 0, 0), palette);
                    ITEM[pos, 1] = new IGMDataItem_String(name, new Rectangle(SIZE[pos].X + 60, SIZE[pos].Y, 0, 0), color: _colorid);
                    BLANKS[pos]  = !unlocked;
                    for (pos = 1; pos < Count; pos++)
                    {
                        Contents[pos] = statdef + pos - 1;
                        getColor(pos, out palette, out _colorid, out unlocked);
                        name = Kernel_bin.MagicData[Memory.State.Characters[Character].Stat_J[statdef + pos - 1]].Name;
                        if (name.Length == 0)
                        {
                            name = Misc[Items._];
                        }
                        ITEM[pos, 0] = new IGMDataItem_Icon(starticon + 1, new Rectangle(SIZE[pos].X, SIZE[pos].Y, 0, 0), palette);
                        ITEM[pos, 1] = new IGMDataItem_String(name, new Rectangle(SIZE[pos].X + 60, SIZE[pos].Y, 0, 0), color: _colorid);
                        BLANKS[pos]  = !unlocked;
                    }
                }
Ejemplo n.º 2
0
            public override void Refresh()
            {
                base.Refresh();

                if (Memory.State.Characters != null && Character != Characters.Blank)
                {
                    for (int i = 0; i < Count; i++)
                    {
                        if (i == 0)
                        {
                            ITEM[i, 1] = new IGMDataItem_String(
                                Kernel_bin.BattleCommands[
                                    Memory.State.Characters[Character].Abilities.Contains(Kernel_bin.Abilities.Mug) ?
                                    13 :
                                    1].Name,
                                new Rectangle(SIZE[i].X + 80, SIZE[i].Y, 0, 0));
                        }
                        else
                        {
                            ITEM[i, 0] = new IGMDataItem_Icon(Icons.ID.Arrow_Right2, SIZE[i], 9);
                            ITEM[i, 1] = Memory.State.Characters[Character].Commands[i - 1] != Kernel_bin.Abilities.None ? new IGMDataItem_String(
                                Icons.ID.Ability_Command, 9,
                                Kernel_bin.Commandabilities[Memory.State.Characters[Character].Commands[i - 1]].Name,
                                new Rectangle(SIZE[i].X + 40, SIZE[i].Y, 0, 0)) : null;
                            Kernel_bin.Abilities k = Memory.State.Characters[Character].Commands[i - 1];
                            Descriptions[i] = k == Kernel_bin.Abilities.None ? null : Kernel_bin.Commandabilities[k].BattleCommand.Description;
                        }
                    }
                }
            }
Ejemplo n.º 3
0
                public override void ReInit()
                {
                    base.ReInit();

                    if (InGameMenu_Junction != null && InGameMenu_Junction.GetMode() == Mode.Mag_Stat && Enabled)
                    {
                        ITEM[0, 0] = new IGMDataItem_Icon(Icons.ID.Rewind_Fast, new Rectangle(SIZE[0].X, SIZE[0].Y, 0, 0), 2, 7);
                        ITEM[0, 1] = new IGMDataItem_String(Descriptions[Items.ST_A_D], new Rectangle(SIZE[0].X + 20, SIZE[0].Y, 0, 0));
                        ITEM[0, 2] = new IGMDataItem_Icon(Icons.ID.Rewind, new Rectangle(SIZE[0].X + 143, SIZE[0].Y, 0, 0), 2, 7);
                        ITEM[0, 3] = new IGMDataItem_String(Descriptions[Items.EL_A_D], new Rectangle(SIZE[0].X + 169, SIZE[0].Y, 0, 0));
                    }
                    else
                    if (InGameMenu_Junction != null && InGameMenu_Junction.GetMode() == Mode.Mag_EL_A && Enabled) //coords for these two need checked.
                    {
                        ITEM[0, 0] = new IGMDataItem_Icon(Icons.ID.Rewind, new Rectangle(SIZE[0].X, SIZE[0].Y, 0, 0), 2, 7);
                        ITEM[0, 1] = new IGMDataItem_String(Descriptions[Items.ST_A_D], new Rectangle(SIZE[0].X + 20, SIZE[0].Y, 0, 0));
                        ITEM[0, 2] = new IGMDataItem_Icon(Icons.ID.Forward, new Rectangle(SIZE[0].X + 143, SIZE[0].Y, 0, 0), 2, 7);
                        ITEM[0, 3] = new IGMDataItem_String(Descriptions[Items.Stats], new Rectangle(SIZE[0].X + 169, SIZE[0].Y, 0, 0));
                    }
                    else
                    if (InGameMenu_Junction != null && InGameMenu_Junction.GetMode() == Mode.Mag_ST_A && Enabled)
                    {
                        ITEM[0, 0] = new IGMDataItem_Icon(Icons.ID.Forward, new Rectangle(SIZE[0].X, SIZE[0].Y, 0, 0), 2, 7);
                        ITEM[0, 1] = new IGMDataItem_String(Descriptions[Items.EL_A_D], new Rectangle(SIZE[0].X + 20, SIZE[0].Y, 0, 0));
                        ITEM[0, 2] = new IGMDataItem_Icon(Icons.ID.Forward_Fast, new Rectangle(SIZE[0].X + 143, SIZE[0].Y, 0, 0), 2, 7);
                        ITEM[0, 3] = new IGMDataItem_String(Descriptions[Items.Stats], new Rectangle(SIZE[0].X + 169, SIZE[0].Y, 0, 0));
                    }
                }
Ejemplo n.º 4
0
 public IGMData_ConfirmDialog(FF8String data, Icons.ID title, FF8String opt1, FF8String opt2, Rectangle?pos, int startcursor = 0) : base(2, 1, new IGMDataItem_Box(data, pos, title), 1, 2)
 {
     this.startcursor = startcursor;
     opt        = new FF8String[Count];
     opt[0]     = opt1;
     opt[1]     = opt2;
     ITEM[0, 0] = new IGMDataItem_String(opt[0], SIZE[0]);
     ITEM[1, 0] = new IGMDataItem_String(opt[1], SIZE[1]);
 }
Ejemplo n.º 5
0
 private void addGF(ref int pos, GFs g, Font.ColorID color = Font.ColorID.White)
 {
     ITEM[pos, 0]  = new IGMDataItem_String(Memory.Strings.GetName(g), SIZE[pos], color);
     ITEM[pos, 1]  = JunctionedGFs.ContainsKey(g) ? new IGMDataItem_Icon(Icons.ID.JunctionSYM, new Rectangle(SIZE[pos].X + SIZE[pos].Width - 100, SIZE[pos].Y, 0, 0)) : null;
     ITEM[pos, 2]  = new IGMDataItem_Int(Source.GFs[g].Level, new Rectangle(SIZE[pos].X + SIZE[pos].Width - 50, SIZE[pos].Y, 0, 0), spaces: 3);
     BLANKS[pos]   = false;
     Contents[pos] = g;
     pos++;
 }
Ejemplo n.º 6
0
 protected override void Init()
 {
     base.Init();
     _helpStr = new FF8String[Count];
     for (byte pos = 0; pos < rows; pos++)
     {
         ITEM[pos, 0] = new IGMDataItem_String(null, SIZE[pos]);
         ITEM[pos, 1] = new IGMDataItem_Int(0, new Rectangle(SIZE[pos].X + SIZE[pos].Width - 60, SIZE[pos].Y, 0, 0), numtype: Icons.NumType.sysFntBig, spaces: 3);
     }
 }
Ejemplo n.º 7
0
 /// <summary>
 /// Things fixed at startup.
 /// </summary>
 protected override void Init()
 {
     ITEM[0, 1]  = new IGMDataItem_Icon(Icons.ID.MenuBorder, new Rectangle(X + 10, Y - 2, 100, 148), scale: new Vector2(1f));
     ITEM[0, 3]  = new IGMDataItem_String(Misc[Items.LV], new Rectangle(X + 117, Y + 54, 0, 0));
     ITEM[0, 6]  = new IGMDataItem_String(Misc[Items.HP], new Rectangle(X + 117, Y + 108, 0, 0));
     ITEM[0, 8]  = new IGMDataItem_String(Misc[Items.ForwardSlash], new Rectangle(X + 272, Y + 108, 0, 0));
     ITEM[0, 10] = new IGMDataItem_String(Misc[Items.CurrentEXP] + new FF8String("\n") + Misc[Items.NextLEVEL], new Rectangle(X, Y + 192, 0, 0));
     ITEM[0, 12] = new IGMDataItem_Icon(Icons.ID.P, new Rectangle(X + 372, Y + 198, 0, 0), 2);
     ITEM[0, 14] = new IGMDataItem_Icon(Icons.ID.P, new Rectangle(X + 372, Y + 231, 0, 0), 2);
     base.Init();
 }
Ejemplo n.º 8
0
            private void Refresh(sbyte pos, Characters character)
            {
                Contents[pos] = new Tuple <Characters, Characters>(character, character);
                float     yoff  = 39;
                Rectangle rbak  = SIZE[pos];
                Rectangle r     = rbak;
                Color     color = new Color(74.5f / 100, 12.5f / 100, 11.8f / 100, .9f);

                ITEM[pos, 0] = new IGMDataItem_String(Memory.Strings.GetName(character), rbak);
                CURSOR[pos]  = new Point(rbak.X, (int)(rbak.Y + (6 * TextScale.Y)));

                r.Offset(7, yoff);
                ITEM[pos, 1] = new IGMDataItem_Icon(Icons.ID.Lv, r, 13);

                r = rbak;
                r.Offset((49), yoff);
                ITEM[pos, 2] = new IGMDataItem_Int(Memory.State.Characters[character].Level, r, 2, 0, 1, 3);

                r = rbak;
                r.Offset(126, yoff);
                ITEM[pos, 3] = new IGMDataItem_Icon(Icons.ID.HP2, r, 13);

                r.Offset(0, 28);
                r.Width      = 118;
                r.Height     = 1;
                ITEM[pos, 4] = new IGMDataItem_Texture(_red_pixel, r)
                {
                    Color = Color.Black
                };
                r.Width      = (int)(r.Width * Memory.State.Characters[character].PercentFullHP());
                ITEM[pos, 5] = new IGMDataItem_Texture(_red_pixel, r)
                {
                    Color = color
                };

                r.Width = 118;
                r.Offset(0, 2);
                ITEM[pos, 6] = new IGMDataItem_Texture(_red_pixel, r)
                {
                    Color = Color.Black
                };
                r.Width      = (int)(r.Width * Memory.State.Characters[character].PercentFullHP());
                ITEM[pos, 7] = new IGMDataItem_Texture(_red_pixel, r)
                {
                    Color = color
                };
                //TODO red bar resizes based on current/max hp

                r = rbak;
                r.Offset((166), yoff);
                ITEM[pos, 8] = new IGMDataItem_Int(Memory.State.Characters[character].CurrentHP(), r, 2, 0, 1, 4);
            }
Ejemplo n.º 9
0
 protected override void Init()
 {
     base.Init();
     ITEM[0, 0]     = new IGMDataItem_String(Titles[Items.RemMag], SIZE[0]);
     ITEM[1, 0]     = new IGMDataItem_String(Titles[Items.RemAll], SIZE[1]);
     Cursor_Status |= Cursor_Status.Enabled;
     Cursor_Status |= Cursor_Status.Horizontal;
     Cursor_Status |= Cursor_Status.Vertical;
     Descriptions   = new Dictionary <Items, FF8String> {
         { Items.RemMag, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 278) },
         { Items.RemAll, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 276) },
     };
 }
Ejemplo n.º 10
0
 protected override void Init()
 {
     base.Init();
     ITEM[0, 0]     = new IGMDataItem_String(Titles[Items.Junction], SIZE[0]);
     Cursor_Status |= Cursor_Status.Enabled;
     Cursor_Status |= Cursor_Status.Horizontal;
     Cursor_Status |= Cursor_Status.Vertical;
     Descriptions   = new Dictionary <Items, FF8String> {
         { Items.Junction, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 218) },
         { Items.Off, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 220) },
         { Items.Auto, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 222) },
         { Items.Ability, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 224) },
     };
 }
Ejemplo n.º 11
0
 private void addMagic(ref int pos, Kernel_bin.Magic_Data spell, Font.ColorID color = Font.ColorID.White)
 {
     if (color == Font.ColorID.White && Source.Stat_J.ContainsValue(spell.ID))
     {
         //spell is junctioned
         color = Font.ColorID.Grey;
     }
     ITEM[pos, 0]  = new IGMDataItem_String(spell.Name, SIZE[pos], color);
     ITEM[pos, 1]  = color != Font.ColorID.White ? new IGMDataItem_Icon(Icons.ID.JunctionSYM, new Rectangle(SIZE[pos].X + SIZE[pos].Width - 75, SIZE[pos].Y, 0, 0)) : null;
     ITEM[pos, 2]  = new IGMDataItem_Int(Source.Magics[spell.ID], new Rectangle(SIZE[pos].X + SIZE[pos].Width - 50, SIZE[pos].Y, 0, 0), spaces: 3);
     BLANKS[pos]   = color == Font.ColorID.Dark_Gray ? true : false;
     Contents[pos] = spell.ID;
     pos++;
 }
Ejemplo n.º 12
0
 protected override void Init()
 {
     ITEM[0, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 0));
     ITEM[1, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 2));
     ITEM[2, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 4));
     ITEM[3, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 8));
     ITEM[4, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 6));
     ITEM[5, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 62));
     ITEM[6, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 64));
     ITEM[7, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 10));
     ITEM[8, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 16));
     ITEM[9, 0]  = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 67));
     ITEM[10, 0] = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 0, 14));
     base.Init();
 }
Ejemplo n.º 13
0
                private void Fill()
                {
                    Faces.ID id   = 0;
                    int      skip = Page * rows;

                    for (int i = 0; i < rows; i++)
                    {
                        bool       gftest    = false;
                        bool       ctest     = false;
                        Characters character = Characters.Blank;
                        GFs        gf        = GFs.Blank;
                        while (!Enum.IsDefined(typeof(Faces.ID), id) ||
                               !((ctest = Item.TestCharacter(ref id, out character)) || (gftest = Item.TestGF(ref id, out gf))) ||
                               skip-- > 0)
                        {
                            if ((byte)++id > 32)
                            {
                                for (; i < rows; i++)
                                {
                                    ITEM[i, 0]  = null;
                                    ITEM[i, 1]  = null;
                                    ITEM[i, 2]  = null;
                                    BLANKS[i]   = true;
                                    Contents[i] = Faces.ID.Blank;
                                }
                                Pages = Page + 1;
                                return;
                            }
                        }
                        ITEM[i, 0] = new IGMDataItem_String(Memory.Strings.GetName(id), pos: SIZE[i]);
                        int hp = (ctest || gftest) ? Memory.State[id].CurrentHP() : -1;
                        BLANKS[i]   = false;
                        Contents[i] = id;
                        if (hp > -1)
                        {
                            ITEM[i, 1] = new IGMDataItem_Icon(Icons.ID.HP2, new Rectangle(SIZE[i].X + SIZE[i].Width - (20 * 7), SIZE[i].Y, 0, 0), 13);
                            ITEM[i, 2] = new IGMDataItem_Int(hp, pos: new Rectangle(SIZE[i].X + SIZE[i].Width - (20 * 4), SIZE[i].Y, 0, 0), spaces: 4);
                        }
                        else
                        {
                            ITEM[i, 1] = null;
                            ITEM[i, 2] = null;
                        }

                        id++;
                    }
                    Pages = Page + 2;
                }
Ejemplo n.º 14
0
                public override void ReInit()
                {
                    if (Memory.State.Characters != null)
                    {
                        Font.ColorID color = (Memory.State.Characters[Character].JunctionnedGFs == Saves.GFflags.None) ? Font.ColorID.Grey : Font.ColorID.White;

                        ITEM[1, 0] = new IGMDataItem_String(Titles[Items.Off], SIZE[1], color);
                        ITEM[2, 0] = new IGMDataItem_String(Titles[Items.Auto], SIZE[2], color);
                        ITEM[3, 0] = new IGMDataItem_String(Titles[Items.Ability], SIZE[3], color);
                        for (int i = 1; i <= 3; i++)
                        {
                            BLANKS[i] = Memory.State.Characters[Character].JunctionnedGFs == Saves.GFflags.None;
                        }
                    }
                    base.ReInit();
                }
Ejemplo n.º 15
0
            public override void Refresh()
            {
                if (Memory.State?.Characters != null)
                {
                    List <KeyValuePair <int, Characters> > party = Memory.State.Party.Select((element, index) => new { element, index }).ToDictionary(m => m.index, m => m.element).Where(m => !m.Value.Equals(Characters.Blank)).ToList();
                    byte pos = 0;
                    foreach (KeyValuePair <int, Characters> pm in party)
                    {
                        Saves.CharacterData data = Memory.State[Memory.State.PartyData[pm.Key]];
                        bool ded = data.IsDead;
                        ITEM[pos, 0] = new IGMDataItem_String(Memory.Strings.GetName(pm.Value), SIZE[pos], ded ? Font.ColorID.Dark_Gray : Font.ColorID.White);

                        pos++;
                    }
                }
            }
                public override void ReInit()
                {
                    base.ReInit();

                    if (Memory.State.Characters != null)
                    {
                        for (int i = 0; i < Count; i++)
                        {
                            int slots = 2;
                            if (Memory.State.Characters[Character].UnlockedGFAbilities.Contains(Kernel_bin.Abilities.Abilityx3))
                            {
                                slots = 3;
                            }
                            if (Memory.State.Characters[Character].UnlockedGFAbilities.Contains(Kernel_bin.Abilities.Abilityx4))
                            {
                                slots = 4;
                            }
                            if (i < slots)
                            {
                                ITEM[i, 0] = new IGMDataItem_Icon(Icons.ID.Arrow_Right2, SIZE[i], 9);
                                if (Memory.State.Characters[Character].Abilities[i] != Kernel_bin.Abilities.None)
                                {
                                    ITEM[i, 1] = new IGMDataItem_String(

                                        Kernel_bin.EquipableAbilities[Memory.State.Characters[Character].Abilities[i]].Icon, 9,
                                        Kernel_bin.EquipableAbilities[Memory.State.Characters[Character].Abilities[i]].Name,
                                        new Rectangle(SIZE[i].X + 40, SIZE[i].Y, 0, 0));
                                    Descriptions[i] = Kernel_bin.EquipableAbilities[Memory.State.Characters[Character].Abilities[i]].Description.ReplaceRegion();
                                }
                                else
                                {
                                    ITEM[i, 1] = null;
                                    //Descriptions[i] = "";
                                }
                                BLANKS[i] = false;
                            }
                            else
                            {
                                ITEM[i, 0] = null;
                                ITEM[i, 1] = null;
                                BLANKS[i]  = true;
                                //Descriptions[i] = "";
                            }
                        }
                    }
                }
Ejemplo n.º 17
0
 private void Fill(Faces.ID e)
 {
     if ((e == Faces.ID.Blank && Target != Faces.ID.Blank) || All)
     {
         Target = e;
         foreach (IGMDataItem i in ITEM)
         {
             i?.Hide();
         }
     }
     else
     {
         if (Target == Faces.ID.Blank)
         {
             foreach (IGMDataItem i in ITEM)
             {
                 i?.Show();
             }
         }
         Target = e;
         Characters character = e.ToCharacters();
         GFs        gf        = e.ToGFs();
         if (character != Characters.Blank || (gf != GFs.Blank && gf != GFs.All))
         {
             ITEM[0, 0] = new IGMDataItem_String(Misc[Items.LV], new Rectangle(SIZE[0].X, SIZE[0].Y, 0, 0));
             ITEM[1, 0] = new IGMDataItem_String(Misc[Items.HP], new Rectangle(SIZE[1].X, SIZE[1].Y, 0, 0));
             ITEM[1, 2] = new IGMDataItem_String(Misc[Items.ForwardSlash], new Rectangle(SIZE[1].X + 155, SIZE[1].Y, 0, 0));
         }
         if (Memory.State.Characters != null && character != Characters.Blank)
         {
             ITEM[0, 1] = new IGMDataItem_Int(Memory.State.Characters[character].Level, new Rectangle(SIZE[0].X + 35, SIZE[0].Y, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 6);
             ITEM[0, 2] = Memory.State.Party != null && Memory.State.Party.Contains(character)
                 ? new IGMDataItem_Icon(Icons.ID.InParty, new Rectangle(SIZE[0].X + 155, SIZE[0].Y, 0, 0), 6)
                 : null;
             ITEM[1, 1] = new IGMDataItem_Int(Memory.State.Characters[character].CurrentHP(character), new Rectangle(SIZE[1].X + 35, SIZE[1].Y, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 6);
             ITEM[1, 3] = new IGMDataItem_Int(Memory.State.Characters[character].MaxHP(character), new Rectangle(SIZE[1].X + 155, SIZE[1].Y, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 5);
         }
         if (Memory.State.GFs != null && (gf != GFs.Blank && gf != GFs.All))
         {
             ITEM[0, 1] = new IGMDataItem_Int(Memory.State.GFs[gf].Level, new Rectangle(SIZE[0].X + 35, SIZE[0].Y, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 6);
             ITEM[0, 2] = null;
             ITEM[1, 1] = new IGMDataItem_Int(Memory.State.GFs[gf].CurrentHP(), new Rectangle(SIZE[1].X + 35, SIZE[1].Y, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 6);
             ITEM[1, 3] = new IGMDataItem_Int(Memory.State.GFs[gf].MaxHP(), new Rectangle(SIZE[1].X + 155, SIZE[1].Y, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 5);
         }
     }
 }
Ejemplo n.º 18
0
                /// <summary>
                /// Things that may of changed before screen loads or junction is changed.
                /// </summary>
                public override void ReInit()
                {
                    base.ReInit();
                    ITEM[0, 0] = new IGMDataItem_Face((Faces.ID)VisableCharacter, new Rectangle(X + 12, Y, 96, 144));
                    ITEM[0, 2] = new IGMDataItem_String(Memory.Strings.GetName(VisableCharacter), new Rectangle(X + 117, Y + 0, 0, 0));

                    if (Memory.State.Characters != null)
                    {
                        ITEM[0, 4] = new IGMDataItem_Int(Memory.State.Characters[Character].Level, new Rectangle(X + 117 + 35, Y + 54, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 6);
                        ITEM[0, 5] = Memory.State.Party != null && Memory.State.Party.Contains(Character)
                            ? new IGMDataItem_Icon(Icons.ID.InParty, new Rectangle(X + 278, Y + 48, 0, 0), 6)
                            : null;
                        ITEM[0, 7]  = new IGMDataItem_Int(Memory.State.Characters[Character].CurrentHP(VisableCharacter), new Rectangle(X + 152, Y + 108, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 6);
                        ITEM[0, 9]  = new IGMDataItem_Int(Memory.State.Characters[Character].MaxHP(VisableCharacter), new Rectangle(X + 292, Y + 108, 0, 0), 13, numtype: Icons.NumType.sysFntBig, padding: 1, spaces: 5);
                        ITEM[0, 11] = new IGMDataItem_Int((int)Memory.State.Characters[Character].Experience, new Rectangle(X + 192, Y + 198, 0, 0), 13, numtype: Icons.NumType.Num_8x8_2, padding: 1, spaces: 9);
                        ITEM[0, 13] = new IGMDataItem_Int(Memory.State.Characters[Character].ExperienceToNextLevel, new Rectangle(X + 192, Y + 231, 0, 0), 13, numtype: Icons.NumType.Num_8x8_2, padding: 1, spaces: 9);
                    }
                }
Ejemplo n.º 19
0
                public IGMData_TopMenu(IReadOnlyDictionary <FF8String, FF8String> pairs) : base()
                {
                    Pairs    = pairs;
                    _helpStr = new FF8String[Pairs.Count];
                    widths   = new int[Pairs.Count];
                    byte pos = 0;

                    foreach (KeyValuePair <FF8String, FF8String> pair in Pairs)
                    {
                        _helpStr[pos] = pair.Value;
                        Rectangle rectangle = Memory.font.RenderBasicText(pair.Key, 0, 0, skipdraw: true);
                        widths[pos] = rectangle.Width;
                        if (rectangle.Width > largestwidth)
                        {
                            largestwidth = rectangle.Width;
                        }
                        if (rectangle.Height > largestheight)
                        {
                            largestheight = rectangle.Height;
                        }
                        totalwidth += rectangle.Width;


                        avgwidth = totalwidth / ++pos;
                    }
                    Init(Pairs.Count, 1, new IGMDataItem_Box(pos: new Rectangle(0, 12, 610, 54)), Pairs.Count, 1);
                    pos = 0;
                    foreach (KeyValuePair <FF8String, FF8String> pair in Pairs)
                    {
                        ITEM[pos, 0] = new IGMDataItem_String(pair.Key, SIZE[pos]);
                        pos++;
                    }
                    Cursor_Status      |= Cursor_Status.Enabled;
                    Cursor_Status      |= Cursor_Status.Horizontal;
                    Cursor_Status      |= Cursor_Status.Vertical;
                    Cursor_Status      |= Cursor_Status.Blinking;
                    Inputs_Okay_Actions = new List <Action>(Count)
                    {
                        Inputs_Okay_UseItem,
                        Inputs_Okay_Sort,
                        Inputs_Okay_Rearrange,
                        Inputs_Okay_BattleRearrange,
                    };
                }
Ejemplo n.º 20
0
 protected override void Init()
 {
     base.Init();
     ITEM[0, 0]     = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 1, 105), SIZE[0]);
     ITEM[1, 0]     = new IGMDataItem_String(Memory.Strings.Read(Strings.FileID.MNGRP, 1, 106), SIZE[1]);
     ITEM[2, 0]     = new IGMDataItem_String("OpenVIII debug tools", SIZE[2]);
     Cursor_Status |= Cursor_Status.Enabled;
     OkayActions    = new Dictionary <int, Action>()
     {
         { 0, NewGameOkayAction },
         { 1, LoadGameOkayAction },
         { 2, DebugModeOkayAction },
     };
     FadeOutActions = new Dictionary <int, Action>()
     {
         { 0, NewGameFadeOutAction },
         //{1, LoadGameOkayAction },
         //{2, DebugModeOkayAction },
     };
 }
Ejemplo n.º 21
0
        private void addMagic(ref int pos, Kernel_bin.Magic_Data spell, Font.ColorID color = @default)
        {
            bool j = false;

            if (color == @default && Source.Stat_J.ContainsValue(spell.ID))
            {
                //spell is junctioned
                if (!Battle)
                {
                    color = junctioned;
                }
                j = true;
            }
            ITEM[pos, 0] = new IGMDataItem_String(spell.Name, SIZE[pos], color);
            ITEM[pos, 1] = j ? new IGMDataItem_Icon(Icons.ID.JunctionSYM, new Rectangle(SIZE[pos].X + SIZE[pos].Width - 75, SIZE[pos].Y, 0, 0)) : null;
            ITEM[pos, 2] = new IGMDataItem_Int(Source.Magics[spell.ID], new Rectangle(SIZE[pos].X + SIZE[pos].Width - 50, SIZE[pos].Y, 0, 0), spaces: 3);
            //makes it so you cannot junction a magic to a stat that does nothing.
            BLANKS[pos]   = color == nostat ? true : false;
            Contents[pos] = spell.ID;
            pos++;
        }
Ejemplo n.º 22
0
                /// <summary>
                /// Things that may of changed before screen loads or junction is changed.
                /// </summary>
                public override void ReInit()
                {
                    base.ReInit();

                    if (Memory.State.Characters != null)
                    {
                        ITEM[0, 0] = new IGMDataItem_String(
                            Kernel_bin.BattleCommands[
                                Memory.State.Characters[Character].Abilities.Contains(Kernel_bin.Abilities.Mug) ?
                                13 :
                                1].Name,
                            SIZE[0]);

                        for (int pos = 1; pos < SIZE.Length; pos++)
                        {
                            ITEM[pos, 0] = Memory.State.Characters[Character].Commands[pos - 1] != Kernel_bin.Abilities.None ? new IGMDataItem_String(
                                Kernel_bin.Commandabilities[Memory.State.Characters[Character].Commands[pos - 1]].Name,
                                SIZE[pos]) : null;
                        }
                    }
                }
Ejemplo n.º 23
0
 protected override void Init()
 {
     base.Init();
     ITEM[0, 0]     = new IGMDataItem_String(Titles[Items.AutoAtk], SIZE[0]);
     ITEM[1, 0]     = new IGMDataItem_String(Titles[Items.AutoDef], SIZE[1]);
     ITEM[2, 0]     = new IGMDataItem_String(Titles[Items.AutoMag], SIZE[2]);
     Cursor_Status |= Cursor_Status.Enabled;
     Cursor_Status |= Cursor_Status.Horizontal;
     Cursor_Status |= Cursor_Status.Vertical;
     Descriptions   = new Dictionary <Items, FF8String> {
         //{Items.HP, Memory.Strings.Read(Strings.FileID.MNGRP,2,226) },
         //{Items.Str, Memory.Strings.Read(Strings.FileID.MNGRP,2,228) },
         //{Items.Vit, Memory.Strings.Read(Strings.FileID.MNGRP,2,230) },
         //{Items.Mag, Memory.Strings.Read(Strings.FileID.MNGRP,2,232) },
         //{Items.Spr, Memory.Strings.Read(Strings.FileID.MNGRP,2,234) },
         //{Items.Spd, Memory.Strings.Read(Strings.FileID.MNGRP,2,236) },
         //{Items.Luck, Memory.Strings.Read(Strings.FileID.MNGRP,2,238) },
         //{Items.Hit, Memory.Strings.Read(Strings.FileID.MNGRP,2,240) },
         //{Items.ST_A,Memory.Strings.Read(Strings.FileID.MNGRP,2,244)},
         //{Items.ST_D,Memory.Strings.Read(Strings.FileID.MNGRP,2,246)},
         //{Items.EL_A,Memory.Strings.Read(Strings.FileID.MNGRP,2,248)},
         //{Items.EL_D,Memory.Strings.Read(Strings.FileID.MNGRP,2,250)},
         //{Items.ST_A_D,Memory.Strings.Read(Strings.FileID.MNGRP,2,252)},
         //{Items.EL_A_D,Memory.Strings.Read(Strings.FileID.MNGRP,2,254)},
         //{ Items.Stats,Memory.Strings.Read(Strings.FileID.MNGRP,2,256)},
         //{Items.ST_A2,Memory.Strings.Read(Strings.FileID.MNGRP,2,258)},
         //{Items.GF,Memory.Strings.Read(Strings.FileID.MNGRP,2,263)},
         //{Items.Magic,Memory.Strings.Read(Strings.FileID.MNGRP,2,265)},
         { Items.AutoAtk, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 270) },
         { Items.AutoMag, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 272) },
         { Items.AutoDef, Memory.Strings.Read(Strings.FileID.MNGRP, 2, 274) },
         //{Items.RemMag,Memory.Strings.Read(Strings.FileID.MNGRP,2,278)},
         //{Items.RemAll,Memory.Strings.Read(Strings.FileID.MNGRP,2,276)},
         //{Items.RemovealljunctionedGFandmagic,Memory.Strings.Read(Strings.FileID.MNGRP,2,279)},
         //{Items.Removealljunctionedmagic,Memory.Strings.Read(Strings.FileID.MNGRP,2,280)},
         //{Items.ChooseGFtojunction,Memory.Strings.Read(Strings.FileID.MNGRP,2,281)},
         //{Items.Chooseslottojunction,Memory.Strings.Read(Strings.FileID.MNGRP,2,282)},
         //{Items.Choosemagictojunction,Memory.Strings.Read(Strings.FileID.MNGRP,2,283)},
     };
 }
Ejemplo n.º 24
0
            public IGMData_SideMenu(IReadOnlyDictionary <FF8String, FF8String> pairs) : base()
            {
                _helpStr = new FF8String[pairs.Count];
                widths   = new int[pairs.Count];
                byte pos = 0;

                foreach (KeyValuePair <FF8String, FF8String> pair in pairs)
                {
                    _helpStr[pos] = pair.Value;
                    Rectangle rectangle = Memory.font.RenderBasicText(pair.Key, 0, 0, skipdraw: true);
                    widths[pos] = rectangle.Width;
                    if (rectangle.Width > largestwidth)
                    {
                        largestwidth = rectangle.Width;
                    }
                    if (rectangle.Height > largestheight)
                    {
                        largestheight = rectangle.Height;
                    }
                    totalwidth  += rectangle.Width;
                    totalheight += rectangle.Height;
                    avgwidth     = totalwidth / ++pos;
                    avgheight    = totalheight / pos;
                }
                Init(pairs.Count, 1, new IGMDataItem_Box(pos: new Rectangle {
                    Width = 226, Height = 492, X = 843 - 226
                }), 1, pairs.Count);
                pos = 0;
                foreach (KeyValuePair <FF8String, FF8String> pair in pairs)
                {
                    ITEM[pos, 0] = new IGMDataItem_String(pair.Key, new Rectangle(SIZE[pos].X, SIZE[pos].Y, 0, 0));
                    pos++;
                }

                Cursor_Status |= Cursor_Status.Enabled;
                Cursor_Status |= Cursor_Status.Vertical;
                Cursor_Status |= Cursor_Status.Horizontal;
            }
Ejemplo n.º 25
0
 public override void Refresh()
 {
     base.Refresh();
     if (Memory.State.Characters != null && Character != Characters.Blank)
     {
         IEnumerable <Enum> availableFlags = Enum.GetValues(typeof(Saves.GFflags)).Cast <Enum>();
         int pos = 0;
         foreach (Enum flag in availableFlags.Where(Memory.State.Characters[Character].JunctionnedGFs.HasFlag))
         {
             if ((Saves.GFflags)flag == Saves.GFflags.None)
             {
                 continue;
             }
             ITEM[pos, 0] = new IGMDataItem_String(
                 Memory.State.GFs[Saves.ConvertGFEnum[(Saves.GFflags)flag]].Name, SIZE[pos]);
             pos++;
         }
         for (; pos < Count; pos++)
         {
             ITEM[pos, 0] = null;
         }
     }
 }
Ejemplo n.º 26
0
            public override void Refresh()
            {
                if (Memory.State?.Characters != null)
                {
                    int pos = 0;
                    if (Enemy.Party != null)
                    {
                        foreach (Enemy e in Enemy.Party)
                        {
                            //if(e.EII)
                            ITEM[pos, 0] = new IGMDataItem_String(e.Name, SIZE[pos], Font.ColorID.White);
                            ITEM[pos, 0].Show();
                            BLANKS[pos] = false;

                            pos++;
                        }
                        for (; pos < Count; pos++)
                        {
                            ITEM[pos, 0]?.Hide();
                            BLANKS[pos] = true;
                        }
                    }
                }
            }
Ejemplo n.º 27
0
                protected override void Init()
                {
                    base.Init();
                    _helpStr = new FF8String[Count];
                    for (byte pos = 0; pos < Count; pos++)
                    {
                        FF8String data = null;
                        switch (pos)
                        {
                        case 0:
                            data          = Memory.Strings.Read(Strings.FileID.MNGRP, 2, 179);//Use
                            _helpStr[pos] = Memory.Strings.Read(Strings.FileID.MNGRP, 2, 180);
                            break;

                        case 1:
                            data          = Memory.Strings.Read(Strings.FileID.MNGRP, 2, 183);//Rearrange
                            _helpStr[pos] = Memory.Strings.Read(Strings.FileID.MNGRP, 2, 184);
                            break;

                        case 2:
                            data          = Memory.Strings.Read(Strings.FileID.MNGRP, 2, 202);//Sort
                            _helpStr[pos] = Memory.Strings.Read(Strings.FileID.MNGRP, 2, 203);
                            break;

                        case 3:
                            data          = Memory.Strings.Read(Strings.FileID.MNGRP, 2, 181);//Battle
                            _helpStr[pos] = Memory.Strings.Read(Strings.FileID.MNGRP, 2, 182);
                            break;
                        }
                        ITEM[pos, 0] = new IGMDataItem_String(data, SIZE[pos]);
                    }
                    Cursor_Status |= Cursor_Status.Enabled;
                    Cursor_Status |= Cursor_Status.Horizontal;
                    Cursor_Status |= Cursor_Status.Vertical;
                    Cursor_Status |= Cursor_Status.Blinking;
                }
Ejemplo n.º 28
0
            /// <summary>
            /// Things that may of changed before screen loads or junction is changed.
            /// </summary>
            public override void Refresh()
            {
                if (Memory.State.Characters != null)
                {
                    Contents = Array.ConvertAll(Contents, c => c = default);
                    base.Refresh();

                    if (Memory.State.Characters != null && unlocked != null)
                    {
                        ITEM[5, 0] = new IGMDataItem_Icon(Icons.ID.Icon_Status_Attack, new Rectangle(SIZE[5].X + 200, SIZE[5].Y, 0, 0),
                                                          (byte)(unlocked.Contains(Kernel_bin.Abilities.ST_Atk_J) ? 2 : 7));
                        ITEM[5, 1] = new IGMDataItem_Icon(Icons.ID.Icon_Status_Defense, new Rectangle(SIZE[5].X + 240, SIZE[5].Y, 0, 0),
                                                          (byte)(unlocked.Contains(Kernel_bin.Abilities.ST_Def_Jx1) ||
                                                                 unlocked.Contains(Kernel_bin.Abilities.ST_Def_Jx2) ||
                                                                 unlocked.Contains(Kernel_bin.Abilities.ST_Def_Jx4) ? 2 : 7));
                        ITEM[5, 2] = new IGMDataItem_Icon(Icons.ID.Icon_Elemental_Attack, new Rectangle(SIZE[5].X + 280, SIZE[5].Y, 0, 0),
                                                          (byte)(unlocked.Contains(Kernel_bin.Abilities.EL_Atk_J) ? 2 : 7));
                        ITEM[5, 3] = new IGMDataItem_Icon(Icons.ID.Icon_Elemental_Defense, new Rectangle(SIZE[5].X + 320, SIZE[5].Y, 0, 0),
                                                          (byte)(unlocked.Contains(Kernel_bin.Abilities.EL_Def_Jx1) ||
                                                                 unlocked.Contains(Kernel_bin.Abilities.EL_Def_Jx2) ||
                                                                 unlocked.Contains(Kernel_bin.Abilities.EL_Def_Jx4) ? 2 : 7));
                        BLANKS[5] = true;
                        foreach (Kernel_bin.Stat stat in (Kernel_bin.Stat[])Enum.GetValues(typeof(Kernel_bin.Stat)))
                        {
                            if (Stat2Icon.ContainsKey(stat))
                            {
                                int pos = (int)stat;
                                if (pos >= 5)
                                {
                                    pos++;
                                }
                                Contents[pos] = stat;
                                FF8String name = Kernel_bin.MagicData[Memory.State.Characters[Character].Stat_J[stat]].Name;
                                if (name == null || name.Length == 0)
                                {
                                    name = Misc[Items._];
                                }

                                ITEM[pos, 0] = new IGMDataItem_Icon(Stat2Icon[stat], new Rectangle(SIZE[pos].X, SIZE[pos].Y, 0, 0), 2);
                                ITEM[pos, 1] = new IGMDataItem_String(name, new Rectangle(SIZE[pos].X + 80, SIZE[pos].Y, 0, 0));
                                if (!unlocked.Contains(Kernel_bin.Stat2Ability[stat]))
                                {
                                    ((IGMDataItem_Icon)ITEM[pos, 0]).Palette     = ((IGMDataItem_Icon)ITEM[pos, 0]).Faded_Palette = 7;
                                    ((IGMDataItem_String)ITEM[pos, 1]).FontColor = Font.ColorID.Grey;
                                    BLANKS[pos] = true;
                                }
                                else
                                {
                                    BLANKS[pos] = false;
                                }

                                ITEM[pos, 2] = new IGMDataItem_Int(Memory.State.Characters[Character].TotalStat(stat, VisableCharacter), new Rectangle(SIZE[pos].X + 152, SIZE[pos].Y, 0, 0), 2, Icons.NumType.sysFntBig, spaces: 10);
                                ITEM[pos, 3] = stat == Kernel_bin.Stat.HIT || stat == Kernel_bin.Stat.EVA
                                    ? new IGMDataItem_String(Misc[Items.Percent], new Rectangle(SIZE[pos].X + 350, SIZE[pos].Y, 0, 0))
                                    : null;
                                if (GetPrevSetting() == null || GetPrevSetting().Stat_J[stat] == Memory.State.Characters[Character].Stat_J[stat] || GetPrevSetting().TotalStat(stat, VisableCharacter) == Memory.State.Characters[Character].TotalStat(stat, VisableCharacter))
                                {
                                    ITEM[pos, 4] = null;
                                }
                                else if (GetPrevSetting().TotalStat(stat, VisableCharacter) > Memory.State.Characters[Character].TotalStat(stat, VisableCharacter))
                                {
                                    ((IGMDataItem_Icon)ITEM[pos, 0]).Palette       = 5;
                                    ((IGMDataItem_Icon)ITEM[pos, 0]).Faded_Palette = 5;
                                    ((IGMDataItem_String)ITEM[pos, 1]).FontColor   = Font.ColorID.Red;
                                    ((IGMDataItem_Int)ITEM[pos, 2]).FontColor      = Font.ColorID.Red;
                                    if (ITEM[pos, 3] != null)
                                    {
                                        ((IGMDataItem_String)ITEM[pos, 3]).FontColor = Font.ColorID.Red;
                                    }
                                    ITEM[pos, 4] = new IGMDataItem_Icon(Icons.ID.Arrow_Down, new Rectangle(SIZE[pos].X + 250, SIZE[pos].Y, 0, 0), 16);
                                }
                                else
                                {
                                    ((IGMDataItem_Icon)ITEM[pos, 0]).Palette       = 6;
                                    ((IGMDataItem_Icon)ITEM[pos, 0]).Faded_Palette = 6;
                                    ((IGMDataItem_String)ITEM[pos, 1]).FontColor   = Font.ColorID.Yellow;
                                    ((IGMDataItem_Int)ITEM[pos, 2]).FontColor      = Font.ColorID.Yellow;
                                    if (ITEM[pos, 3] != null)
                                    {
                                        ((IGMDataItem_String)ITEM[pos, 3]).FontColor = Font.ColorID.Yellow;
                                    }
                                    ITEM[pos, 4] = new IGMDataItem_Icon(Icons.ID.Arrow_Up, new Rectangle(SIZE[pos].X + 250, SIZE[pos].Y, 0, 0), 17);
                                }
                            }
                        }
                    }
                }
            }
Ejemplo n.º 29
0
                private void ReInitCharacter(sbyte pos, Characters character, Characters visableCharacter)
                {
                    if (SIZE != null)
                    {
                        if (character != Characters.Blank)
                        {
                            Contents[pos] = new Tuple <Characters, Characters>(character, visableCharacter);
                            float yoff = 6;

                            ITEM[pos, 0] = new IGMDataItem_Box(Memory.Strings.GetName(visableCharacter), title: Icons.ID.STATUS);
                            Tuple <Rectangle, Point, Rectangle> dims = DrawBox(SIZE[pos], ((IGMDataItem_Box)ITEM[pos, 0]).Data, options: Box_Options.SkipDraw);
                            Rectangle r = dims.Item3;
                            ITEM[pos, 0].Pos = dims.Item1;
                            CURSOR[pos]      = dims.Item2;

                            r = dims.Item3;
                            r.Offset(184, yoff);
                            ITEM[pos, 1] = new IGMDataItem_Icon(Icons.ID.Lv, r, 13);

                            r = dims.Item3;
                            r.Offset((229), yoff);
                            ITEM[pos, 2] = new IGMDataItem_Int(Memory.State.Characters[character].Level, r, 2, 0, 1, 3);

                            r = dims.Item3;
                            r.Offset(304, yoff);
                            ITEM[pos, 3] = new IGMDataItem_Icon(Icons.ID.HP2, r, 13);

                            r = dims.Item3;
                            r.Offset((354), yoff);
                            ITEM[pos, 4] = new IGMDataItem_Int(Memory.State.Characters[character].CurrentHP(visableCharacter), r, 2, 0, 1, 4);

                            r = dims.Item3;
                            r.Offset(437, yoff);
                            ITEM[pos, 5] = new IGMDataItem_Icon(Icons.ID.Slash_Forward, r, 13);

                            r = dims.Item3;

                            r.Offset((459), yoff);
                            ITEM[pos, 6] = new IGMDataItem_Int(Memory.State.Characters[character].MaxHP(visableCharacter), r, 2, 0, 1, 4);

                            if (Memory.State.TeamLaguna || Memory.State.SmallTeam)
                            {
                                BLANKS[pos] = false;
                                r           = dims.Item3;
                                r.Offset(145, 36);
                                FF8String s = Strings[Items.CurrentEXP] + "\n" + Strings[Items.NextLEVEL];
                                ITEM[pos, 7] = new IGMDataItem_String(s, r);

                                r = dims.Item3;
                                r.Offset((340), 42);
                                ITEM[pos, 8] = new IGMDataItem_Int((int)Memory.State.Characters[character].Experience, r, 2, 0, 1, 9);

                                r = dims.Item3;
                                r.Offset(520, 42);
                                ITEM[pos, 9] = new IGMDataItem_Icon(Icons.ID.P, r, 2);

                                r = dims.Item3;
                                r.Offset((340), 75);
                                ITEM[pos, 10] = new IGMDataItem_Int(Memory.State.Characters[character].ExperienceToNextLevel, r, 2, 0, 1, 9);

                                r = dims.Item3;
                                r.Offset(520, 75);
                                ITEM[pos, 11] = new IGMDataItem_Icon(Icons.ID.P, r, 2);
                            }
                            else
                            {
                                for (int i = 7; i < Depth; i++)
                                {
                                    ITEM[pos, i] = null;
                                }
                            }
                        }
                        else
                        {
                            ITEM[pos, 0] = new IGMDataItem_Box(pos: SIZE[pos]);
                            BLANKS[pos]  = true;
                            for (int i = 1; i < Depth; i++)
                            {
                                ITEM[pos, i] = null;
                            }
                        }
                    }
                }
Ejemplo n.º 30
0
            public override void Refresh()
            {
                if (Memory.State?.Characters != null)
                {
                    List <KeyValuePair <int, Characters> > party = Memory.State.Party.Select((element, index) => new { element, index }).ToDictionary(m => m.index, m => m.element).Where(m => !m.Value.Equals(Characters.Blank)).ToList();
                    byte pos = (byte)party.FindIndex(x => x.Value == VisableCharacter);
                    foreach (KeyValuePair <int, Characters> pm in party.Where(x => x.Value == VisableCharacter))
                    {
                        Saves.CharacterData c    = Memory.State.Characters[Memory.State.PartyData[pm.Key]];
                        FF8String           name = Memory.Strings.GetName(pm.Value);
                        int HP = c.CurrentHP(pm.Value);
                        //int MaxHP = c.MaxHP(pm.Value);
                        //float HPpercent = c.PercentFullHP(pm.Value);
                        int          CriticalHP = c.CriticalHP(pm.Value);
                        Font.ColorID colorid    = Font.ColorID.White;
                        byte         palette    = 2;
                        if (HP < CriticalHP)
                        {
                            colorid = Font.ColorID.Yellow;
                            palette = 6;
                        }
                        if (HP <= 0)
                        {
                            colorid = Font.ColorID.Red;
                            palette = 5;
                        }
                        byte?        fadedpalette = null;
                        Font.ColorID?fadedcolorid = null;
                        bool         blink        = false;
                        if (mode == Mode.YourTurn)
                        {
                            blink        = true;
                            fadedpalette = 7;
                            fadedcolorid = Font.ColorID.Grey;
                            ITEM[pos, 2] = new IGMDataItem_Texture(dot, new Rectangle(SIZE[pos].X + 230, SIZE[pos].Y + 12, 150, 15), Color.LightYellow * .8f, new Color(125, 125, 0, 255) * .8f)
                            {
                                Blink = blink
                            };
                        }
                        else if (mode == Mode.ATB_Charged)
                        {
                            ITEM[pos, 2] = new IGMDataItem_Texture(dot, new Rectangle(SIZE[pos].X + 230, SIZE[pos].Y + 12, 150, 15), Color.Yellow * .8f);
                        }
                        // insert gradient atb bar here. Though this probably belongs in the update
                        // method as it'll be in constant flux.
                        else
                        {
                            ITEM[pos, 2] = null;
                        }

                        // TODO: make a font render that can draw right to left from a point. For Right aligning the names.
                        ITEM[pos, 0] = new IGMDataItem_String(name, new Rectangle(SIZE[pos].X, SIZE[pos].Y, 0, 0), colorid, faded_fontcolor: fadedcolorid)
                        {
                            Blink = blink
                        };
                        ITEM[pos, 1] = new IGMDataItem_Int(HP, new Rectangle(SIZE[pos].X + 128, SIZE[pos].Y, 0, 0), palette: palette, faded_palette: fadedpalette, spaces: 4, numtype: Icons.NumType.Num_8x16_1)
                        {
                            Blink = blink
                        };

                        ITEM[pos, 3] = new IGMDataItem_Icon(Icons.ID.Size_08x64_Bar, new Rectangle(SIZE[pos].X + 230, SIZE[pos].Y + 12, 150, 15), 0);
                        pos++;
                    }
                    base.Refresh();
                }
            }