rename puae to uae
while libretro initially ported original puae (which is long dead), they switched to just pulling updates from winuae every once in a while (and renamed to libretro-uae), because it's still active and is kinda considered golden standard these days
This commit is contained in:
parent
4274b75379
commit
18078c8764
|
@ -34,7 +34,7 @@ namespace BizHawk.Client.EmuHawk.CoreExtensions
|
|||
MAME => Properties.Resources.Mame,
|
||||
MGBAHawk => Properties.Resources.Mgba,
|
||||
NDS => Properties.Resources.MelonDS,
|
||||
PUAE => Properties.Resources.Amiga,
|
||||
UAE => Properties.Resources.Amiga,
|
||||
_ => null
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1332,8 +1332,8 @@ namespace BizHawk.Client.EmuHawk
|
|||
// PicoDrive
|
||||
items.Add(CreateCoreSubmenu(VSystemCategory.Consoles, CoreNames.PicoDrive, CreateGenericCoreConfigItem<PicoDrive>(CoreNames.PicoDrive)));
|
||||
|
||||
// PUAE
|
||||
items.Add(CreateCoreSubmenu(VSystemCategory.PCs, CoreNames.PUAE, CreateGenericCoreConfigItem<PUAE>(CoreNames.PUAE)));
|
||||
// UAE
|
||||
items.Add(CreateCoreSubmenu(VSystemCategory.PCs, CoreNames.UAE, CreateGenericCoreConfigItem<UAE>(CoreNames.UAE)));
|
||||
|
||||
// QuickNes
|
||||
var quickNesGamepadSettingsItem = CreateSettingsItem("Controller Settings...", (_, _) => OpenQuickNesGamepadSettingsDialog(GetSettingsAdapterFor<QuickNES>()));
|
||||
|
|
|
@ -6,23 +6,23 @@ using BizHawk.Emulation.Cores.Waterbox;
|
|||
|
||||
namespace BizHawk.Emulation.Cores.Computers.Amiga
|
||||
{
|
||||
public abstract class LibPUAE : LibWaterboxCore
|
||||
public abstract class LibUAE : LibWaterboxCore
|
||||
{
|
||||
public const int PAL_WIDTH = 720;
|
||||
public const int NTSC_WIDTH = PAL_WIDTH;
|
||||
// the core renders 576 which is what libretro displays
|
||||
// but default window height is 568 in original PUAE and WinUAE
|
||||
// but default window height is 568 in original UAE and WinUAE
|
||||
// this lets us hide a black line and a weird artifact that our A600 config has there
|
||||
public const int PAL_HEIGHT = 568;
|
||||
// WinUAE displays 484 lines for NTSC
|
||||
// but libretro port only renders 482 and then only displays 480
|
||||
public const int NTSC_HEIGHT = 482;
|
||||
// libretro defines PUAE_VIDEO_HZ_PAL as 49.9204101562500000f
|
||||
public const int PUAE_VIDEO_NUMERATOR_PAL = 102237;
|
||||
public const int PUAE_VIDEO_DENOMINATOR_PAL = 2048;
|
||||
// libretro defines PUAE_VIDEO_HZ_NTSC as 59.8260993957519531f
|
||||
public const int PUAE_VIDEO_NUMERATOR_NTSC = 299130497;
|
||||
public const int PUAE_VIDEO_DENOMINATOR_NTSC = 5000000;
|
||||
// libretro defines UAE_VIDEO_HZ_PAL as 49.9204101562500000f
|
||||
public const int UAE_VIDEO_NUMERATOR_PAL = 102237;
|
||||
public const int UAE_VIDEO_DENOMINATOR_PAL = 2048;
|
||||
// libretro defines UAE_VIDEO_HZ_NTSC as 59.8260993957519531f
|
||||
public const int UAE_VIDEO_NUMERATOR_NTSC = 299130497;
|
||||
public const int UAE_VIDEO_DENOMINATOR_NTSC = 5000000;
|
||||
|
||||
public const int FASTMEM_AUTO = -1;
|
||||
public const int MAX_FLOPPIES = 4;
|
||||
|
@ -123,7 +123,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
}
|
||||
|
||||
// https://wiki.amigaos.net/wiki/Keymap_Library
|
||||
public enum PUAEKeyboard : int
|
||||
public enum UAEKeyboard : int
|
||||
{
|
||||
Key_Backquote = 0x00,
|
||||
Key_1 = 0x01,
|
|
@ -6,69 +6,69 @@ using BizHawk.Emulation.Common;
|
|||
|
||||
namespace BizHawk.Emulation.Cores.Computers.Amiga
|
||||
{
|
||||
public partial class PUAE
|
||||
public partial class UAE
|
||||
{
|
||||
private LibPUAE.ControllerType[] _ports { get; set; }
|
||||
private static readonly (string Name, LibPUAE.AllButtons Button)[] _joystickMap = CreateJoystickMap();
|
||||
private static readonly (string Name, LibPUAE.AllButtons Button)[] _cd32padMap = CreateCd32padMap();
|
||||
private static readonly (string Name, LibPUAE.PUAEKeyboard Key)[] _keyboardMap = CreateKeyboardMap();
|
||||
private LibUAE.ControllerType[] _ports { get; set; }
|
||||
private static readonly (string Name, LibUAE.AllButtons Button)[] _joystickMap = CreateJoystickMap();
|
||||
private static readonly (string Name, LibUAE.AllButtons Button)[] _cd32padMap = CreateCd32padMap();
|
||||
private static readonly (string Name, LibUAE.UAEKeyboard Key)[] _keyboardMap = CreateKeyboardMap();
|
||||
|
||||
private static (string Name, LibPUAE.AllButtons Value)[] CreateJoystickMap()
|
||||
private static (string Name, LibUAE.AllButtons Value)[] CreateJoystickMap()
|
||||
{
|
||||
var joystickMap = new List<(string, LibPUAE.AllButtons)>();
|
||||
var joystickMap = new List<(string, LibUAE.AllButtons)>();
|
||||
// ReSharper disable once LoopCanBeConvertedToQuery
|
||||
foreach (var b in Enum.GetValues(typeof(LibPUAE.AllButtons)))
|
||||
foreach (var b in Enum.GetValues(typeof(LibUAE.AllButtons)))
|
||||
{
|
||||
if (((short)b & LibPUAE.JoystickMask) == 0)
|
||||
if (((short)b & LibUAE.JoystickMask) == 0)
|
||||
continue;
|
||||
|
||||
var name = Enum.GetName(typeof(LibPUAE.AllButtons), b)!.Replace('_', ' ');
|
||||
joystickMap.Add((name, (LibPUAE.AllButtons)b));
|
||||
var name = Enum.GetName(typeof(LibUAE.AllButtons), b)!.Replace('_', ' ');
|
||||
joystickMap.Add((name, (LibUAE.AllButtons)b));
|
||||
}
|
||||
return joystickMap.ToArray();
|
||||
}
|
||||
|
||||
private static (string Name, LibPUAE.AllButtons Value)[] CreateCd32padMap()
|
||||
private static (string Name, LibUAE.AllButtons Value)[] CreateCd32padMap()
|
||||
{
|
||||
var joystickMap = new List<(string, LibPUAE.AllButtons)>();
|
||||
var joystickMap = new List<(string, LibUAE.AllButtons)>();
|
||||
// ReSharper disable once LoopCanBeConvertedToQuery
|
||||
foreach (var b in Enum.GetValues(typeof(LibPUAE.AllButtons)))
|
||||
foreach (var b in Enum.GetValues(typeof(LibUAE.AllButtons)))
|
||||
{
|
||||
if (((short)b & LibPUAE.Cd32padMask) == 0)
|
||||
if (((short)b & LibUAE.Cd32padMask) == 0)
|
||||
continue;
|
||||
|
||||
var name = Enum.GetName(typeof(LibPUAE.AllButtons), b)!.Replace('_', ' ');
|
||||
joystickMap.Add((name, (LibPUAE.AllButtons)b));
|
||||
var name = Enum.GetName(typeof(LibUAE.AllButtons), b)!.Replace('_', ' ');
|
||||
joystickMap.Add((name, (LibUAE.AllButtons)b));
|
||||
}
|
||||
return joystickMap.ToArray();
|
||||
}
|
||||
|
||||
private static (string Name, LibPUAE.PUAEKeyboard Value)[] CreateKeyboardMap()
|
||||
private static (string Name, LibUAE.UAEKeyboard Value)[] CreateKeyboardMap()
|
||||
{
|
||||
var keyboardMap = new List<(string, LibPUAE.PUAEKeyboard)>();
|
||||
var keyboardMap = new List<(string, LibUAE.UAEKeyboard)>();
|
||||
// ReSharper disable once LoopCanBeConvertedToQuery
|
||||
foreach (var k in Enum.GetValues(typeof(LibPUAE.PUAEKeyboard)))
|
||||
foreach (var k in Enum.GetValues(typeof(LibUAE.UAEKeyboard)))
|
||||
{
|
||||
var name = Enum.GetName(typeof(LibPUAE.PUAEKeyboard), k)!.Replace('_', ' ');
|
||||
keyboardMap.Add((name, (LibPUAE.PUAEKeyboard)k));
|
||||
var name = Enum.GetName(typeof(LibUAE.UAEKeyboard), k)!.Replace('_', ' ');
|
||||
keyboardMap.Add((name, (LibUAE.UAEKeyboard)k));
|
||||
}
|
||||
|
||||
return keyboardMap.ToArray();
|
||||
}
|
||||
|
||||
private static ControllerDefinition CreateControllerDefinition(PUAESyncSettings settings)
|
||||
private static ControllerDefinition CreateControllerDefinition(UAESyncSettings settings)
|
||||
{
|
||||
var controller = new ControllerDefinition("Amiga Controller");
|
||||
|
||||
for (int port = 1; port <= 2; port++)
|
||||
{
|
||||
LibPUAE.ControllerType type = port == 1
|
||||
LibUAE.ControllerType type = port == 1
|
||||
? settings.ControllerPort1
|
||||
: settings.ControllerPort2;
|
||||
|
||||
switch (type)
|
||||
{
|
||||
case LibPUAE.ControllerType.Joystick:
|
||||
case LibUAE.ControllerType.Joystick:
|
||||
{
|
||||
foreach (var (name, _) in _joystickMap)
|
||||
{
|
||||
|
@ -76,7 +76,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
}
|
||||
break;
|
||||
}
|
||||
case LibPUAE.ControllerType.CD32_pad:
|
||||
case LibUAE.ControllerType.CD32_pad:
|
||||
{
|
||||
foreach (var (name, _) in _cd32padMap)
|
||||
{
|
||||
|
@ -84,7 +84,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
}
|
||||
break;
|
||||
}
|
||||
case LibPUAE.ControllerType.Mouse:
|
||||
case LibUAE.ControllerType.Mouse:
|
||||
{
|
||||
controller.BoolButtons.AddRange(
|
||||
[
|
||||
|
@ -93,8 +93,8 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
$"P{port} {Inputs.MouseRightButton}"
|
||||
]);
|
||||
controller
|
||||
.AddAxis($"P{port} {Inputs.MouseX}", 0.RangeTo(LibPUAE.PAL_WIDTH), LibPUAE.PAL_WIDTH / 2)
|
||||
.AddAxis($"P{port} {Inputs.MouseY}", 0.RangeTo(LibPUAE.PAL_HEIGHT), LibPUAE.PAL_HEIGHT / 2);
|
||||
.AddAxis($"P{port} {Inputs.MouseX}", 0.RangeTo(LibUAE.PAL_WIDTH), LibUAE.PAL_WIDTH / 2)
|
||||
.AddAxis($"P{port} {Inputs.MouseY}", 0.RangeTo(LibUAE.PAL_HEIGHT), LibUAE.PAL_HEIGHT / 2);
|
||||
break;
|
||||
}
|
||||
}
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
namespace BizHawk.Emulation.Cores.Computers.Amiga
|
||||
{
|
||||
public partial class PUAE : IDriveLight
|
||||
public partial class UAE : IDriveLight
|
||||
{
|
||||
public bool DriveLightEnabled { get; }
|
||||
public bool DriveLightOn { get; private set; }
|
|
@ -7,7 +7,7 @@ using BizHawk.Emulation.Common;
|
|||
|
||||
namespace BizHawk.Emulation.Cores.Computers.Amiga
|
||||
{
|
||||
public partial class PUAE : ISettable<object, PUAE.PUAESyncSettings>
|
||||
public partial class UAE : ISettable<object, UAE.UAESyncSettings>
|
||||
{
|
||||
public enum MachineConfig
|
||||
{
|
||||
|
@ -143,11 +143,11 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
Turbo = 0
|
||||
}
|
||||
|
||||
private void CreateArguments(PUAESyncSettings settings)
|
||||
private void CreateArguments(UAESyncSettings settings)
|
||||
{
|
||||
_args = new List<string>
|
||||
{
|
||||
"puae",
|
||||
"uae",
|
||||
};
|
||||
|
||||
switch(settings.MachineConfig)
|
||||
|
@ -238,7 +238,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
AppendSetting("bogomem_size=" + (int)settings.SlowMemory);
|
||||
}
|
||||
|
||||
if (settings.FastMemory != LibPUAE.FASTMEM_AUTO)
|
||||
if (settings.FastMemory != LibUAE.FASTMEM_AUTO)
|
||||
{
|
||||
AppendSetting("fastmem_size=" + settings.FastMemory);
|
||||
}
|
||||
|
@ -258,19 +258,19 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
|
||||
for (int port = 0; port <= 1; port++)
|
||||
{
|
||||
LibPUAE.ControllerType type = port == 0
|
||||
LibUAE.ControllerType type = port == 0
|
||||
? settings.ControllerPort1
|
||||
: settings.ControllerPort2;
|
||||
|
||||
switch (type)
|
||||
{
|
||||
case LibPUAE.ControllerType.Joystick:
|
||||
case LibUAE.ControllerType.Joystick:
|
||||
AppendSetting($"joyport{port}mode=djoy");
|
||||
break;
|
||||
case LibPUAE.ControllerType.CD32_pad:
|
||||
case LibUAE.ControllerType.CD32_pad:
|
||||
AppendSetting($"joyport{port}mode=cd32joy");
|
||||
break;
|
||||
case LibPUAE.ControllerType.Mouse:
|
||||
case LibUAE.ControllerType.Mouse:
|
||||
AppendSetting($"joyport{port}mode=mouse");
|
||||
break;
|
||||
}
|
||||
|
@ -307,19 +307,19 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
public object GetSettings() => null;
|
||||
public PutSettingsDirtyBits PutSettings(object o) => PutSettingsDirtyBits.None;
|
||||
|
||||
private PUAESyncSettings _syncSettings;
|
||||
public PUAESyncSettings GetSyncSettings()
|
||||
private UAESyncSettings _syncSettings;
|
||||
public UAESyncSettings GetSyncSettings()
|
||||
=> _syncSettings.Clone();
|
||||
|
||||
public PutSettingsDirtyBits PutSyncSettings(PUAESyncSettings o)
|
||||
public PutSettingsDirtyBits PutSyncSettings(UAESyncSettings o)
|
||||
{
|
||||
var ret = PUAESyncSettings.NeedsReboot(_syncSettings, o);
|
||||
var ret = UAESyncSettings.NeedsReboot(_syncSettings, o);
|
||||
_syncSettings = o;
|
||||
return ret ? PutSettingsDirtyBits.RebootCore : PutSettingsDirtyBits.None;
|
||||
}
|
||||
|
||||
[CoreSettings]
|
||||
public class PUAESyncSettings
|
||||
public class UAESyncSettings
|
||||
{
|
||||
[DisplayName("Machine configuration")]
|
||||
[Description("")]
|
||||
|
@ -358,22 +358,22 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
|
||||
[DisplayName("Fast memory")]
|
||||
[Description("Size in megabytes of fast-memory. -1 means Auto. Overrides machine configuration.")]
|
||||
[Range(LibPUAE.FASTMEM_AUTO, 512)]
|
||||
[DefaultValue(LibPUAE.FASTMEM_AUTO)]
|
||||
[Range(LibUAE.FASTMEM_AUTO, 512)]
|
||||
[DefaultValue(LibUAE.FASTMEM_AUTO)]
|
||||
[TypeConverter(typeof(ConstrainedIntConverter))]
|
||||
public int FastMemory { get; set; }
|
||||
|
||||
[DisplayName("Controller port 1")]
|
||||
[Description("")]
|
||||
[DefaultValue(LibPUAE.ControllerType.Mouse)]
|
||||
[DefaultValue(LibUAE.ControllerType.Mouse)]
|
||||
[TypeConverter(typeof(DescribableEnumConverter))]
|
||||
public LibPUAE.ControllerType ControllerPort1 { get; set; }
|
||||
public LibUAE.ControllerType ControllerPort1 { get; set; }
|
||||
|
||||
[DisplayName("Controller port 2")]
|
||||
[Description("")]
|
||||
[DefaultValue(LibPUAE.ControllerType.Joystick)]
|
||||
[DefaultValue(LibUAE.ControllerType.Joystick)]
|
||||
[TypeConverter(typeof(DescribableEnumConverter))]
|
||||
public LibPUAE.ControllerType ControllerPort2 { get; set; }
|
||||
public LibUAE.ControllerType ControllerPort2 { get; set; }
|
||||
|
||||
[DisplayName("Mouse speed")]
|
||||
[Description("Mouse speed in percents (1% - 1000%). Adjust if there's mismatch between emulated and host mouse movement. Note that maximum mouse movement is still 127 pixels due to Amiga hardware limitations.")]
|
||||
|
@ -407,13 +407,13 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
[TypeConverter(typeof(DescribableEnumConverter))]
|
||||
public FloppySpeed FloppySpeed { get; set; }
|
||||
|
||||
public PUAESyncSettings()
|
||||
public UAESyncSettings()
|
||||
=> SettingsUtil.SetDefaultValues(this);
|
||||
|
||||
public PUAESyncSettings Clone()
|
||||
=> (PUAESyncSettings)MemberwiseClone();
|
||||
public UAESyncSettings Clone()
|
||||
=> (UAESyncSettings)MemberwiseClone();
|
||||
|
||||
public static bool NeedsReboot(PUAESyncSettings x, PUAESyncSettings y)
|
||||
public static bool NeedsReboot(UAESyncSettings x, UAESyncSettings y)
|
||||
=> !DeepEquality.DeepEquals(x, y);
|
||||
}
|
||||
}
|
|
@ -8,36 +8,36 @@ using BizHawk.Emulation.Cores.Waterbox;
|
|||
namespace BizHawk.Emulation.Cores.Computers.Amiga
|
||||
{
|
||||
[PortedCore(
|
||||
name: CoreNames.PUAE,
|
||||
name: CoreNames.UAE,
|
||||
author: "UAE Team",
|
||||
portedVersion: "5.0.0",
|
||||
portedUrl: "https://github.com/libretro/libretro-uae",
|
||||
isReleased: false)]
|
||||
public partial class PUAE : WaterboxCore
|
||||
public partial class UAE : WaterboxCore
|
||||
{
|
||||
private static readonly Configuration ConfigPAL = new Configuration
|
||||
{
|
||||
SystemId = VSystemID.Raw.Amiga,
|
||||
MaxSamples = 2 * 1024,
|
||||
DefaultWidth = LibPUAE.PAL_WIDTH,
|
||||
DefaultHeight = LibPUAE.PAL_HEIGHT,
|
||||
MaxWidth = LibPUAE.PAL_WIDTH,
|
||||
MaxHeight = LibPUAE.PAL_HEIGHT,
|
||||
DefaultFpsNumerator = LibPUAE.PUAE_VIDEO_NUMERATOR_PAL,
|
||||
DefaultFpsDenominator = LibPUAE.PUAE_VIDEO_DENOMINATOR_PAL
|
||||
DefaultWidth = LibUAE.PAL_WIDTH,
|
||||
DefaultHeight = LibUAE.PAL_HEIGHT,
|
||||
MaxWidth = LibUAE.PAL_WIDTH,
|
||||
MaxHeight = LibUAE.PAL_HEIGHT,
|
||||
DefaultFpsNumerator = LibUAE.UAE_VIDEO_NUMERATOR_PAL,
|
||||
DefaultFpsDenominator = LibUAE.UAE_VIDEO_DENOMINATOR_PAL
|
||||
};
|
||||
|
||||
private static readonly Configuration ConfigNTSC = new Configuration
|
||||
{
|
||||
SystemId = VSystemID.Raw.Amiga,
|
||||
MaxSamples = 2 * 1024,
|
||||
DefaultWidth = LibPUAE.NTSC_WIDTH,
|
||||
DefaultHeight = LibPUAE.NTSC_HEIGHT,
|
||||
DefaultWidth = LibUAE.NTSC_WIDTH,
|
||||
DefaultHeight = LibUAE.NTSC_HEIGHT,
|
||||
// games never switch region, and video dumping won't be happy, but amiga can still do it
|
||||
MaxWidth = LibPUAE.PAL_WIDTH,
|
||||
MaxHeight = LibPUAE.PAL_HEIGHT,
|
||||
DefaultFpsNumerator = LibPUAE.PUAE_VIDEO_NUMERATOR_NTSC,
|
||||
DefaultFpsDenominator = LibPUAE.PUAE_VIDEO_DENOMINATOR_NTSC
|
||||
MaxWidth = LibUAE.PAL_WIDTH,
|
||||
MaxHeight = LibUAE.PAL_HEIGHT,
|
||||
DefaultFpsNumerator = LibUAE.UAE_VIDEO_NUMERATOR_NTSC,
|
||||
DefaultFpsDenominator = LibUAE.UAE_VIDEO_DENOMINATOR_NTSC
|
||||
};
|
||||
|
||||
private readonly LibWaterboxCore.EmptyCallback _ledCallback;
|
||||
|
@ -62,12 +62,12 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
}
|
||||
|
||||
[CoreConstructor(VSystemID.Raw.Amiga)]
|
||||
public PUAE(CoreLoadParameters<object, PUAESyncSettings> lp)
|
||||
public UAE(CoreLoadParameters<object, UAESyncSettings> lp)
|
||||
: base(lp.Comm, lp.SyncSettings?.Region is VideoStandard.NTSC ? ConfigNTSC : ConfigPAL)
|
||||
{
|
||||
_roms = lp.Roms;
|
||||
_syncSettings = lp.SyncSettings ?? new();
|
||||
_syncSettings.FloppyDrives = Math.Min(LibPUAE.MAX_FLOPPIES, _syncSettings.FloppyDrives);
|
||||
_syncSettings.FloppyDrives = Math.Min(LibUAE.MAX_FLOPPIES, _syncSettings.FloppyDrives);
|
||||
DeterministicEmulation = lp.DeterministicEmulationRequested || _syncSettings.FloppySpeed is FloppySpeed._100;
|
||||
var filesToRemove = new List<string>();
|
||||
|
||||
|
@ -83,9 +83,9 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
ControllerDefinition = CreateControllerDefinition(_syncSettings);
|
||||
_ledCallback = LEDCallback;
|
||||
|
||||
var puae = PreInit<LibPUAE>(new WaterboxOptions
|
||||
var uae = PreInit<LibUAE>(new WaterboxOptions
|
||||
{
|
||||
Filename = "puae.wbx",
|
||||
Filename = "uae.wbx",
|
||||
SbrkHeapSizeKB = 1024,
|
||||
SealedHeapSizeKB = 512,
|
||||
InvisibleHeapSizeKB = 512,
|
||||
|
@ -122,7 +122,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
Console.WriteLine(string.Join(" ", _args));
|
||||
Console.WriteLine();
|
||||
|
||||
if (!puae.Init(_args.Count, _args.ToArray()))
|
||||
if (!uae.Init(_args.Count, _args.ToArray()))
|
||||
throw new InvalidOperationException("Core rejected the rom!");
|
||||
|
||||
foreach (var f in filesToRemove)
|
||||
|
@ -132,25 +132,25 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
|
||||
PostInit();
|
||||
|
||||
puae.SetLEDCallback(_syncSettings.FloppyDrives > 0 ? _ledCallback : null);
|
||||
uae.SetLEDCallback(_syncSettings.FloppyDrives > 0 ? _ledCallback : null);
|
||||
}
|
||||
|
||||
protected override LibWaterboxCore.FrameInfo FrameAdvancePrep(IController controller, bool render, bool rendersound)
|
||||
{
|
||||
DriveLightOn = false;
|
||||
var fi = new LibPUAE.FrameInfo
|
||||
var fi = new LibUAE.FrameInfo
|
||||
{
|
||||
Port1 = new LibPUAE.ControllerState
|
||||
Port1 = new LibUAE.ControllerState
|
||||
{
|
||||
Type = _ports[0],
|
||||
Buttons = 0
|
||||
},
|
||||
Port2 = new LibPUAE.ControllerState
|
||||
Port2 = new LibUAE.ControllerState
|
||||
{
|
||||
Type = _ports[1],
|
||||
Buttons = 0
|
||||
},
|
||||
Action = LibPUAE.DriveAction.None
|
||||
Action = LibUAE.DriveAction.None
|
||||
};
|
||||
|
||||
for (int port = 1; port <= 2; port++)
|
||||
|
@ -159,7 +159,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
|
||||
switch (_ports[port - 1])
|
||||
{
|
||||
case LibPUAE.ControllerType.Joystick:
|
||||
case LibUAE.ControllerType.Joystick:
|
||||
{
|
||||
foreach (var (name, button) in _joystickMap)
|
||||
{
|
||||
|
@ -170,7 +170,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
}
|
||||
break;
|
||||
}
|
||||
case LibPUAE.ControllerType.CD32_pad:
|
||||
case LibUAE.ControllerType.CD32_pad:
|
||||
{
|
||||
foreach (var (name, button) in _cd32padMap)
|
||||
{
|
||||
|
@ -181,21 +181,21 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
}
|
||||
break;
|
||||
}
|
||||
case LibPUAE.ControllerType.Mouse:
|
||||
case LibUAE.ControllerType.Mouse:
|
||||
{
|
||||
if (controller.IsPressed($"P{port} {Inputs.MouseLeftButton}"))
|
||||
{
|
||||
currentPort.Buttons |= LibPUAE.AllButtons.Button_1;
|
||||
currentPort.Buttons |= LibUAE.AllButtons.Button_1;
|
||||
}
|
||||
|
||||
if (controller.IsPressed($"P{port} {Inputs.MouseRightButton}"))
|
||||
{
|
||||
currentPort.Buttons |= LibPUAE.AllButtons.Button_2;
|
||||
currentPort.Buttons |= LibUAE.AllButtons.Button_2;
|
||||
}
|
||||
|
||||
if (controller.IsPressed($"P{port} {Inputs.MouseMiddleButton}"))
|
||||
{
|
||||
currentPort.Buttons |= LibPUAE.AllButtons.Button_3;
|
||||
currentPort.Buttons |= LibUAE.AllButtons.Button_3;
|
||||
}
|
||||
|
||||
currentPort.MouseX = controller.AxisValue($"P{port} {Inputs.MouseX}");
|
||||
|
@ -209,7 +209,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
{
|
||||
if (!_ejectPressed)
|
||||
{
|
||||
fi.Action = LibPUAE.DriveAction.EjectDisk;
|
||||
fi.Action = LibUAE.DriveAction.EjectDisk;
|
||||
CoreComm.Notify($"Ejected drive FD{_currentDrive}: {_drives[_currentDrive]}", _messageDuration);
|
||||
_drives[_currentDrive] = "empty";
|
||||
}
|
||||
|
@ -218,7 +218,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
{
|
||||
if (!_insertPressed)
|
||||
{
|
||||
fi.Action = LibPUAE.DriveAction.InsertDisk;
|
||||
fi.Action = LibUAE.DriveAction.InsertDisk;
|
||||
unsafe
|
||||
{
|
||||
var str = FileNames.FD + _currentSlot;
|
||||
|
@ -226,7 +226,7 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
{
|
||||
fixed (byte* buffer = fi.Name.Buffer)
|
||||
{
|
||||
Encoding.ASCII.GetBytes(filename, str.Length, buffer, LibPUAE.FILENAME_MAXLENGTH);
|
||||
Encoding.ASCII.GetBytes(filename, str.Length, buffer, LibUAE.FILENAME_MAXLENGTH);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -309,19 +309,19 @@ namespace BizHawk.Emulation.Cores.Computers.Amiga
|
|||
{
|
||||
var ntsc = initial
|
||||
? _syncSettings.Region is VideoStandard.NTSC
|
||||
: BufferHeight == LibPUAE.NTSC_HEIGHT;
|
||||
: BufferHeight == LibUAE.NTSC_HEIGHT;
|
||||
|
||||
if (ntsc)
|
||||
{
|
||||
_correctedWidth = LibPUAE.PAL_WIDTH * 6 / 7;
|
||||
VsyncNumerator = LibPUAE.PUAE_VIDEO_NUMERATOR_NTSC;
|
||||
VsyncDenominator = LibPUAE.PUAE_VIDEO_DENOMINATOR_NTSC;
|
||||
_correctedWidth = LibUAE.PAL_WIDTH * 6 / 7;
|
||||
VsyncNumerator = LibUAE.UAE_VIDEO_NUMERATOR_NTSC;
|
||||
VsyncDenominator = LibUAE.UAE_VIDEO_DENOMINATOR_NTSC;
|
||||
}
|
||||
else
|
||||
{
|
||||
_correctedWidth = LibPUAE.PAL_WIDTH;
|
||||
VsyncNumerator = LibPUAE.PUAE_VIDEO_NUMERATOR_PAL;
|
||||
VsyncDenominator = LibPUAE.PUAE_VIDEO_DENOMINATOR_PAL;
|
||||
_correctedWidth = LibUAE.PAL_WIDTH;
|
||||
VsyncNumerator = LibUAE.UAE_VIDEO_NUMERATOR_PAL;
|
||||
VsyncDenominator = LibUAE.UAE_VIDEO_DENOMINATOR_PAL;
|
||||
}
|
||||
}
|
||||
|
|
@ -46,7 +46,7 @@ namespace BizHawk.Emulation.Cores
|
|||
public const string Octoshock = "Octoshock";
|
||||
public const string PceHawk = "PCEHawk";
|
||||
public const string PicoDrive = "PicoDrive";
|
||||
public const string PUAE = "PUAE";
|
||||
public const string UAE = "UAE";
|
||||
public const string QuickNes = "quickerNES";
|
||||
public const string Sameboy = "SameBoy";
|
||||
public const string Saturnus = "Saturnus";
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
CORE_DIR = libretro-uae
|
||||
TARGET = puae.wbx
|
||||
TARGET = uae.wbx
|
||||
EMU = $(CORE_DIR)/sources/src
|
||||
LIBRETRO = $(CORE_DIR)/libretro
|
||||
DEPS_DIR = $(CORE_DIR)/deps
|
||||
|
|
Loading…
Reference in New Issue