mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Add debugging output
This commit is contained in:
@@ -68,6 +68,8 @@ namespace SabreTools
|
|||||||
entry.Remove(0, _tempDir.Length),
|
entry.Remove(0, _tempDir.Length),
|
||||||
(new FileInfo(entry)).Length,
|
(new FileInfo(entry)).Length,
|
||||||
tempHash));
|
tempHash));
|
||||||
|
|
||||||
|
Console.WriteLine("File parsed: " + entry.Remove(0, _tempDir.Length));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Otherwise, just get the info on the file itself
|
// Otherwise, just get the info on the file itself
|
||||||
@@ -92,6 +94,8 @@ namespace SabreTools
|
|||||||
item.Remove(0, _basePath.Length).Remove(0, actualpath.Length + (actualpath != "" ? 1 : 0)),
|
item.Remove(0, _basePath.Length).Remove(0, actualpath.Length + (actualpath != "" ? 1 : 0)),
|
||||||
(new FileInfo(item)).Length,
|
(new FileInfo(item)).Length,
|
||||||
tempHash));
|
tempHash));
|
||||||
|
|
||||||
|
Console.WriteLine("File parsed: " + item.Remove(0, _basePath.Length));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Delete the temp directory
|
// Delete the temp directory
|
||||||
@@ -126,22 +130,17 @@ namespace SabreTools
|
|||||||
Console.WriteLine(rom.Item1 + "\t" + rom.Item2 + "\t" + rom.Item3 + "\t" + rom.Item4);
|
Console.WriteLine(rom.Item1 + "\t" + rom.Item2 + "\t" + rom.Item3 + "\t" + rom.Item4);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//TODO: So, this below section is a pretty much one for one copy of code that is written in generate
|
||||||
|
// this means that in the future, "writing to DAT" will be abstracted out to the DLL so that any
|
||||||
|
// properly formatted data can be passed in and it will get written as necessary. That would open
|
||||||
|
// the possibiliites for different ways to generate a DAT from multiple things
|
||||||
|
|
||||||
// Now write it all out as a DAT
|
// Now write it all out as a DAT
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
FileStream fs = File.Create("dirdat.xml");
|
FileStream fs = File.Create("dirdat.xml");
|
||||||
StreamWriter sw = new StreamWriter(fs, Encoding.UTF8);
|
StreamWriter sw = new StreamWriter(fs, Encoding.UTF8);
|
||||||
|
|
||||||
/*
|
|
||||||
string header_old = "clrmamepro (\n" +
|
|
||||||
"\tname \"dirdat\"\n" +
|
|
||||||
"\tdescription \"dirdat\"\n" +
|
|
||||||
"\tversion \"\"\n" +
|
|
||||||
"\tcomment \"\"\n" +
|
|
||||||
"\tauthor \"DATFromDir\"\n" +
|
|
||||||
")\n";
|
|
||||||
*/
|
|
||||||
|
|
||||||
string header = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" +
|
string header = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" +
|
||||||
"<!DOCTYPE datafile PUBLIC \"-//Logiqx//DTD ROM Management Datafile//EN\" \"http://www.logiqx.com/Dats/datafile.dtd\">\n\n" +
|
"<!DOCTYPE datafile PUBLIC \"-//Logiqx//DTD ROM Management Datafile//EN\" \"http://www.logiqx.com/Dats/datafile.dtd\">\n\n" +
|
||||||
"\t<datafile>\n" +
|
"\t<datafile>\n" +
|
||||||
|
|||||||
Reference in New Issue
Block a user