public static Learnset[] getArray(byte[][] entries) { Learnset[] data = new Learnset[entries.Length]; for (int i = 0; i < data.Length; i++) data[i] = new Learnset6(entries[i]); return data; }
public static Learnset[] getArray(byte[][] entries) { Learnset[] data = new Learnset[entries.Length]; for (int i = 0; i < data.Length; i++) { data[i] = new Learnset7(entries[i]); } return(data); }
private void getList() { entry = Util.getIndex(CB_Species); int s = baseForms[entry]; int f = formVal[entry]; 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]; if (input.Length <= 4) { files[entry] = BitConverter.GetBytes(-1); return; } pkm = new Learnset7(input); dgv.Rows.Add(pkm.Count); // Fill Entries for (int i = 0; i < pkm.Count; i++) { dgv.Rows[i].Cells[0].Value = pkm.Levels[i]; dgv.Rows[i].Cells[1].Value = movelist[pkm.Moves[i]]; } dgv.CancelEdit(); }
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 <= 4) { File.WriteAllBytes(files[entry], BitConverter.GetBytes(-1)); return; } pkm = new Learnset(input); dgv.Rows.Add(pkm.Count); // Fill Entries for (int i = 0; i < pkm.Count; i++) { dgv.Rows[i].Cells[0].Value = pkm.Levels[i]; dgv.Rows[i].Cells[1].Value = movelist[pkm.Moves[i]]; } dgv.CancelEdit(); }