BrawlBuilder.BrawlBuilder.Extract C# (CSharp) Méthode

Extract() private méthode

private Extract ( ProcessStartInfo pStartInfo ) : bool
pStartInfo ProcessStartInfo
Résultat bool
		private bool Extract(ProcessStartInfo pStartInfo)
		{
			SetStatus("Extracting...");

			bool skipExtraction = false;

			// Check if there is already an extracted Brawl folder
			if (Directory.Exists("ssbb.d") && brawlIso.Text == "")
			{
				skipExtraction = true;
			}
			else if (Directory.Exists("ssbb.d"))
			{
				DialogResult result = MessageBox.Show("There is already an ssbb.d directory. Would you like to skip the extraction and use these files instead?\n\nNote: If you choose 'No', the current ssbb.d directory will be overwritten.", "Notice", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
				if (result == DialogResult.Yes)
					skipExtraction = true;
				else
					DeleteBrawlFolder();

				if (buildWorker.CancellationPending)
					return false;
			}

			if (!skipExtraction)
			{
				// Extract brawl to ssbb.d folder
				pStartInfo.Arguments = "extract \"" + brawlIso.Text + "\" ssbb.d --psel=DATA -1ovv";

				if (!DoWit(pStartInfo))
					return false;
			}

			if (!Directory.Exists("ssbb.d"))
				StopWorker("Extraction failed, stopping build...");

			if (buildWorker.CancellationPending)
			{
				// Since we have been copying files in, ssbb.d is no longer a clean Brawl. Delete it.
				DeleteBrawlFolder();
				return false;
			}

			return true;
		}