fix linking, rename lib, prep for GB/C
get more consoles working. PCE still not there
fix PCE hucard loading; CD still broken
fix PCE CD loading and firmware. SGB still not quite there
get SGB working
add gitlab recipe for libretro buildbot
Also fixes presets/clear buttons for NTT, Pachinko & Hypershot, and improves layout for all controller config popups (buttons/borders are aligned, etc.)
Modified NesMemoryManager & BaseMapper to allow inlining the read logic when the CPU is e.g executing code from ROM. This speeds up execution by around 5%.
-ProcessCpuClock was used to check for events that don't need to be checked that often (auto-switch disk + auto fast-forward options). This has been moved to an EndFrame callback.
-This was even slower than intended because of the call to _emu->GetFrameCount() which was, relatively speaking, fairly slow. To improve its performance (since it's used rarely for some things like turbo button processing), a separate GetFrameCount function was added on all console classes, and Emulator::GetFrameCount was also optimized to be faster when called from the emulation thread.
When the auto-switch disk option is enabled, this can improve performance by about 25-30%. When the option is not enabled, this still improves performance by 4-5%.
* GB: Link cable support with two local consoles
* GB: Fix crash when color blending is enabled
* GB: Fix formatting
* GB: Link UI fixes, control fixes, audio fixes
Copied from Sour's branch. Also a separate change to use separate savefiles.
* GB: Try to avoid crashes from buffer overflows
* GB: Separate savefiles with linked multiplayer
* GB: Add support for faster link speed
* GB: Move enum to correct file
* GB: Refactor, move serial transfer to function
* -Fixed secondary console sometimes running far ahead of the main console when frame counters did not match (e.g because one console had their LCD disabled longer, etc.) This would cause buffer overflows in the audio buffer.
-Fixed screen tearing when both consoles are not perfectly in sync (because of the LCD being disabled for a different amount of time, etc.)
-Fixed main console not calling PlayQueuedAudio properly mid-frame
-Reuse VS Dualsystem code to merge audio/video when possible/simple and moved that to AvMergeUtilities
Some visual glitches can appear on the secondary screen (for GB) while rewinding, but this can't really be fixed.
* Fixed warning (unused local variable)
* Prevent loading single-console save states when in dual-console modes
* Disable debugger for VS DualSystem's subconsole. Fixes issues when debugging VS DualSystem games
* Code cleanup
* Rework solution to disable debugger on second console to improve performance
Added InternalRunFrame for nes & gb to avoid checking for the presence of the second console after each cpu instruction
* Don't enable the linked GB option by default
* Removed unused function
* Netplay: Force game to reload after updating emulation settings when connecting to the server (or when the host changes game)
This ensures that e.g the GB link cable setting is applied and that the game loads correctly, regardless of the client's link cable settings (otherwise the game could load without the link mode enabled, etc.)
---------
Co-authored-by: Sour <[email protected]>
* SNES: Add Turbo File Twin support
* SNES: Try to make write mode flag more accurate
Hardware tests on Turbo File Twin seem to be showing that if you write data then it stops reporting that the write flag is on, despite letting you write more data
* SNES: Move bit array access to a utility
Also add note about how bit 26 in STF report is not fully verified
* SNES: Add behavior seen when reading without read command
When you turn the strobe on and off outside of a read command, the shift register gets reloaded with the most recently read or written byte
* NES, SNES: Emulator::SaveBattery() for saving console and controller
* Fix range limit in SetBitInArray
* Add notes about unknown aspects of TFII mode
* Add comments to make it clear what's unknown
* STF mode ignores out-of-range addresses
Also allocate _data instead of putting it in the class
* Code: Add auto-formatting rules for C++ projects (clang-format) and enforce code style via "clang-format" and "dotnet format"
* fix ui format warnings
Resetting the emulator would cause the EPSM to not function for a while. This was because the EPSM implementation was not reset-aware. While the console clock it's comparing against would be reset to 0, its own internal clock would not, and so it would have to wait for the console clock to catch back up.
Thanks to Sour for finding the cause and suggesting the fix.
Otherwise, Game Genie codes that could have worked on hardware did not work as expected because of the bus conflicts. This could occur when e.g trying to use cheats on a romhack, etc.
Keep BGs in separate arrays based on their priority to avoid having to scan thousands of background entries for layers that have no backgrounds at all on each frame