fix breakage from june of opening libretro cores (fixes #1357)
@asnivor please check loading bundler XMLs
This commit is contained in:
parent
dac6c0a062
commit
2948d7597a
|
@ -3659,39 +3659,44 @@ namespace BizHawk.Client.EmuHawk
|
||||||
CoreFileProvider.SyncCoreCommInputSignals(nextComm);
|
CoreFileProvider.SyncCoreCommInputSignals(nextComm);
|
||||||
InputManager.SyncControls();
|
InputManager.SyncControls();
|
||||||
|
|
||||||
if (Path.GetExtension(loaderName.Replace("*OpenRom*", "").Replace("|", "")).ToLower() == ".xml")
|
if (ioa is OpenAdvanced_OpenRom)
|
||||||
{
|
{
|
||||||
// this is a multi-disk bundler file
|
OpenAdvanced_OpenRom ioa_openRom = ioa as OpenAdvanced_OpenRom;
|
||||||
// determine the xml assets and create RomStatusDetails for all of them
|
|
||||||
var xmlGame = XmlGame.Create(new HawkFile(loaderName.Replace("*OpenRom*", "")));
|
|
||||||
|
|
||||||
StringWriter xSw = new StringWriter();
|
if (Path.GetExtension(ioa_openRom.Path).ToLower() == ".xml")
|
||||||
|
{
|
||||||
|
// this is a multi-disk bundler file
|
||||||
|
// determine the xml assets and create RomStatusDetails for all of them
|
||||||
|
var xmlGame = XmlGame.Create(new HawkFile(ioa_openRom.Path));
|
||||||
|
|
||||||
for (int xg = 0; xg < xmlGame.Assets.Count; xg++)
|
StringWriter xSw = new StringWriter();
|
||||||
{
|
|
||||||
var ext = Path.GetExtension(xmlGame.AssetFullPaths[xg]).ToLower();
|
|
||||||
|
|
||||||
if (ext == ".cue" || ext == ".ccd" || ext == ".toc" || ext == ".mds")
|
for (int xg = 0; xg < xmlGame.Assets.Count; xg++)
|
||||||
{
|
{
|
||||||
xSw.WriteLine(Path.GetFileNameWithoutExtension(xmlGame.Assets[xg].Key));
|
var ext = Path.GetExtension(xmlGame.AssetFullPaths[xg]).ToLower();
|
||||||
xSw.WriteLine("SHA1:N/A");
|
|
||||||
xSw.WriteLine("MD5:N/A");
|
|
||||||
xSw.WriteLine();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
xSw.WriteLine(xmlGame.Assets[xg].Key);
|
|
||||||
xSw.WriteLine("SHA1:" + xmlGame.Assets[xg].Value.HashSHA1());
|
|
||||||
xSw.WriteLine("MD5:" + xmlGame.Assets[xg].Value.HashMD5());
|
|
||||||
xSw.WriteLine();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Emulator.CoreComm.RomStatusDetails = xSw.ToString();
|
if (ext == ".cue" || ext == ".ccd" || ext == ".toc" || ext == ".mds")
|
||||||
Emulator.CoreComm.RomStatusAnnotation = "Multi-disk bundler";
|
{
|
||||||
}
|
xSw.WriteLine(Path.GetFileNameWithoutExtension(xmlGame.Assets[xg].Key));
|
||||||
|
xSw.WriteLine("SHA1:N/A");
|
||||||
|
xSw.WriteLine("MD5:N/A");
|
||||||
|
xSw.WriteLine();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
xSw.WriteLine(xmlGame.Assets[xg].Key);
|
||||||
|
xSw.WriteLine("SHA1:" + xmlGame.Assets[xg].Value.HashSHA1());
|
||||||
|
xSw.WriteLine("MD5:" + xmlGame.Assets[xg].Value.HashMD5());
|
||||||
|
xSw.WriteLine();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (Emulator is TI83 && Global.Config.TI83autoloadKeyPad)
|
Emulator.CoreComm.RomStatusDetails = xSw.ToString();
|
||||||
|
Emulator.CoreComm.RomStatusAnnotation = "Multi-disk bundler";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (Emulator is TI83 && Global.Config.TI83autoloadKeyPad)
|
||||||
{
|
{
|
||||||
GlobalWin.Tools.Load<TI83KeyPad>();
|
GlobalWin.Tools.Load<TI83KeyPad>();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue