Пример #1
0
        private void getList()
        {
            entry = Util.getIndex(CB_Species);

            int[]  specForm = Personal.getSpecies(data, Main.oras, entry);
            string filename = "_" + specForm[0] + (entry > 721 ? "_" + (specForm[1] + 1) : "");

            PB_MonSprite.Image = (Bitmap)Resources.ResourceManager.GetObject(filename);

            dgv.Rows.Clear();
            byte[] input = File.ReadAllBytes(files[entry]);
            if (input.Length == 0)
            {
                return;
            }
            pkm = new EggMoves(input);
            if (pkm.Count < 1)
            {
                File.WriteAllBytes(files[entry], new byte[0]); return;
            }
            dgv.Rows.Add(pkm.Count);

            // Fill Entries
            for (int i = 0; i < pkm.Count; i++)
            {
                dgv.Rows[i].Cells[0].Value = movelist[pkm.Moves[i]];
            }

            dgv.CancelEdit();
        }
Пример #2
0
        private void getList()
        {
            entry = Util.getIndex(CB_Species);
            int s = 0, f = 0;

            if (entry <= Main.Config.MaxSpeciesID)
            {
                s = entry;
            }
            int[]  specForm = { s, f };
            string filename = "_" + specForm[0] + (entry > Main.Config.MaxSpeciesID ? "_" + (specForm[1] + 1) : "");

            PB_MonSprite.Image = (Bitmap)Resources.ResourceManager.GetObject(filename);

            dgv.Rows.Clear();
            byte[] input = files[entry];
            pkm = new EggMoves7(input);
            NUD_FormTable.Value = pkm.FormTableIndex;
            if (pkm.Count < 1)
            {
                files[entry] = new byte[0]; return;
            }
            dgv.Rows.Add(pkm.Count);

            // Fill Entries
            for (int i = 0; i < pkm.Count; i++)
            {
                dgv.Rows[i].Cells[0].Value = movelist[pkm.Moves[i]];
            }

            dgv.CancelEdit();
        }
Пример #3
0
        private void GetList()
        {
            entry = WinFormsUtil.GetIndex(CB_Species);

            int[]  specForm = Main.Config.Personal.GetSpeciesForm(entry, Main.Config);
            string filename = "_" + specForm[0] + (entry > 721 ? "_" + (specForm[1] + 1) : "");

            PB_MonSprite.Image = (Bitmap)Resources.ResourceManager.GetObject(filename);

            dgv.Rows.Clear();
            byte[] input = files[entry];
            if (input.Length == 0)
            {
                return;
            }
            pkm = new EggMoves6(input);
            if (pkm.Count < 1)
            {
                files[entry] = Array.Empty <byte>(); return;
            }
            dgv.Rows.Add(pkm.Count);

            // Fill Entries
            for (int i = 0; i < pkm.Count; i++)
            {
                dgv.Rows[i].Cells[0].Value = movelist[pkm.Moves[i]];
            }

            dgv.CancelEdit();
        }
Пример #4
0
 public static EggMoves[] getArray(byte[][] entries)
 {
     EggMoves[] data = new EggMoves[entries.Length];
     for (int i = 0; i < data.Length; i++)
         data[i] = new EggMoves6(entries[i]);
     return data;
 }
Пример #5
0
 public static EggMoves[] getArray(byte[][] entries)
 {
     EggMoves[] data = new EggMoves[entries.Length];
     for (int i = 0; i < data.Length; i++)
     {
         data[i] = new EggMoves7(entries[i]);
     }
     return(data);
 }
Пример #6
0
        private void getList()
        {
            entry = Util.getIndex(CB_Species);
            int s = 0, f = 0;
            if (entry <= Main.Config.MaxSpeciesID)
            {
                s = entry;
            }
            int[] specForm = { s, f };
            string filename = "_" + specForm[0] + (entry > Main.Config.MaxSpeciesID ? "_" + (specForm[1] + 1) : "");
            PB_MonSprite.Image = (Bitmap)Resources.ResourceManager.GetObject(filename);

            dgv.Rows.Clear();
            byte[] input = files[entry];
            pkm = new EggMoves7(input);
            NUD_FormTable.Value = pkm.FormTableIndex;
            if (pkm.Count < 1) { files[entry] = new byte[0]; return; }
            dgv.Rows.Add(pkm.Count);

            // Fill Entries
            for (int i = 0; i < pkm.Count; i++)
                dgv.Rows[i].Cells[0].Value = movelist[pkm.Moves[i]];

            dgv.CancelEdit();
        }
Пример #7
0
        private void getList()
        {
            entry = Util.getIndex(CB_Species);

            int[] specForm = Main.Config.Personal.getSpeciesForm(entry);
            string filename = "_" + specForm[0] + (entry > 721 ? "_" + (specForm[1] + 1) : "");
            PB_MonSprite.Image = (Bitmap)Resources.ResourceManager.GetObject(filename);

            dgv.Rows.Clear();
            byte[] input = files[entry];
            if (input.Length == 0) return;
            pkm = new EggMoves6(input);
            if (pkm.Count < 1) { files[entry] = new byte[0]; return; }
            dgv.Rows.Add(pkm.Count);

            // Fill Entries
            for (int i = 0; i < pkm.Count; i++)
                dgv.Rows[i].Cells[0].Value = movelist[pkm.Moves[i]];

            dgv.CancelEdit();
        }