コード例 #1
0
        static void Main(string[] args)
        {
            var directoryName = "./files";

            if (!Directory.Exists(directoryName))
            {
                Directory.CreateDirectory(directoryName);
            }
            var isoExtract = new ISOExtractor("Pokemon XD - Gale of Darkness (USA).iso");
            var iso        = isoExtract.ExtractISO();

            Console.Read();
        }
コード例 #2
0
        private void loadIsoButton_Click(object sender, EventArgs e)
        {
            openISODialog.Filter          = "Colosseum or XD Game File|*.iso;*.zip";
            openISODialog.CheckFileExists = true;
            if (openISODialog.ShowDialog() == DialogResult.OK)
            {
                iso?.Dispose();
                isoExtractor?.Dispose();

                progressMessageLabel.Text = "Reading ISO...";

                if (OpenFile())
                {
                    iso = isoExtractor.ExtractISO();
                    switch (iso.Game)
                    {
                    case Game.Colosseum:
                    {
                        gamePictureBox.Image          = new Bitmap("Images/colo-logo.jpg");
                        gameExtractor                 = new ColoExtractor();
                        starterComboBox.SelectedItem  = "ESPEON";
                        starter2ComboBox.SelectedItem = "UMBREON";
                        // disable XD only options
                        foreach (Control ctrl in battleBingoTabPage.Controls)
                        {
                            ctrl.Enabled = false;
                        }
                        pokeSpotGroupBox.Enabled = false;
                        break;
                    }

                    case Game.XD:
                    {
                        gamePictureBox.Image         = new Bitmap("Images/xd-logo.jpg");
                        gameExtractor                = new XDExtractor(iso);
                        starterComboBox.SelectedItem = "EEVEE";
                        starter2Label.Visible        = false;
                        starter2ComboBox.Visible     = false;
                        break;
                    }

                    default:
                        return;
                    }
                    gameLabel.Text   = iso.Game.ToString();
                    regionLabel.Text = iso.Region.ToString();

                    progressMessageLabel.Text = "Successfully read ISO";
                }
            }
        }