Add files via upload

This commit is contained in:
alyosha-tas 2017-06-24 16:01:07 -04:00 committed by GitHub
parent c60763484d
commit b54a738c97
2 changed files with 15 additions and 8 deletions
BizHawk.Emulation.Cores/Consoles/Nintendo/Gameboy

View File

@ -80,7 +80,7 @@ namespace BizHawk.Emulation.Cores.Nintendo.Gameboy
public class GambatteSyncSettings
{
[DisplayName("Use System BIOS")]
[DisplayName("Enable BIOS: WARNING: File must exist!")]
[Description("Boots game using system BIOS. Should be used for TASing")]
[DefaultValue(false)]
public bool EnableBIOS { get; set; }

View File

@ -80,10 +80,22 @@ namespace BizHawk.Emulation.Cores.Nintendo.Gameboy
LibGambatte.LoadFlags flags = 0;
if (_syncSettings.ForceDMG)
{
flags |= LibGambatte.LoadFlags.FORCE_DMG;
// we need to change the BIOS to GB bios
if (game.System == "GBC")
{
BiosRom = null;
BiosRom = new byte[256];
BiosRom = comm.CoreFileProvider.GetFirmware("GB", "World", false);
}
}
if (_syncSettings.EnableBIOS && BiosRom == null)
{
Console.WriteLine("Warning: BIOS not found, loading without BIOS");
bios_length = 0;
throw new MissingFirmwareException("Boot Rom not found");
}
// to disable BIOS loading into gambatte, just set bios_length to 0
@ -92,11 +104,6 @@ namespace BizHawk.Emulation.Cores.Nintendo.Gameboy
bios_length = 0;
}
if (_syncSettings.ForceDMG)
{
flags |= LibGambatte.LoadFlags.FORCE_DMG;
}
if (_syncSettings.GBACGB)
{
flags |= LibGambatte.LoadFlags.GBA_CGB;