Commit Graph

4454 Commits

Author SHA1 Message Date
James Groom b40c405921
Remove useless check from Nymashock ctor
when you load a `.bin`, well in my case it asked me to choose a platform, but once I picked PSX, it continued to synthesise a `.cue` and side-step this check
2024-04-30 22:00:41 +10:00
CasualPokePlayer 296eb8f1a0 fix message 2024-04-30 00:52:00 -07:00
CasualPokePlayer 65a7c89318 make extensions how gpgx wants to see them 2024-04-30 00:49:09 -07:00
CasualPokePlayer 60fb92f685 partially revert previous commit (seems that throwing in this callback causes a stack overflow? wtf? throwing normally works in nyma firmware handling which is in a callback so this is odd)
add proper gg firmware entry
2024-04-30 00:49:09 -07:00
CasualPokePlayer c41dea6683 Cleanup some GPGX stuff, fix system detection for archived roms 2024-04-29 23:23:17 -07:00
CasualPokePlayer 21b6bd331b Add CHD CD support 2024-04-29 22:21:47 -07:00
Sergio Martin 9dcb84336e
Wiring up GPGX as core for SMS, GG, and SG (#3902)
* Adding GPGX as core for SMS and GG
* Enabling SMS FM selection
* Allow selecting PicoDrive as the preferred core for MD/Genesis

---------

Co-authored-by: James Groom <OSSYoshiRulz+GitHub@gmail.com>
Co-authored-by: feos <feykomylce@gmail.com>
2024-04-28 20:10:44 +03:00
James Groom 8a0bf19869
Restore previous GPGX display name
if you're going to fix this, fix the rest at the same time, and use the name verbatim with spaces
2024-04-28 23:54:57 +10:00
James Groom 653844e692
Add workaround for a Mono bug 2024-04-27 18:50:59 +00:00
CasualPokePlayer 127209f3a2 Fix wrong track mode being given to gpgx 2024-04-27 06:15:49 -07:00
James Groom df0ae2c2d0
Leave some comments in `LuaConsole.InputBox_KeyDown` 2024-04-27 12:15:10 +00:00
James Groom 6ed83ed7a0
Improve UX for long-running commands in the Lua REPL 2024-04-27 12:13:28 +00:00
CasualPokePlayer d4c4ef8f17 C# fixes for gpgx 2024-04-27 03:12:25 -07:00
CasualPokePlayer 06ceec6390 Fixup nyma flatbuffer comms, update flatbuffer 2024-04-27 02:52:14 -07:00
CasualPokePlayer 811555d594 fix gpgx invisible heap size
kb is not bytes
2024-04-26 16:26:00 -07:00
CasualPokePlayer fb438863f5 Fix crash when saving CD ebram 2024-04-26 16:18:34 -07:00
CasualPokePlayer 80f209ed0d Remove CD caching code
It was a sort of novel speed boost idea, but it doesn't work too well due to wbx heap limitations and the drive light still needing a callback anyways
2024-04-26 15:41:33 -07:00
CasualPokePlayer 979258f2cf Fix calculation for disc buffer size needed 2024-04-26 14:41:22 -07:00
CasualPokePlayer 55fbf68c8a Better calculation for disc buffer space needed 2024-04-26 13:53:28 -07:00
CasualPokePlayer f1dec3dd07 C# changes for fixing GPGX drive light 2024-04-26 13:51:36 -07:00
CasualPokePlayer 5326d76ec5 Fix GPGX CD buffer allocation 2024-04-26 12:55:21 -07:00
CasualPokePlayer b91f328436 More C# changes for GPGX adjustments 2024-04-26 12:47:17 -07:00
CasualPokePlayer 9e2d239a02 Adjust C# parts for GPGX changes 2024-04-26 12:12:14 -07:00
CasualPokePlayer 3c168ed64c Fix crashes when a branch is saved/loaded while the main window is minimized
primarily occurs with the case of a lua script and the user decides to minimize the main window
2024-04-25 14:14:06 -07:00
James Groom 24d2794554
Fix typo in doc comment
fixes df36aaaa1
2024-04-25 14:14:04 +10:00
James Groom df36aaaa1c
Add docs to the config props which control host audio volume 2024-04-25 04:09:39 +00:00
Sergio Martin 5cb1fe0042
Update Genesis Plus GX Core (#3889)
* Added deep freeze functionality
* Adding support for selecting sound chip
* Adding LUA interface to the deepfreeze list
* Implemented sprite always on top in the VDP
* Found and fixed the issue that manifested itself in a reset Gargoyles and an outright fail in Ristar. The issue was the use of a union type containing overlapping cd and cartdrige data. Using struct now to keep them separated
* Fix PC reg in tracelogs
---------
Co-authored-by: feos <feykomylce@gmail.com>
Co-authored-by: CasualPokePlayer <50538166+CasualPokePlayer@users.noreply.github.com>
2024-04-21 18:34:54 +03:00
Morilli e06369bed8 Fix inverted timestamp condition in branch id check
fixes 05abb3adfa
2024-04-20 12:46:28 +02:00
James Groom 1ff7d54511
Make Lua `onqueryitemtext` more resilient (resolves #3897) 2024-04-19 00:03:30 +10:00
James Groom 45e2307a7b
Reword a label for clarity in the bundler 2024-04-17 14:59:27 +10:00
James Groom 8f963ba58c
Improve error dialog when `DiscMountJob` fails 2024-04-15 13:10:24 +10:00
James Groom c35aeb992f
Don't start with `CompileCueJob` if the `ParseCueJob` had an error 2024-04-15 13:01:04 +10:00
CasualPokePlayer fe8a119eaf update mGBA 2024-04-12 19:38:54 -07:00
James Groom d415bf4ca0
Fix typo
fixes 7d951c6a3
2024-04-06 03:42:21 +10:00
James Groom 7d951c6a3d
Fix `FileNotFoundException` thrown from quickslot preview
fixes 1db54108a
2024-04-06 03:41:12 +10:00
James Groom 1db54108ac
Wire up `ScreenshotForm` for the quickslot buttons in the status bar 2024-04-05 00:14:21 +00:00
James Groom 20ff7a10ba
Merge `ScreenshotForm` to custom controls dir 2024-04-04 23:59:17 +00:00
James Groom 58f810a0e1
Merge `ScreenshotForm` into one file and fix doc comment 2024-04-04 23:56:43 +00:00
James Groom 73c3056bd6
Shuffle logic between `ScreenshotForm.UpdateValues` and call-site 2024-04-04 23:51:09 +00:00
James Groom 3cb7847b35
Improve memoisation in `ScreenshotForm` 2024-04-04 23:39:17 +00:00
feos 18f8f3faa2 mame: mnemonics for Robotron 2084 2024-04-04 18:12:16 +03:00
James Groom dd9e4178d6
Use MSBuild to create empty dirs in output 2024-04-04 00:17:32 +00:00
James Groom b427e7c417
Fix generation of API reference `.xml` files 2024-04-04 00:16:11 +00:00
James Groom d0594c2224
Fix post-build file shuffling again
fixes b654d4a2a
2024-04-04 00:14:44 +00:00
James Groom 82d80bf4bf
Embed debug info for main solution only
fixes 0e892a5f1
2024-04-03 23:32:29 +00:00
Morilli b654d4a2ac Fix and simplify PostBuild file moving 2024-04-03 22:57:45 +02:00
Morilli 41e7c04678 Don't set output path for non-exe projects
surely this is safe and fine and all
2024-04-03 22:38:43 +02:00
James Groom 2206571ab8
Hide asms from ext. tool list if they don't reference any Hawk asms 2024-03-30 07:15:31 +10:00
James Groom a3faf6fbd7
Skip generating ext. tool menu items for files that aren't assemblies 2024-03-30 07:12:24 +10:00
James Groom 7e8623fdda
Retain `BizHawk.Client.` prefix in executables' assembly names 2024-03-30 07:07:21 +10:00
Morilli 6d06dcd5d2 Fix BinarySearch test failures 2024-03-29 18:56:56 +01:00
Morilli af9d337900 Add one more failing test 2024-03-29 18:56:38 +01:00
Morilli b983bdb361 Add failing binary search tests
Fixing these functions is left as an exercise to the reader
2024-03-29 13:08:52 +01:00
CasualPokePlayer be6647f10c [MAME] Fix System Bus causing desyncs 2024-03-28 17:58:34 -07:00
James Groom d67b1c1d23
Fix typo
fixes 4f144c74d
2024-03-27 17:19:16 +00:00
James Groom 4f144c74d4
Create constructors for `RollColumn` 2024-03-27 17:17:53 +00:00
James Groom 8967f58df8
Move `&&`/`||` to start of next line in main solution 2024-03-27 16:35:31 +00:00
James Groom b0ba7a1246
Move `&&`/`||` to start of next line in EmuHawk project 2024-03-27 16:10:32 +00:00
James Groom 8987ba8650
Remove unused import
fixes cf45d41c8
2024-03-27 02:24:29 +00:00
James Groom 651c79abeb
Fix typos from `&&`/`||` refactoring
fixes 5685befe1
2024-03-27 02:21:50 +00:00
James Groom 5685befe14
Move `&&`/`||` to start of next line in Emulation.Cores project 2024-03-27 02:10:39 +00:00
Morilli e5582cd016 Use UtcNow instead of Now 2024-03-26 22:28:18 +01:00
Morilli 95381170d8 Add optimization for >>1k fps scenarios 2024-03-26 20:14:54 +01:00
Morilli cf45d41c85 Don't unnecessarily create and return a Dictionary from GetAxisValues 2024-03-26 19:23:50 +01:00
Morilli 032d1b85d6 -1 list allocation per frame yay 2024-03-26 19:20:54 +01:00
Morilli d498f8c3be Simplify logic in OverrideAdapter 2024-03-26 19:10:22 +01:00
Morilli 45159091e6 Optimize IsLoaded<T>
can we get rid of the other 3 functions maybe?
2024-03-26 18:32:32 +01:00
James Groom 3c2b01f34b
Replace some spaces used as indentation 2024-03-26 16:52:47 +00:00
James Groom 7b5f688590
Fix double enumeration in `InputRoll.SelectRow` 2024-03-26 01:11:07 +10:00
James Groom 85caed48cc
Fix movie importer crashing on files with unrecognised extentions 2024-03-22 17:00:43 +00:00
Sergio Martin 9c4a818423
Replace QuickNES core with QuickerNES (squashed PR #3839)
resolves #3848
2024-03-23 01:31:22 +10:00
James Groom 0857dd6771
Clean up equality implementation for `Cell` 2024-03-20 22:19:57 +00:00
James Groom 01ed94d167
Replace mutation w/ pre-init check for N64 C button column header hack
also fixes width not being recalculated
fixes fde16fa5a
2024-03-20 19:51:41 +00:00
James Groom 41cae2dd22
Remove unused props from `RollColumn` and `RollColumns` 2024-03-20 19:46:56 +00:00
James Groom c5a478a28a
Remove unused prop `Cell.CurrentText` 2024-03-20 19:34:45 +00:00
James Groom bbe7040554
Remove temporary no-crash-plz shims 2024-03-20 19:33:46 +00:00
James Groom a3aa67681f
Clean up debug serialisation of `Cell`
fixes 2a67cf93e
2024-03-20 19:31:34 +00:00
YoshiRulz 57439f9697 Reduce LINQ calls on `CellList` 2024-03-20 11:24:13 +00:00
James Groom 0f9f6f0e53 Drop import 2024-03-20 11:24:13 +00:00
Morilli ca0fb69570 Optimize operations with selected items 2024-03-20 11:24:13 +00:00
James Groom 2a67cf93ec Replace `SortedSet` with `SortedList<T>` in `InputRoll`
see 6d40c08c3
2024-03-20 11:24:13 +00:00
SkiHatDuckie 328d36d0ca
Refactor window scale menu, add 6x through 9x (squashed PR #3872)
resolves #3826
2024-03-20 09:48:15 +10:00
adelikat b6efbfe54b add hotkey to toggle the last used lua script 2024-03-19 11:10:15 -05:00
Morilli bfae8d0f1e reduce allocations in CalculatePointedCell 2024-03-16 13:26:53 +01:00
Morilli cad3699221 Don't triple-allocate in FrameToStringPadded 2024-03-15 18:31:46 +01:00
James Groom 2f6a507fdf
Simplify some logic in `InputRoll.{SelectCell,OnMouseDown}` 2024-03-15 12:10:20 +00:00
James Groom 967ce66e9e
Use helper prop in `InputRoll`, simplifying LINQ call 2024-03-15 12:01:58 +00:00
Morilli 0cbc65ba4e Improve Cell comparison 2024-03-14 21:59:25 +01:00
James Groom 86a4aa69ee
Fix double enumeration in `InputRoll.SelectRow` 2024-03-15 06:02:29 +10:00
James Groom ce6d032051
Fix logic in `Bk2Controller.SetFromMnemonic`
fixes fdf63900b
2024-03-14 04:15:56 +10:00
James Groom 8d892346d2
Fix crash when loading `.wch` into RAM Search 2024-03-13 23:42:25 +10:00
James Groom 0f8995eec7
Clean up conditionals in `TAStudio.TasView_QueryItemIcon`
fixes 17ed62b39
2024-03-12 15:35:44 +10:00
James Groom e55c6c2688
Avoid delegate wrapper in `ICollection.RemoveAll` extension hot path
see 6d40c08c3
2024-03-12 15:24:41 +10:00
James Groom 24bd99eb07
Refactor `HotkeyInfo.ResolveWithDefaults` 2024-03-12 15:22:07 +10:00
Morilli fdf63900b6 Reduce string allocations in SetFromMnemonic 2024-03-12 02:17:59 +01:00
Morilli 17ed62b39e Prevent unnecessary TasMovieRecord queries 2024-03-12 01:41:22 +01:00
Morilli 9a2de650d1 Reduce Cell allocation spam
Don't really like this change but it does help allocation count a lot. Perhaps Cell should just be a struct?
2024-03-12 00:04:29 +01:00
Morilli 6d40c08c3c fix #3675
This looks to just be better on .net framework...
2024-03-11 22:43:57 +01:00
CasualPokePlayer 5bf9d387b4 prevent various apis from being used while in an input/memory callback 2024-03-10 23:18:55 -07:00
CasualPokePlayer 38ef6028d7 correct buffer check condition 2024-03-10 15:25:01 -07:00
CasualPokePlayer 04fe0d7d04 fix crash with SDLResampler 2024-03-10 15:10:17 -07:00
CasualPokePlayer 03fa3fc19d get rid of this Flush call
isn't really needed
2024-03-10 15:03:33 -07:00
CasualPokePlayer d9a93c474a throw out the speex resampler, place in SDL's resampler to replace it
no more 2010 vc++ runtime requirement
2024-03-10 15:02:25 -07:00
Morilli 05abb3adfa Optimize IndexOfFrame function in TAStudio 2024-03-10 19:21:05 +01:00
Morilli 87197e0524 Optimize IsMarker checks in TAStudio 2024-03-10 18:57:08 +01:00
CasualPokePlayer d547ff3d57 update comment due to prev commit 2024-03-10 03:40:18 -07:00
CasualPokePlayer c85aee928f remove DInput dependency with RawKeyInput 2024-03-09 22:01:44 -08:00
CasualPokePlayer 90369fce13 encore: add lag detection 2024-03-08 20:25:25 -08:00
CasualPokePlayer 59176ca2d3 encore: fix aes_keys.txt / seeddb.bin not being properly picked up by the core 2024-03-08 19:12:54 -08:00
CasualPokePlayer 6dd0bb25e8 encore: remove async file io completely, fix savestate crashes due to AsyncWakeUpCallback serialization attempts 2024-03-08 17:29:40 -08:00
James Groom 69d29c39f5
Fix cheat editor resetting display type when changing size
and when choice is no longer valid, default to hex instead of unsigned
2024-03-08 21:42:20 +10:00
James Groom 2f758459dd
Add docs and unit tests for `IList.LowerBoundBinarySearch` extension
without d29da10e9, the final case in this test method would throw an exception
2024-03-08 11:22:44 +00:00
James Groom 49fa40f562
Rename newly-added `.props` file, improve MSTest output
fixes 6df491c9d
2024-03-08 10:50:57 +00:00
James Groom 5a6fcce981
Use new way of importing MSTest framework 2024-03-08 10:42:37 +00:00
James Groom 9e12480c3e
Bump MSTest and Magick.NET 2024-03-08 10:38:08 +00:00
James Groom 6df491c9d9
Dedup test project files and also mute style warnings in GambatteSuite 2024-03-08 10:33:53 +00:00
James Groom 8630ccdd41
Update list of known testrom failures from Gambatte suite 2024-03-08 10:30:12 +00:00
CasualPokePlayer d9cd9f4810 do various determinism fixes for encore 2024-03-07 22:31:16 -08:00
James Groom 729ca96517
Hopefully fix double BOM
thanks VS Code
2024-03-08 03:50:05 +00:00
James Groom 615c2eaf88 Leave comment in `FindIOSurfaceInfo`
fixes 7ee0e0afa
2024-03-08 13:42:47 +10:00
Morilli 7ee0e0afac Reduce allocations in FindIOSurfaceInfo 2024-03-08 02:22:56 +01:00
Morilli d29da10e91 Fix LowerBoundBinarySearch, fix lag check 2024-03-08 02:22:31 +01:00
Morilli b8e49413cf Remove unnecessary TasMovieRecord allocations 2024-03-07 23:52:18 +01:00
Morilli 674997b345 Optimize speed and allocations of TasMovieMarker.Previous[OrCurrent]
was quite a ridiculous amount of allocations due the amount of calls to this functions
2024-03-07 22:53:39 +01:00
James Groom 592eb34370
Update lists of known testrom failures (except Gambatte suite) 2024-03-07 06:55:43 +00:00
James Groom 1f70320ea8
Get testroms projects building again
fixes 8ae947fed, e87536ea8, e7f4ad822, 59fcdb04c, 72cc19266, d788e603f, and 86684b689
2024-03-07 06:54:16 +00:00
CasualPokePlayer 7c4f997f88 encore: add in some new settings, expose some other settings, rework upscaling management (more in line with how melonds is handled) 2024-03-06 21:08:57 -08:00
James Groom 07d1c41712
Fix typo
fixes 8c3f857ab
2024-03-06 17:39:38 +10:00
James Groom 8c3f857ab6
Fix cheat editor showing "0x" prefix when not hex type 2024-03-06 16:30:14 +10:00
CasualPokePlayer 5a55f04f1e -headless isn't a postfix for encore 2024-03-05 18:28:12 -08:00
CasualPokePlayer 1bbc54f29f add back encore submodule + build script + add windows build + a few more renamings 2024-03-05 16:13:51 -08:00
CasualPokePlayer 7cf8c968df rename all the things 2024-03-04 18:39:30 -08:00
CasualPokePlayer f02080b61b fix build 2024-03-04 17:13:51 -08:00
CasualPokePlayer 5304467855 update to nightly-2104 2024-03-04 17:06:40 -08:00
James Groom 3f58dba4f5
Use title case for this menu item 2024-02-25 06:42:51 +10:00
James Groom 4df850973f
Document invariant
see df4aa7974
2024-02-24 05:15:31 +10:00
Morilli df4aa7974b Optimize InputDisplayGenerator.Generate 2024-02-22 19:27:38 +01:00
YoshiRulz d31047ffc3 Use NuGet central package management 2024-02-14 16:24:31 +00:00
James Groom daf9ea7bb2
Check for FFmpeg when using DiscoHawk's bottom box
no download option for now
2024-02-14 16:23:11 +00:00
James Groom 3f2f9cc170
Copy error dialog code from DiscoHawk's top box to its bottom box 2024-02-14 16:21:34 +00:00
feos 54ef35d2e0 black text on white BG is how input roll is meant to look
if we ever support swapping the colors for a dark theme, bd3f919129 could be a useful refactor, but only allowing linux users to see input roll properly was wrong (because setting BG to Control color makes it look disabled)
2024-02-13 01:11:50 +03:00
CasualPokePlayer b34e713f1c update sqlite stuff, also swap it with Microsoft.Data.Sqlite.Core / SQLitePCLRaw.provider.e_sqlite3 and do a different hack to avoid pulling in native deps 2024-02-12 13:59:16 -08:00
James Groom 131bc65e8f
Bump .NET SDK to 8.x 2024-02-12 20:38:03 +00:00
CasualPokePlayer 17434f78cf init rtc before calling nyma init functions
mainly needed for saturnus
2024-02-09 18:37:34 -08:00
CasualPokePlayer 5fb7b486b3 dumb rcheevos saturn memory fix
yeah this is dumb
2024-02-08 23:48:53 -08:00
CasualPokePlayer 2c521fdc5a add ISaveRam explicitly
this is needed for new saveram interface to be picked up apparently
fixes 446fac3242
2024-02-08 23:36:12 -08:00
CasualPokePlayer 446fac3242 add in c# side code to actually use new saturnus saveram interface 2024-02-08 23:32:14 -08:00
CasualPokePlayer 5d54c09577 update saturn entries in firmware db
mainly don't consider other region bios files as "acceptable", mednafen policy is to reject the wrong region (see ss.bios_sanity handling)
2024-02-07 06:17:54 -08:00
James Groom 33f0b5ca32
Remove imports no longer used after recent changes 2024-02-06 11:10:05 +00:00
James Groom 33a71cf0e1
Replace `null` array w/ empty in `NESSyncSettings.OkBtn_Click` (fixes #3858)
fixes 103fb3832
2024-02-06 09:03:16 +10:00
James Groom 103fb38322
Clean up `NESSyncSettings.OkBtn_Click` (resolves #3856) 2024-02-01 15:11:52 +00:00
James Groom 484e1fee78
Clean up `NESSyncSettings.InitialWRamStatePattern` 2024-02-01 15:10:02 +00:00
James Groom 7e8950ea52
Clean up `BytesToHexString` 2024-02-01 15:04:36 +00:00
James Groom f3aae71da6
Expose PALRAM domain from NesHawk (resolves #3854) 2024-01-31 09:31:22 +00:00
CasualPokePlayer 2f11560b14 fix alternative keyboard layout handling for extended scancodes 2024-01-26 07:01:22 -08:00
James Groom acf368e67f
Rewrite Game Genie (GB) decoder 2024-01-21 15:01:20 +00:00
James Groom 2f9119834b
Add test cases for Game Genie (GB) decoder 2024-01-21 14:49:22 +00:00
James Groom 21706d8421
Fix typo
fixes f6a9dee46
2024-01-18 14:55:51 +10:00
James Groom f6a9dee467
Prevent an IooRE in *Action 52*
see https://github.com/TASEmulators/BizHawk/issues/2999#issuecomment-1895239013
2024-01-17 17:35:25 +10:00
CasualPokePlayer 62afd3c747 add missing member to this struct 2024-01-16 22:04:30 -08:00
CasualPokePlayer 1b7fe8e7fd misc cheevo stuff 2024-01-16 20:16:25 -08:00
CasualPokePlayer d03d076fa7 several rcheevo updates, mostly for 3DS stuff 2024-01-16 20:00:45 -08:00
CasualPokePlayer 67b535d0f8 remove dsi skip fw restriction c# side 2024-01-16 11:08:40 -08:00
CasualPokePlayer 8be0111e72 fix build 2023-12-31 18:02:49 -08:00
CasualPokePlayer d6fdf503b9 /s/RIM_KEY/RI_KEY
seems to be a dumb typo (docs have RI_KEY_* not RIM_KEY_*)
2023-12-31 06:00:48 -08:00
CasualPokePlayer 6330a703a1 fix Pause key not working with RAWINPUT 2023-12-31 05:44:50 -08:00
CasualPokePlayer 79d6bee75f this can be null 2023-12-30 16:40:25 -08:00
CasualPokePlayer f94bcb64b1 add back hawk sound when opening About box 2023-12-30 16:37:37 -08:00
CasualPokePlayer 51925e7cc9 make SDL2WavStream consume a generic Stream rather than passing in a file path
this now should make it functionally the same as a System.Media.SoundPlayer, letting us only doing disk access one time per wav file (and allows some embbed wav to be played)
2023-12-30 16:03:21 -08:00
CasualPokePlayer a38e854a6d add method to play wav files via ISoundOutput, use this instead of System.Media.SoundPlayer 2023-12-30 04:49:26 -08:00
CasualPokePlayer 94f6616e74 fix #1862, also rename front facing setting ("non-vi" makes no sense here) 2023-12-25 00:46:13 -08:00
CasualPokePlayer bc432de43a fix 7ceb6345e4
somehow mixed up files and put the wrong tmd in lol
2023-12-24 23:46:20 -08:00
CasualPokePlayer 7ceb6345e4 add missing TMD for USA California Super Sports, also remove unneeded data in TMDs 2023-12-24 19:05:20 -08:00
CasualPokePlayer ded668fe5a add PolySharp as explicit dep, do some BizHawk.Common .NET6 cleanups
PolySharp was already an implicit dep due to some transitive dep from Vortice. This causes some problems in the test project, although it seems it's specific to the test project setup / one of the test project deps exposing internal classes rather than actually the fault of PolySharp (enabling PolySharpExcludeTypeForwardedToDeclarations works around it)
PolySharp provides source generated internal IsExternalInit/Range/Index, allowing us to use init props and range/index operators, and since it's source generated and internal to each project, it should play nice with potential multi-targetting (keeping in mind the test project is an edge case that doesn't apply in general)
2023-12-22 14:26:24 -08:00
James Groom 3fb30a2ca7
Clean up some `AskSaveChanges` implementations 2023-12-22 04:48:49 +00:00
James Groom bd3f919129
Don't hardcode colours in InputRoll 2023-12-22 04:16:01 +00:00
James Groom cae739a826
Clean up peeking for Hex Editor's N64 Matrix view 2023-12-22 01:17:02 +10:00
James Groom 0d5b0ac964
Fix typos from copy-pasting via human
fixes 6f39bed3f
2023-12-22 01:11:39 +10:00
James Groom 6f39bed3f8
UI+UX improvements for Hex Editor's N64 Matrix view
no idea what this is actually for but now it's usable
2023-12-22 01:04:57 +10:00
James Groom e1571189c5
Mute NU1702 harder 2023-12-21 13:36:13 +10:00
James Groom ea00f3be54
Use helper method
fixes 73bb9b4bd
this is the only code style warning atm
2023-12-21 13:35:23 +10:00
CasualPokePlayer d00a512026 add comment noting StopSound can't be used for directsound's ResetToDefaultDevice 2023-12-18 02:37:30 -08:00
CasualPokePlayer f4ac17c904 Replace OpenAL dlls with openal-soft provided ones (downloaded from their official site: https://www.openal-soft.org/)
Fix hanging issue with OpenAL on device disconnection
Cleanup other hanging/crash fixes in other audio backends
2023-12-18 02:32:37 -08:00
CasualPokePlayer ad3aa2f5dc fix weird double utf8 bom in Bk2LogEntryGenerator 2023-12-17 04:27:17 -08:00
CasualPokePlayer f4ef12a38b simplify xaudio2 critical error handling
don't need to be this fancy, also this can still potentially deadlock anyways since audio throttle isn't going to be message pumping in throttling code
2023-12-17 04:24:19 -08:00
CasualPokePlayer d5fc092c0a Fix disconnecting an audio device potentially crashing/hanging for DirectSound and XAudio2
OpenAL seems to only do this on Windows, Linux does not care. This issue is also only relevant for audio throttle wrt XAudio2/OpenAL.
2023-12-17 04:11:27 -08:00
James Groom 7f21cbd029
Fix syntax errors in interp. string
fixes 0e084eaef
2023-12-17 20:00:30 +10:00
James Groom 0e084eaefd
Elaborate on admin warning, now with manual override (resolves #3835) 2023-12-17 09:46:44 +00:00
feos 4f522bac11 mame: put soft reset first so its dups could be resolved automatically
should complete #3704
2023-12-13 20:57:43 +03:00
James Groom 8a806c897d
Improve error message in `Bk2LogEntryGenerator` ctor (see #3704) 2023-12-13 07:50:16 +10:00
CasualPokePlayer 3bcc6ee977 do some more cleanup with rcheevos stuff, also rework rcheevos read map. having a dict full of delegates ends up allocating >26GiB of memory for New 3DS (i.e. 256MiB of memory), so instead have a map of _memFunction indexes corresponding to address, thereby making memory usage equal to the memory mapping size (so for New 3DS this will only take 256MiB of memory). it comes with some limitations, none of which matter for now 2023-12-11 03:59:10 -08:00
CasualPokePlayer 6b0b6f2106 do cleanup with rcheevos, using record structs where possible
also add in `in` support for the BizInvoker for compat interop
(non-compat interop doesn't really matter here, the point of `in` is to avoid a copy back for non-blittable objects, which doesn't apply for non-compat which only works for blittable objects / always just pins them down)
2023-12-10 16:02:07 -08:00
Morilli 83e784ecec Actually provide proper OAM memory domain in bsnes 2023-12-10 00:48:50 +01:00
CasualPokePlayer cc0b6c0d99 update rcheevos to latest release, change a ton of ints to uints (what's actually used often)
todo: trim out unneeded defs and do c# 10 cleanups
2023-12-09 02:25:40 -08:00
CasualPokePlayer 4d6bc5a33a fix build 2023-12-06 23:23:16 -08:00
CasualPokePlayer 2019f4baf2 c# side for 7b4bd8cdc3 2023-12-06 23:22:17 -08:00
feos 688fb249f9 fix #3715 2023-12-03 15:50:49 +03:00
feos 79baa45ca6 bounds have proper dimensions now 2023-12-03 11:48:49 +03:00
feos 0efdd02085 address #3715 (need to fix hawk side aspect ratio) 2023-12-03 03:12:58 +03:00
feos 73bb9b4bd9 mame: add driver src file to dump info 2023-12-02 22:35:05 +03:00
feos 2a40b172e1 fix #3704 2023-12-02 20:53:37 +03:00
feos a3746fe7b7 fix #3721 2023-12-02 18:06:43 +03:00
CasualPokePlayer 5f6243bd76 Remove SDL_INIT_HAPTIC use
We don't actually use the haptic API, which is a separate thing from SDL_GameControllerRumble/SDL_JoystickRumble
2023-11-23 23:09:46 -08:00
James Groom 2105871122
Clean up handling of modal dialogs and parenting in RA 2023-11-23 07:56:45 +00:00
James Groom 36df9c387b
Add `IDialogParent.AddOnScreenMessage` extension 2023-11-23 07:45:40 +00:00
James Groom 5ef398c309
Lazily init `BasicApiProvider`/`ApiContainer` 2023-11-23 06:47:36 +00:00
James Groom 525c9c2f9c
Use `MainForm.QuicksaveLoad` directly for RA 2023-11-23 06:34:29 +00:00
James Groom 40b17b59c4
Move events from `EmuClientApi` to `MainForm`
the `event` members remain, but the triggering is now delegated back to `MainForm`, and the additional processing has been moved there too
2023-11-22 12:25:44 +00:00
James Groom ca5dc1a6e8
Extract disc hashing from Octoshock, clean it up, and add to Nymashock 2023-11-21 06:54:11 +00:00
CasualPokePlayer 859ea8e249 improve Program startup, remove the OSTailoredCode duplication hack, use RuntimeInformation.IsOSPlatform for figuring out OS, use AppContext.BaseDirectory to get exe location (apparently even works with bundled assemblies in .net5+) 2023-11-18 20:00:16 -08:00
feos c7d65eb0ca mame: add defender mnemonics 2023-11-18 12:52:46 +03:00
James Groom 000f741994
Respect `BIZHAWK_HOME` for e.g. loading Waterbox cores
pretty much only affects NixHawk, where the wbox cores are in one dir and EmuHawk.exe and the other assemblies are in another, and all are symlinked into one tree
2023-11-18 17:26:49 +10:00
CasualPokePlayer ba24907d9c Improve NLua lua library loading, using C# function pointers. It now no longer depends on BizHawk.BizInvoke/BizHawk.Common. It might be faster too
Add in liblua-* variant for Linux lua library names (resolves #3678)
Remove some more unused NLua code
Make LuaState internal, we don't need to see it (NLua.Lua API slightly changed to accommodate this, tests could be broken due to this?)
Make various other NLua classes internal, we don't need to see them
Check against lua library loading failing, provide a non-fatal message box if it has failed instead of crashing on some exception.
Remove UnixSearchPaths (unneeded with LD_LIBRARY_PATH being set) and unused IImportResolvers
2023-11-17 19:03:03 -08:00
James Groom 1956302a15
Use IRODictionary in `BkmMnemonicConstants` 2023-11-18 04:52:09 +10:00
James Groom a9bfd96027
Backport `IEnumerable<KeyValuePair<,>>.ToDictionary` 2023-11-18 04:26:28 +10:00
James Groom c2ddc40468
Clean up impl. of `LinkedDebuggable`
see ed5a708f9
2023-11-18 04:11:02 +10:00
James Groom a227e7d113
Fix typos
fixes b36f4aa4e and ed5a708f9
2023-11-18 03:44:36 +10:00
James Groom ed5a708f93
Clean up `IDebuggable` impl. for GBHawkLink{,3x,4x} 2023-11-18 03:37:17 +10:00
James Groom b36f4aa4ef
Remove unused imports 2023-11-18 03:30:27 +10:00
James Groom 024739d22e
Fix typo in `GBHawkLink4x.SetCpuRegister`
broken since introduction in a751aab74
2023-11-18 03:20:50 +10:00
James Groom 63127695d4
Expose `IInputApi.GetPressedAxes` to Lua, improve `input` lib docs 2023-11-17 13:27:53 +10:00
James Groom 8eef419c62
Rename "Max" window size menu item to "10x" to reflect behaviour 2023-11-17 12:36:51 +10:00
James Groom e53f30f105
Fix "Max" window size menu item never being unchecked 2023-11-17 12:35:50 +10:00
CasualPokePlayer 7edba4962c fix 70bd081a93 (again)
see a2185d9ef0 and 8a5921182e
2023-11-16 09:14:25 -08:00
CasualPokePlayer 582446651f fix all the analyser warnings in NLua 2023-11-16 03:14:47 -08:00
CasualPokePlayer 49807254f6 remove ComImport usage for Win32ShellContextMenu, also /s/ShlobjImports/Shell32Imports 2023-11-15 18:58:06 -08:00
CasualPokePlayer 4660e4d25b Slightly improve ShellLink com interop, resolve todo (seems to work perfectly fine) 2023-11-15 13:29:09 -08:00
CasualPokePlayer 3bc44d6756 Remove SHGetMalloc usage, use Marshal.FreeCoTaskMem instead
Marshal.FreeCoTaskMem can be used instead (assuming we're >= Win2000), see https://learn.microsoft.com/en-us/windows/win32/api/shlobj_core/nf-shlobj_core-shgetmalloc
Also fix pszDisplayName allocation (needs * sizeof(char) due to unicode funny)
2023-11-15 12:55:40 -08:00
CasualPokePlayer 956af3577e Change a lot of CharSet.Auto's to CharSet.Unicode, explicitly put W postfix on relevant winapi functions/structs, put ExactSpelling = true for winapi functions.
We don't care for ANSI functions (no way somebody is going to run BizHawk on Windows 98/ME), and ExactSpelling = false (default) has a minor runtime cost, so this should be slightly more performant.
Also, replace ShellLink COM usage with custom COM interaction code. See https://github.com/TASEmulators/BizHawk/issues/3767. The same is yet to be done for the two other COM usages.
2023-11-15 11:33:50 -08:00
James Groom 391190b6d4
Inline `ICoreFileProvider.DllPath` 2023-11-14 18:05:32 +10:00
CasualPokePlayer edf5f15134 slightly improve xlib bindings, should now in theory work for 32 bit systems 2023-11-11 11:16:52 -08:00
CasualPokePlayer f9c85172e4 try to fix issues where reloading Citra when recording a movie results a crash due to the temp user folder having active file handles
unloading the dll would forcefully evict these file handles. unknown whether Linux does the same with the .so, perhaps it does, perhaps it doesn't. not really any extra harm if it doesn't
2023-11-11 09:11:17 -08:00
James Groom e9468cb0c8
Check FWIDs in database at runtime
see e119bdda3
2023-11-09 08:51:29 +10:00
CasualPokePlayer 282417c9af pass DateTimeFormatInfo.CurrentInfo here instead of suppressing the warning
fixes 5ae15c8
2023-11-08 11:58:38 -08:00
CasualPokePlayer 5ae15c89c3 remove invariant culture here
fixes 6e20a3091c
2023-11-08 10:32:37 -08:00
CasualPokePlayer e119bdda39 fix up firmware entries which had spaces in the id 2023-11-08 10:26:01 -08:00
CasualPokePlayer 5095f0c999 force real bios use when gba cart is present for melonds
melonds' freebios doesn't work with gba cart usage
2023-11-08 08:27:42 -08:00
CasualPokePlayer 6a80336787 add some more ds fw hashes 2023-11-06 09:46:34 -08:00
CasualPokePlayer eeb824d035 add in Chinese / Korean language options, remove unneeded firmware checks 2023-11-04 05:33:14 -07:00
Morilli 7d4b21f9c7 Fix some analyzer warnings
also improve globalconfig readability
2023-11-03 11:56:23 +01:00
CasualPokePlayer cdf89f4b09 add in missing asms in SubMain asm ver check 2023-11-03 03:52:32 -07:00
CasualPokePlayer b1f16cf437 fix ordinal loading (im pretty sure what was being done before only actually worked for dllimport and not getprocaddress)
cleanup some more win32 imports (new LoaderApiImports, although it isn't used for OSTailoredCode to avoid hard dep on BizHawk.Common, probably want to use same hack on LoaderApiImports)
2023-11-02 22:48:12 -07:00
CasualPokePlayer 195846f2f3 cleanup c# side melon code 2023-11-02 13:55:12 -07:00
CasualPokePlayer 7e91e1b260 fix dsi firmware checking 2023-11-02 10:16:30 -07:00
CasualPokePlayer 1ca7b0295d c# changes for melonDS update 2023-11-02 10:12:56 -07:00
Moritz Bender e1fb97dee6
Update snes9x to 1.62.3 (#3729)
* Update snes9x to 1.62.3

* Update snes9x submodule

* Implement msu1 for snes9x

* do less bullshit initialization

* Update snes9x submodule
2023-11-02 18:48:54 +03:00
Morilli abc5ddcc6e Fix lua console null output logging
- closes #3810
- fixes bb7f933429
2023-11-02 13:56:20 +01:00
CasualPokePlayer ebaafe2658 error check against gl context being failed to be set to current
in practice this should only throw when someone has a broken driver
2023-11-01 08:03:17 -07:00
CasualPokePlayer 151908104e Revert 683aa263a0 2023-10-28 22:50:05 -07:00
James Groom aaf46cc9a7
Fix `--lua=*.luases` being interpreted as a script (fixes #3814) 2023-10-29 06:38:06 +10:00
CasualPokePlayer c8f109eb34 fix ctrl/shift (probably more) with alt kb layout handling with RawKeyInput
also fix dinput not filtering out unknown key events (TODO: shouldn't this be handled higher up the input chain? surely we wouldn't want to respond at all to unknown key events)
2023-10-28 08:21:44 -07:00
CasualPokePlayer b98942dcfd minor fix in CWDHacks.Get()
fixes 686119c7dd
2023-10-28 05:10:31 -07:00
CasualPokePlayer 686119c7dd organize and cleanup a ton of win32 imports, do cleanup elsewhere with that 2023-10-28 05:05:36 -07:00
feos b4a6b06fba tastudio: disable rec mode when drawing inputs
see #2144
2023-10-28 13:35:01 +03:00
feos bb0bd415a6 address #3500 2023-10-28 12:20:22 +03:00
James Groom ef864536de
Fix typo'd `return;` in non-void method
fixes 672536305
2023-10-28 12:12:15 +10:00
James Groom 6725363052
Allow drawing on LuaPictureBoxes on multiple windows (fixes #3778)
fixes bb4ba2184, though it wasn't working correctly before that either
this whole thing needs deduping
2023-10-28 02:35:27 +10:00
James Groom 14c00d0ca2
In Debug config, don't use `Assembly.Load(byte[])` for ext. tools
apparently messes with the debugger IDK
2023-10-27 08:21:11 +10:00
James Groom 940c392fa3
Prevent selecting 'None' placeholder ext. tool 2023-10-27 06:46:20 +10:00
CasualPokePlayer 5c475ce898 Remove BizExvoker (unused for a long time, probably never going to use it)
Move MemoryBlock stuff and FPCtrl over from BizInvoke to Common
Move imports over to Common, remove unused imports
Do tons of cleanup here
2023-10-26 03:22:28 -07:00
CasualPokePlayer f2a4794105 Use source generation for SettingsUtil.SetDefaultValues 2023-10-25 22:52:06 -07:00
feos 5ce0aa24a5 fix #3481 2023-10-25 21:02:08 +03:00
feos 7ac9bc26cd mame: add reset 2023-10-25 20:30:32 +03:00
CasualPokePlayer edcd2cd548 fix Ctrl+C not SIGINT'ing, I think 2023-10-24 07:36:17 -07:00
James Groom 736abf32ac
Ensure FFmpeg DL target is writable before downloading 2023-10-24 23:11:54 +10:00
James Groom 542a0e08be
Fix `Process.Start` crash in Play Movie dialog on Linux 2023-10-24 22:50:44 +10:00
James Groom c7f438c240
Use loaded movie's filename for A/V filename 2023-10-24 22:46:22 +10:00
James Groom 65060c00f1
Fix/mute code style warnings 2023-10-24 22:32:17 +10:00
CasualPokePlayer b88c7e6baa fix warning from last commit 2023-10-23 22:48:42 -07:00
CasualPokePlayer cd4e58eaca make CRC32/SHA1 hashers not die when on a non-x86_64 platform 2023-10-23 15:41:27 -07:00
CasualPokePlayer 12a63e27e6 give more memory to melonDS
fixing OOM with 512MB games
2023-10-23 05:52:36 -07:00
CasualPokePlayer ee7fc95fac fix some usings 2023-10-22 19:28:23 -07:00
CasualPokePlayer 8941bac1ce remove BinaryQuickSerializer
see #3768
2023-10-22 19:23:32 -07:00
CasualPokePlayer cfdf607373 fix #3807 2023-10-22 01:05:32 -07:00
CasualPokePlayer 19552d6408 update Silk.* packages to 2.18.0, remove Silk .config hack (unneeded with this update) 2023-10-21 20:51:42 -07:00
CasualPokePlayer 220268809c Remove EvDevKeyInput. Pretty much useless in practice as apparently you need higher permissions (e.g. root) to access keyboard evdev files, direct evdev is more reserved for gamepads (already handled by SDL2)
Turn these OS specific key input impls into instantiable classes instead of a ton of static classes, a lot nicer to work with as don't need to constantly check CurrentOS to know which class to use, only the factory needs to check that!
2023-10-20 21:43:23 -07:00
CasualPokePlayer 62501ad859 do minor cleanup with EvDevKeyInput, add in define for switching from X11KeyInput to EvDevKeyInput 2023-10-16 16:08:19 -07:00
CasualPokePlayer d4602cf831 add Quartz key input handler
unused of course since no macOS support, but there when we need it
2023-10-15 19:06:53 -07:00
CasualPokePlayer b6d4b0dc81 remove some unused stuff 2023-10-15 04:17:06 -07:00
CasualPokePlayer a35ee381d0 Add evdev keyboard handler. Untested and unused for now 2023-10-15 04:11:32 -07:00
kalimag f3796756bc
Add setting to control what happens when double-clicking RAM watch (squashed PR #3802)
* Make RamWatch double click action configurable
* Make RamWatch Enter press share double-click behavior
* Make RamWatch double-click action default to poke
* Fix code style
* Reduce total diff size from extracting method
* Make sub-menu text more specific
2023-10-15 14:43:10 +10:00
CasualPokePlayer b5ebee7cd5 move RAWINPUT imports to a new file 2023-10-12 20:49:17 -07:00
CasualPokePlayer 5fc37d6aac add RAWInput keyboard handler, use it for OSTailoredKeyInputAdapter / SDL2
re-removes hard DirectInput dependency
2023-10-12 00:36:13 -07:00
CasualPokePlayer a320928a6f fix IOE in X11KeyInput.Update() 2023-10-11 17:48:23 -07:00
CasualPokePlayer ac3913ded3 add user agent for cheevo stuff 2023-10-05 02:05:31 -07:00
feos c438faeec9 added more mame mnemonics 2023-10-04 19:07:20 +03:00
James Groom 27c5b0e9b7
Also clear `GuiApi`'s image cache when restarting 2023-10-04 05:21:22 +10:00
CasualPokePlayer 0d4a1a6b26 fix #3781 2023-10-02 22:32:30 -07:00
CasualPokePlayer af4e9200ed fix memory leak when screenshotting/framedumping with osd with d3d9 display method 2023-10-02 21:08:48 -07:00
Morilli a71b228c70 reset "change" variables on tasproj load
Doing this fixes tasproj prompting for save on bk2->tasproj conversion (which makes no sense) and generally seems senseful to do; there is no point ever having a changelog or changes bool set just after loading a tasproj
2023-09-27 21:54:35 +02:00
James Groom cf809ed5aa
Override duration for onboarding OSD message
fixes a351dcc55
this is why you test changes even when you're sure they will compile
2023-09-26 23:52:52 +10:00
CasualPokePlayer 2b00e33560 add TransformPoint impl for NDS 2023-09-25 22:18:44 -07:00
CasualPokePlayer f6a77a8410 Fix touch coord calc when OpenGL is not available, probably fix off by one here too (I think this is right?) 2023-09-25 05:35:15 -07:00
CasualPokePlayer 07126b1e48 c# changes for 3d5c2120f2 2023-09-25 05:26:17 -07:00
CasualPokePlayer f63e50c91b C# changes for melonDS OpenGL support
also add in a way to debug OpenGL stuff (only built when uncommenting a define)
also do various cleanup here
2023-09-24 04:28:42 -07:00
CasualPokePlayer acff619034 add more mmap heap to melonds, check against 0 sized arrays in roms 2023-09-17 12:37:37 -07:00
CasualPokePlayer 0496d45e09 melonDS's logs already have a newline 2023-09-17 02:52:44 -07:00
CasualPokePlayer 0ad1f7feb2 waterbox has fun limitations 2023-09-17 02:16:25 -07:00
CasualPokePlayer 178939f76c woops 2023-09-17 01:03:42 -07:00
CasualPokePlayer d3dff6fe37 update c# side for melonDS changes 2023-09-17 00:58:49 -07:00
Morilli 2fc9f719e5 Fix #3685 again 2023-09-12 16:44:31 +02:00
CasualPokePlayer 4f98bf101c fix minor oops in previous commit 2023-09-11 22:57:04 -07:00
CasualPokePlayer d788e603fd force usage of bios on gambatte when recording a movie
(except when the rom cant be booted with bios, then enable bios sync setting is respected)
also cleanup this code a lot
2023-09-11 22:52:48 -07:00
CasualPokePlayer ed0dbb77ae expose SRAM for GBA rcheevos
see https://github.com/RetroAchievements/rcheevos/pull/265
2023-09-11 21:29:34 -07:00
James Groom e68a49aa51
Use absolute path to `ffmpeg` in `FFmpegWriter` 2023-09-11 16:31:23 +10:00
James Groom a7ee68f47d
Fix typo in Satellaview header model
see #3749
2023-09-10 22:38:19 +10:00
James Groom 2647bb8300
Log FFmpeg download fails to stdout in Debug config 2023-09-09 16:56:06 +10:00
James Groom a351dcc557
Make the onboarding flow impossible to miss
This should motivate widening the scope of profiles, and may also inspire additional features for onboarding such as paths/firmware, screen layout, or keybinds.
2023-09-05 05:47:03 +10:00
James Groom ebe3cad66c
Change UI label for `Config.AcceptBackgroundInput`
see #671
2023-09-02 01:47:52 +10:00
Moritz Bender 362269c982
Establish basic style analyzer rules (#3759)
* Fix analyzer nullable error

can't disable them in CA1305 xdd

* .editorconfig -> .globalconfig

* Add basic set of style analyzer rules

* dotnet format output

* Some additional fixes

* Apply manual simplification

* Transform some enum comparisons

* fix typo

* add TODO
2023-08-30 23:08:21 +02:00
James Groom 7193313e12
Comment-out unreachable code
fixes a315b122c
2023-08-25 11:59:35 +10:00
James Groom e86a0d6dda
When editing watches, select notes field 2023-08-25 11:41:51 +10:00
CasualPokePlayer 1575949762 upgrade these for c#10 2023-08-22 19:34:51 -07:00
CasualPokePlayer 19443040c4 slightly refactor OSD layer, no longer uses a render callback, rather it will do its logic itself and has its own enable drawing flag 2023-08-22 17:57:46 -07:00
CasualPokePlayer 53563657fe Implement blending enable/disable for IGL_GDIPlus (more just moving it away from GDIPlusGuiRenderer)
Fix GDI+ used for display method (got broken in some cleanup commits ago)
Remove some things meant to be removed in the last commit (fixes debug build)
2023-08-22 17:16:48 -07:00
CasualPokePlayer 8c1d996b80 simplify IGL 3: Remove ability to make custom blend states (was never used), only have 2 functions for blending, one enabling "normal" blending, one disabling blending (with alpha copy semantics) (only 2 which actually were used) 2023-08-22 16:46:21 -07:00
Morilli 757ae3293f Resolve part 4 of #3735 2023-08-22 19:22:34 +02:00
kalimag 54b1b2e421 Stop moving executables' pdbs to dll folder 2023-08-20 14:24:30 +10:00
kalimag d459aaaf6f
Dispose disks in Nyma cores (#3751) 2023-08-19 23:27:05 +02:00
Moritz Bender c57657bbd4
Set inputdisplay correctly on LoadState (#3747)
* Set inputdisplay correctly on LoadState

* Add explanatory comment for future generations
2023-08-19 23:22:55 +02:00
Morilli ebf1950873 fix #3686 2023-08-18 04:58:38 +02:00
Morilli 4fea6752f3 Fix #3685 2023-08-18 04:06:28 +02:00
Morilli ea7683a996 Bump LangVersion to 10 2023-08-16 16:30:06 +02:00
CasualPokePlayer c17f65fb10
Slightly increase sleep time while paused, should resolve #3737 2023-08-14 20:11:22 -07:00
Morilli c10d2927ca bump AnalysisModeUsage to Recommended
fixes CA2211, CA2215, CA2241, CA2251

silence CA1816 because it's unnecessary

reduce severity of CA2201 because I like the concept but don't wanna fix them all
2023-08-14 14:18:45 -07:00
Morilli 71e08e27b9 bump AnalysisModePerformance to Recommended
fixes CA1841

silence CA1805 and CA1822 because of sheer amount of violations

reduce severity of CA1838 because I don't wanna fix it lol
2023-08-14 14:18:45 -07:00
Morilli 6e20a3091c Fix CA1305 and bump to error 2023-08-14 14:18:45 -07:00
Morilli 8e557b0b9d bump AnalysisModeGlobalization to Recommended
fixes CA1304, CA1309, CA1310, CA1311

temporarily silences CA1305

reduce severity of CA2101
2023-08-14 14:18:45 -07:00
CasualPokePlayer 44dce7dc08 remove unused experimental code 2023-08-13 14:24:03 -07:00
CasualPokePlayer ae42858560 fix D3D9 crashing on minimize 2023-08-13 14:21:58 -07:00
Moritz Bender 56ac05f9a3
Allow migrating non-SHA1 hashes on movie import (#3733)
* Allow migrating non-SHA1 hashes on movie import

* Show more descriptive message on missing hash

* actually return null here

* Simplify LsmvImport

* add more hash HeaderKeys

* remove unnecessary IEmulator argument

this could potentially fix bugs even

* explicitly cast to ReadOnlySpan
2023-08-13 23:11:48 +02:00
Morilli b6f1bae7e1 Revert erroneous change to bk2 loading for now
fixes 0af4d125b2
2023-08-13 21:14:35 +02:00
Morilli 9131c8ab2e Change SmvImport to import to Snes9x core; various fixes
the importer is still far from perfect, but it should handle some things better than before

- closes #3177
2023-08-13 20:01:56 +02:00
Morilli 0af4d125b2 revert bd9ec3c57d, fix bk2 framebuffer load 2023-08-12 18:16:54 +02:00
CasualPokePlayer 4ad7736ca7 add some kind of 3DS support to retroachievements, probably 2023-08-12 04:22:46 -07:00
CasualPokePlayer 72cc192661 Create a new project to house the IGL WinForms controls (Bizware.Graphics.Controls), thus allowing for Bizware.Graphics to be netstandard2.0
also move GDIPlus IGL stuff over from BizwareGL to Bizware.Graphics
2023-08-12 03:56:02 -07:00
CasualPokePlayer 9139870e7e fix bug from 3622fe76f9, remove variable unused since 3622fe76f9 2023-08-11 16:59:14 -07:00
CasualPokePlayer dfd7caaacb use glBufferSubData when possible instead of glBufferData, gives a nice performance boost 2023-08-11 16:57:20 -07:00
CasualPokePlayer 3622fe76f9 simplify IGL 2: Combine BindArrayData and DrawArrays calls into one Draw call: only supports triangle strips (already limitation with D3D9), assumes start is 0, binding and drawing are implicitly merged into a single call (in practice BindArrayData would just save the vertex pointer to some class level variable for DrawArrays, so this is just better all around) 2023-08-11 15:33:08 -07:00
CasualPokePlayer 64abeddc2b simplify IGL 1: Combine Clear and SetClearColor, remove support for non-color buffers (not supported by GDI+, never actually used) 2023-08-11 13:30:46 -07:00
CasualPokePlayer f2942feb93 minor cleanup for 47c2d315ce 2023-08-11 00:34:07 -07:00
CasualPokePlayer 47c2d315ce drop OpenGL 2.0 support (annoying to support given we already require FBO support, which is an extension pre-3.0, and VAOs also fall under that same group, polyfilling this is just bleh)
in practice this means nothing for any Windows user (since D3D9 would support whatever garbage GPUs that had OGL 2.0 support but not OGL 3.0 support), so it only affects Linux users with GPUs from 2004-2010 (~2011 GPUs supported at least OGL 3.0), and those users probably have options to still use BizHawk if they really wanted to anyways

With this, switch the GuiRenderer (main) pipeline to use VAOs/VBOs instead of the old legacy fixed pipeline crap (other shaders still need that crap for now, so there is still a fallback path there). Also add in way to "free" the vertex layout (since it now can hold a VAO/VBO which needs to be freed once the vertex layout is finished)
2023-08-11 00:30:47 -07:00
CasualPokePlayer 8260a59bcf fix #3726 2023-08-10 00:07:10 -07:00
Randomno 1cf5af83dd
Change Odyssey 2 framerate (squashed PR #3728)
* change o2 framerate

* result
2023-08-10 04:11:02 +10:00
Morilli a496f09f07 Fix SmvImport CRC32 import
closes #3727
2023-08-09 11:14:31 +02:00
Morilli fe845ce8ef Don't double-load movies from the PlayMovie dialog 2023-08-07 14:14:22 +02:00
CasualPokePlayer 20ca53dfd1 Apply e186514c39 for copy mechanism
Also fix the formatting of the string, we want : here not .
2023-08-07 02:45:54 -07:00
Morilli e186514c39 Display day length for 1+ day long movies 2023-08-07 11:40:24 +02:00
CasualPokePlayer f8b3914126 fix broken movie length calculation
this happened to work by chance most of the time, but for movies which cant store the number of milliseconds in an int, it breaks down
2023-08-07 02:32:32 -07:00
CasualPokePlayer 97d9ce35e2 Disable Hybrid Screen setting in Citra for now 2023-08-06 03:21:22 -07:00
CasualPokePlayer 59fcdb04cd Remove Bizware Vector2/3/4 and Matrix4 in favor of System.Numerics's implementation
Many many cleanups in BizwareGL and DisplayManager and GDI+ code
2023-08-06 03:21:22 -07:00
CasualPokePlayer bb96825c60
System.Data.SQLite -> Microsoft.Data.Sqlite (#3719)
* Swap System.Data.SQLite with Microsoft.Data.Sqlite

Apparently this is supposed to be a kind of successor? https://learn.microsoft.com/en-us/dotnet/standard/data/sqlite/compare

* Add e_sqlite3 libs to Assets, prevent runtimes folder creation with OS tailored libs plopped in, delete System.Data.SQLite references
2023-08-05 17:45:40 -07:00
James Groom 2150061c91
Update LuaConsole.cs 2023-08-06 03:01:44 +10:00
CasualPokePlayer ca756a2df3 dont use ContextMenu
winforms net6 doesn't support it, and "replacement" ContextMenuStrip doesn't work for this use case, so just create a slim wrapper using CreatePopupMenu/DestroyMenu directly
2023-08-04 00:54:42 -07:00
CasualPokePlayer ba8656e345 slight tastudio tweaks wrt 12830bab4e 2023-08-03 21:03:20 -07:00
James Groom 1ebc006873
Update unit test to match new config schema
fixes 12830bab4
2023-08-02 18:03:06 +10:00
CasualPokePlayer dc34b0b1a9 add in Wine/Proton detection, used to prevent D3D9 from being used if a user ends up using wine/proton (as often it seems D3D9 wine/proton just doesn't work and crashes in weird ways, sometimes *after* checking the renderer so it wouldn't fallback to OpenGL anyways)
Probably can add in some first time message box warning the user that wine/proton isnt supported, although we probably shouldn't block wine/proton (considering it's the only option for some distros with read-only filesystems, like the Steam Deck)
2023-07-31 23:02:30 -07:00
CasualPokePlayer 67e5505899 Rework OpenGL version support checking to be more robust, slightly rework OpenGL context creation request (they can now explicitly request the core profile) 2023-07-31 22:32:30 -07:00
CasualPokePlayer a2ea86fae0 add NET6_0 guard for GetValueOrDefault backports 2023-07-31 22:01:05 -07:00
CasualPokePlayer 811275cca8 Rewire memory domain pointers after reset in Citra
Add 3DS framerate in PlatformFrameRates
2023-07-31 21:22:57 -07:00
CasualPokePlayer 1ee2ef928c Prevent SDL from doing windows message pumping
Normally SDL doesn't do this as we don't ever call SDL_PumpEvents (or anything that calls that). However, OpenGL context creation code ends up calling WIN_PumpEvents regardless. This usually doesn't matter, however, in some cases, this can cause crashes, mainly with loading a state with Citra, as that ends up re-constructing its frame dumping OpenGL context (yeah that's dumb and useless but it's mostly harmless, outside of this message pumping). The WIN_PumpEvents calls appear to be unneeded anyways, so we can safely disable message pumping here.
2023-07-31 15:55:36 -07:00
CasualPokePlayer a315b122c5 force OpenGL renderer in Citra for now
the software renderer doesn't seem to be functional and the code for blitting it is incomplete
2023-07-29 17:03:53 -07:00
CasualPokePlayer 33f1c5472a add missing Dispose() for Citra ctor failure case 2023-07-29 16:26:29 -07:00
CasualPokePlayer 0a72dc046f add in missing mnemonics for 3DS controls 2023-07-29 15:22:56 -07:00
CasualPokePlayer e62c972ca3 Check in citra dll/so, add in build scripts/linux glslangValidator for citra, some minor cleanup handling with citra input handling 2023-07-29 15:09:17 -07:00
CasualPokePlayer f1e9f10454 Minor reworking of IGL OpenGL context creation
Try to regain compat with < OpenGL 3.0 users, better checks against OpenGL availability
2023-07-28 23:26:51 -07:00
CasualPokePlayer e7f4ad8220 fix exception popping up when Dispose()'ing DisplayManagerBase with OpenGL 2023-07-28 22:19:15 -07:00
CasualPokePlayer 12830bab4e Add in flag to IStatable to hint to the frontend that it should avoid rewind (not entire sure with the name, maybe SlowStates would have been better? trivial to mass-rename anyways)
Add in logic to not create the main rewinder if this flag is true, and add in logic to tastudio to avoid the main greenzone captures (instead only capture on branch save/load)
2023-07-28 22:07:31 -07:00
CasualPokePlayer 1ad3ed2216 minor cleanups in IGL_OpenGL 2023-07-28 15:38:43 -07:00
CasualPokePlayer 7a2f1532bf fix DS being shown upside down when ScreenControlNDS is used
fixes 78f5e75534
2023-07-28 14:54:02 -07:00
CasualPokePlayer f7448495b0 correct 3DS rom check in XmlGame
fixes 8c41b09108
2023-07-28 05:37:47 -07:00
CasualPokePlayer 8c41b09108 Add in 3DS rom extensions to rom filter
make it so CIAs past index 0 will be "installed" (mostly only relevant for movies, as the temp user folder is wiped each session in deterministic mode)
ensure XMLs won't load 3DS roms into memory (same reasoning as other hack, might be >=2GiB)
do some cleanup with this code
2023-07-28 05:33:56 -07:00
CasualPokePlayer 4ff157f652 add in Citra for global core config menu 2023-07-27 22:41:03 -07:00
CasualPokePlayer bd2c2ffc86 /s/_3DS/N3DS 2023-07-27 22:37:06 -07:00
CasualPokePlayer 5607845b24 Add in screen control filter for Citra port 2023-07-27 22:20:50 -07:00
CasualPokePlayer ff57303821 Add in 3DS entry for SystemIDDisplayNames 2023-07-24 00:39:50 -07:00
CasualPokePlayer 89b387e50d add memory domains for Citra 2023-07-24 00:14:11 -07:00
CasualPokePlayer 67510f3b56 cleanup 3DS firmware handling
seems these methods aren't really supported in citra, so I guess have fun dealing with manually setting firmware files
2023-07-23 21:22:26 -07:00
CasualPokePlayer 18b81a2011 Fixup OpenGL version reporting; add debug print for 3DS firm installing message
fixes 8ae947fed7
2023-07-23 20:09:17 -07:00
CasualPokePlayer 41ee99999a Add 3DS firmware handling 2023-07-23 19:55:58 -07:00
CasualPokePlayer 739c35c174 fix #3692 2023-07-23 03:58:46 -07:00
CasualPokePlayer dd5cbc92af set WRAM as the main memory domain in SameBoy
see #3711
2023-07-23 03:44:09 -07:00
CasualPokePlayer 2d17290918 add in RetroAchievements support for Uzebox and TI83 2023-07-23 03:38:29 -07:00
CasualPokePlayer 01cc5ca476 fix a RetroAchievements PSX hashing edge case 2023-07-23 03:28:54 -07:00
CasualPokePlayer e87536ea8f commit C# parts for Citra port
not committing the dll yet until some more things are ready
2023-07-23 03:14:26 -07:00
CasualPokePlayer cdfb8d67e8 commit citra submodule 2023-07-23 02:46:37 -07:00
CasualPokePlayer bed66e2cd4 fix minor oopsies / dumbs with previous commit 2023-07-23 02:16:24 -07:00
CasualPokePlayer 8ae947fed7 prep work for easier OpenGL interop for cores 2023-07-23 01:54:36 -07:00
CasualPokePlayer 78f5e75534
Kill Bizware .NET Framework deps (#3702)
The main objective in this PR is to get rid of the main .NET Framework dependencies in Bizware packages. This PR doesn't do that completely per se, still having .NET Framework used for WinForms Controls, but that can easily be swapped over for whatever UI framework we use next as long as it exposes native window handles in some way.

For this PR, it does some reorganizing of Bizware, splitting Bizware.OpenTK3 and Bizware.DirectX into 3 packages based on usage; Bizware.Audio, Bizware.Graphics, and Bizware.Input. These packages in the future probably could have more functionality moved into them, but for now they are largely just a reshuffling of the Bizware.OpenTK3 and Bizware.DirectX packages.

As both SlimDX and OpenTK3 are .NET Framework, they have been removed in this PR. Their replacements are as follows:

SharpDX: DirectSound, Direct3D9
Vortice: XAudio2, DirectInput/XInput
Silk.NET: OpenAL, OpenGL
SDL2-CS / native SDL2: OpenGL context management, new gamepad backend (replacing OpenTK's role for gamepads)
native X11: New key input backend (replacing one of OpenTK's roles for keyboards)

GLControl has been replaced by custom made control which just uses SDL2 for context management.

The OpenTK input backend has been replaced with a combination of SDL2 and an OS tailored key input backend (DirectInput on Windows, X11 on Linux, and planned to be Quartz on macOS). This is just represented on the user side as "SDL2" without mentioning the key input backend. This does mean for a while DirectX will be mandatory on Windows again, until a RAWINPUT backend is written for handling key input on Windows for the SDL2 input backend.
2023-07-23 00:35:43 -07:00
zeromus fe47285394 trim cheat lines, since it's virtually impossible to copy text from a web browser without getting junk around it 2023-06-30 19:42:28 -04:00
YoshiRulz 6b87e3ac91
Fix being unable to open SubGBHawk via system menu (fixes #3693) 2023-06-25 01:23:14 +10:00
SG d8ea4547d4
Add StringFormat to pixeltext DrawString parameters (squashed PR #3690)
* Add StringFormat to DrawString parameters

* Revert whitespace changes

* Code style nitpicks, cache `StringFormat`

---------

Co-authored-by: YoshiRulz <OSSYoshiRulz@gmail.com>
2023-06-21 09:20:54 +10:00
YoshiRulz 4ee7e4cad7
Add deduper utility to RAM Watch 2023-06-13 23:43:53 +10:00
YoshiRulz 25ad59d895
Replace type check with enum (int) comparison in `Watch` 2023-06-13 23:43:53 +10:00
YoshiRulz ca8a183f38
Add `WatchList.InsertRange` and use when duplicating rows in RAM Watch 2023-06-13 23:43:53 +10:00
YoshiRulz 4d4887ee31
Fix `WatchList.Insert` not setting dirty flag
not sure if this was problematic in practice
2023-06-13 23:43:53 +10:00
Morilli 13dd04a026 Fix #3679 2023-06-07 23:01:54 +02:00
CasualPokePlayer 9e5fb35f7a Add in missing TMD for Cave Story Japan 2023-05-29 02:25:36 -07:00
Morilli c3ec8393d0 Optimize Remove[Prefix|Suffix] by using ordinal string comparison 2023-05-27 03:50:46 +02:00
adelikat f6135abe65 disabled log generator caching in bk2, it has playback problems not found it basic testing, need to revisist this later 2023-05-26 19:19:08 -05:00
YoshiRulz fde16fa5a3
Hide D=>A TAStudio columns w/ Ares64, rename C* buttons in header
initial implementation by @thekovic
2023-05-27 03:01:49 +10:00
nattthebear 3d5b068c2f QuickNES: Slightly tweak palette rounding computation
Fixes #3668
2023-05-26 07:01:56 -04:00
nattthebear 8a94204a2f QuickNES: Fix loading 64 color palettes
Since ee0992158d, we were using the default palette for deemphasis modes, instead of computing it based off of the input palette.
2023-05-26 06:46:56 -04:00
adelikat cb721a39da de-engineer some movie stuff, ILogEntryGenerator is not an important abstrations now that Bkm is gone 2023-05-25 15:01:30 -05:00
adelikat 33ed05b20c BK2LogEntryGenerator - further optimize by doing the control ordering once 2023-05-25 13:32:58 -05:00
Morilli f697a828c8 Optimize CreateLogEntry
Surely this is safe, right?
2023-05-25 13:19:16 -05:00
adelikat 05f8747321 optimize movie recording loop a bit, do not create a new instance of log entry generator every frame, avoids a lot of memory allocations with mnemonic lookups that do not change for the lifetime of the movie, also a slight optikmization in Bk2 controller, co-authored iwth morilli 2023-05-24 11:18:42 -05:00
YoshiRulz 9daac2c26f
Add and use extension method `string.StartsWith(char)`
reverts 333ce98a7, partially reverts bc16a2cda
2023-05-23 09:18:25 +10:00
adelikat 333ce98a71 low hanging fruit speed up in inputlog loading using str[0] == c instead of str.StartsWith(c) 2023-05-22 12:50:30 -05:00
YoshiRulz 681ef72cd5
Change wording of checkbox for `Config.SuppressAskSave` 2023-05-21 16:22:54 +10:00
CasualPokePlayer ccf2c61a23 fix #3664 2023-05-20 03:11:40 -07:00
CasualPokePlayer 08ead80385 make these callback delegate caches static (why didn't this warn that static was possible here?) 2023-05-19 22:30:17 -07:00
CasualPokePlayer 3c53f52c6d remove some debugging crap from c9e30060d4 2023-05-19 22:28:32 -07:00
CasualPokePlayer 542cf2433a Reduce allocation spam in Jaguar disassembly functions 2023-05-19 22:26:45 -07:00
CasualPokePlayer c9e30060d4 Rework the Reader/Writer callbacks for the WaterboxHost, a bit nicer here working with the userdata
Also make it so initial loading uses the zstdstream or filestream directly instead of a memorystream with it all loaded
something of note, not really happy with how these read/write callbacks get used in practice, it seems they get spammed in small chunks
for initial loading, it's 8192 byte chunks each, which can be a LOT of callbacks, depending on core size (gpgx is ~500, MAME is ~22K)
similarly, savestates suffer a similar issue, although instead it's a ton of 4096 byte chunks (page size eh?)
The unmanaged <-> managed transitions obviously are not exactly performant, and I imagine are taking a significant portion of the time here
Perhaps some buffering strategy should come in on the native waterboxhost side to alleviate callback spam?
2023-05-19 22:26:45 -07:00
adelikat 99a6b1d339 add hotkey for toggling the 'Display Nothing" feature 2023-05-19 20:05:16 -05:00
CasualPokePlayer 8a13793d00 Turn WaterboxHostNative ReturnData to a struct, misc cleanups elsewhere 2023-05-18 22:21:17 -07:00
CasualPokePlayer 332143ea8d invalidate cram caches when poking, maybe 2023-05-18 21:14:57 -07:00
CasualPokePlayer 473d3cc294 fix #3662 2023-05-18 19:09:08 -07:00
CasualPokePlayer ea854ff39d make discohawk form a bit bigger
all the formats supported means the box wasn't big enough to display all of them lol
2023-05-18 07:28:10 -07:00
CasualPokePlayer fe79b69123 (Partial) .nrg support
TAO support isn't complete, a lot of sanity checking isn't done yet
2023-05-18 07:14:14 -07:00
Morilli 3d30f52e7c Fix LogWindow treating everything as ascii
hopefully this doesn't break anything
2023-05-17 14:54:18 +02:00
CasualPokePlayer f11b5bc9c4 fixup CDI generated subcode (not sure why I did that)
have it generate "leadin" and "leadout" tracks for multisession discs... this is almost certainly wrong for leadin (doesn't matter so far), leadout is probably right...
2023-05-12 20:47:29 -07:00
CasualPokePlayer 0e6d5fb708 minor addendum to 2012b083f6 2023-05-12 03:28:14 -07:00
CasualPokePlayer 2012b083f6 Fixup multisession handling with MDS and improve its track/sector size handling, also maybe fix it entirely? (not sure if this ever worked)
Move the various synths using the CUE SS_Base to a file, mostly just a nicer organizational change as MDS and CDI use one of these but not CUE
Misc improvements elsewhere
2023-05-12 02:44:05 -07:00
CasualPokePlayer 1f3068fe77 fix synthesizing disc tracks with multisession discs when the first session has a large amount of tracks
FirstRecordedTrackNumber only works here for the first session, for future sessions it doesn't work and may just result in out of range exception
2023-05-11 02:57:14 -07:00
CasualPokePlayer 858ea372a9 Fix Jaguar CD detection for Caves of Fear 2023-05-11 02:28:33 -07:00
CasualPokePlayer e3c27813b6 fix the fix in 45a0c8cffb 2023-05-10 05:37:03 -07:00
CasualPokePlayer 45a0c8cffb another fix for 9551394 2023-05-10 05:23:24 -07:00
CasualPokePlayer c52a950c41 Fix dumping CCDs with multisession discs, fix oopsies with CDI parsing giving the wrong last recorded track number 2023-05-10 04:58:37 -07:00
CasualPokePlayer 2379650e1b Implement error and verbose message callbacks for rcheevos (currently they just output to the console)
Implement debug option for hashing with more pure rcheevos logic, mostly just useful for figuring out disc hashing issues
2023-05-10 03:11:50 -07:00
CasualPokePlayer d3a689c589 Resolve #3650. Also fix a bug which caused overwriting lua scripts with a new lua script to fail (fixes 380e459bec) 2023-05-08 03:01:41 -07:00
CasualPokePlayer f677e92504 fix TOC field mixup with Jaguar CD 2023-05-07 22:09:52 -07:00
CasualPokePlayer 40e21b716e fix 955139454a 2023-05-07 02:59:38 -07:00
CasualPokePlayer 7d5a1d5c98 Lower CPU usage from RCheevos http stuff 2023-05-07 02:41:07 -07:00
CasualPokePlayer 68cd28c28a fix directionals and other common buttons being dropped from controller inputs when hotkeys overrode controller inputs 2023-05-07 01:00:13 -07:00
YoshiRulz 4a752f66b7
Add Analyzer to require checking or discarding `TryGetValue`
I'm pretty sure all the existing instances were intended to use `default(T)` if
the key isn't present, except maybe the cheatcode converters but I don't care to
rewrite those at the moment
2023-05-05 06:27:15 +10:00
YoshiRulz 384a4e1e18
Bump version info post-release 2023-05-04 08:10:07 +10:00
CasualPokePlayer 36fae775d4 Prevent annoying waits when using firmware manager with DSi NANDs present 2023-05-03 02:19:56 -07:00
CasualPokePlayer 5f6d70ac46 Fix random crashes with rcheevos. The issue was that rc_runtime_t can store pointers to itself, which is bad when rcheevos expected the user to allocate that struct and did not provide functions for that. I've added that functionality and PR'd it (I'll fixup submodule to point to upstream when it's merged)
PR can be found here: https://github.com/RetroAchievements/rcheevos/pull/239
Also minor fixes wrt the ContinueWith usage in InternalDoRequest
2023-05-03 01:54:57 -07:00
CasualPokePlayer 248b8ab984 Fixup bad threading (no, you cannot access rcheevo's _runtime in a separate thread! main thread use only!). Should fix up some random crashes
Slightly change up the request model, now InternalDoRequest does not block
Fixup logic of ToSoftcoreMode (and comments so it isn't screwed up again)
2023-05-02 21:47:09 -07:00
CasualPokePlayer 8ef1d93891 Prevent UI thread deadlocking on Dispose()'ing rcheevos stuff 2023-05-02 17:18:31 -07:00
CasualPokePlayer b9a983f1fe Fix typo causing crash with SMSHawk with RetroAchievements & Hardcore Mode 2023-05-02 17:08:39 -07:00
CasualPokePlayer 41d94e4262 Change up multithreaded rendering in melonDS
Instead of creating a new Task and destroying it every frame, just create a new thread and call the delegate when needed.
Also allow for rendering a frame twice, this is actually possible anyways (albeit rarely done).
This should also help against a potential deadlock due to the Task.Wait call on the UI thread (which has special semantics in WinForms)
Also minor nitpicks in RCheevos code
2023-05-02 16:52:48 -07:00
CasualPokePlayer b517228475 Refactor rcheevo http requests (again). This should better protect against the UI thread deadlocking due to Task semantics with WinForms 2023-05-01 03:50:49 -07:00
vadosnaprimer e065263ff2 MAME does mark bad dumps, but it only keeps their info if good dump is not known yet. once a good dump appears, its info replaces the bad one.
so simply sticking to newest rom sets is the safest, otherwise there's little user control, because there's no global list of all known dumps with indications which of them are bad and what to use instead.
2023-04-30 14:07:08 +03:00
CasualPokePlayer 2010f5e15c disable leaderboard list form, for now, and revert efa6505
see that commit for details on issues with this form (this form is kind of useless anyways, meh)
2023-04-28 18:37:06 -07:00
YoshiRulz 8a5921182e
Add Analyzer to disallow discarding locals e.g. `_ = result;`
fixes 70bd081a9, a2185d9ef
2023-04-29 01:52:43 +10:00
CasualPokePlayer a2185d9ef0 fix 70bd081a93
The entire call is skipped in release mode if you place it inside a Debug.Assert.
2023-04-28 03:14:56 -07:00
YoshiRulz 66f26bb1c1
Create and use `IDictionary.GetValueOrPut{,New,New1}` extensions 2023-04-27 17:25:03 +10:00
YoshiRulz fa48278354
Enable MEN014 and fix noncompliance
"Prefer TryGetValue"
2023-04-27 17:24:55 +10:00
CasualPokePlayer c8589de5c6 fix #3648 2023-04-26 23:05:11 -07:00
sverx 102dee9622
Fix some SMS audio inaccuracies (squashed PR #3602)
* fix noise audio channel on SMS VDP

* Update SN76489sms.cs

also, white noise is generated by XORing bits 0 and 3, not 0 and 1, on an SMS/GG VDP

* Update SN76489sms.cs

reverting commit #7b857e7
2023-04-27 15:46:52 +10:00
Daniel Parks dd30a389a0 TAStudio/PatternsForm: Block deletion of loop entry which would cause a crash 2023-04-27 15:14:44 +10:00
Daniel Parks 07ba36956a TAStudio/PatternsForm: Allow looping to entry zero 2023-04-27 15:14:44 +10:00
YoshiRulz 9cbd238997
Convert `GenericDebugger.DisasmOp` to a struct 2023-04-23 19:08:19 +10:00
YoshiRulz 70bd081a93
Refactor `ServiceInjector` 2023-04-23 17:41:55 +10:00
YoshiRulz c5d6a66e01
Resolve TODO re: memoisation in `GenericDebugger` 2023-04-23 17:41:55 +10:00
YoshiRulz 4b001a48a9
Dedup `GenericDebugger.EngageDebugger` 2023-04-23 17:41:55 +10:00
YoshiRulz ac3e76309f
Use helper prop here 2023-04-23 17:41:54 +10:00
YoshiRulz bcdeec369a
Move commented-out code to `#if false` 2023-04-23 17:41:50 +10:00
Morilli 396e876320 Optimize TAStudio column drawing by caching PlayerNumber for each column name
TAStudio previously called `PlayerNumber(...)` for each visible cell with the column's name, only to determine whether its player number is odd or even.

Because that function uses regex and is potentially called extremely often, this had a noticable impact on fps.

I've decided to just cache the odd/even playernumber result in a dictionary for faster access, which while not being my preferred way of handling this at least results in a decent speedup.
2023-04-23 00:15:43 +02:00
Morilli afb92870e4 TargetName -> AssemblyName
this fixes the winforms designer in Rider, let's hope it doesn't break anything though
2023-04-22 13:51:13 +02:00
CasualPokePlayer a8aced4474
Workaround crashes in MAME's zlib decompression code (#3639)
* Workaround crashes in MAME's zlib decompression code (see https://github.com/TASEmulators/BizHawk/issues/3615)

* Use using block, only catch InvalidDataException (what will be thrown if the zip entry has an unsupported (likely lzma) compression method)
2023-04-20 09:29:03 -07:00
CasualPokePlayer efa6505826 prevent crashes when loading up leaderboard forms
apparently some game had 2002 leaderboards which caused a crash when making a form for every one of them in the leaderboard list, I guess windows has a limit on the amount of forms that can be active at once?
this is a quick hack to prevent such a crash, design needs to be rethought
2023-04-20 09:00:16 -07:00
Morilli 1356bc6a3f i guess this is required oops
fixes bc16a2cdaa
2023-04-20 12:31:33 +02:00
Moritz Bender bc16a2cdaa
Implement IBasicMovieInfo interface for IMovie (#3634)
* Implement IBasicMovieInfo interface for IMovie

this allows parsing basic movie fields into an own class that is independent from Bk2Movie/TasMovie

This is mainly useful for the PlayMovie dialog which can now load movie information from files on disk without having to go through the entire Bk2Movie/TasMovie loading process

* don't potentially iterate input log twice

* Optimize LoadFramecount
2023-04-20 10:43:02 +02:00
CasualPokePlayer cf88e61875 c# side changes to use the split ares' binaries
resolves #3614 and #3617
2023-04-19 23:23:12 -07:00
CasualPokePlayer 8cf820da4d Don't send invalid paths to MAME
Waterbox cores can't create files anyways, and trying to send in ? might make MAME try to make the directory anyways (which crashes due to the syscall for that being unimplemented), while "" will not do that
2023-04-19 18:41:05 -07:00
YoshiRulz b5e2a0c422
Move some .gitignore entries to nested dirs 2023-04-19 15:59:34 +10:00
CasualPokePlayer 955139454a fix Jaguar CD homebrew hashing wrt retroachievements 2023-04-18 22:38:13 -07:00
CasualPokePlayer 4268c50617 Fix RetroAchievements rich presence not working
Cleanup this code so it plays nicer with BizHawk's "run everything on the main thread" (+ WinForms not playing nice with async methods)
Resend any game session start / achievement unlocks / leaderboard triggers if they failed. Wait for all achievement unlocks and leaderboard triggers to finish on Dispose() (mostly for catching them when user closes BizHawk)
Update rcheevos to 10.7.0
2023-04-18 21:35:58 -07:00
YoshiRulz 20e5c43bc8
Add `--socket_udp` CLI flag 2023-04-18 19:15:02 +10:00
Morilli 0f2a76bd5e lazy-initialize zstd contexts to reduce alloations
This becomes mostly apparent in the PlayMovie dialog where one zstd instance is created for every single movie, churning significant amounts of memory even though zstd isn't even used
2023-04-16 15:33:40 +02:00
CasualPokePlayer 98afdb8993 (Actually) Fix DeltaSerializer's `GetDelta`
fixes 2838a5412a
2023-04-15 22:04:21 -07:00
CasualPokePlayer 2838a5412a Fix DeltaSerializer's `GetDelta`
Fixes AppleII/C64 states sometimes crashing when a disk change actually happens
2023-04-15 21:33:51 -07:00
YoshiRulz ebd36f08b6
Downgrade `System.Drawing.Common` to 6.0.0 and enable Unix impl.
fixes 65ffa3fc2
testroms run now, CBB checking GambatteSuite runs but I'm guessing it does too
2023-04-16 10:49:18 +10:00
YoshiRulz 6ffe99c006
Use the right `Sameboy` ctor in testroms project
This reverts commit 379eeeeed8.
2023-04-16 10:14:46 +10:00
YoshiRulz 236c748b1a
Downgrade MSTest to 2.2.9
fixes 65ffa3fc2
2.2.10 and above result in the error `The type or namespace name 'TestContext'
could not be found`
2023-04-16 10:14:43 +10:00
YoshiRulz a1fe557d31
Re-enable MA0020 and fix noncompliance 2023-04-16 09:02:40 +10:00
YoshiRulz 65ffa3fc2e
Blindly update NuGet deps
temporarily disabled MA0020
2023-04-16 09:02:40 +10:00
100thCoin 85a481f93f
Nes.Core now updates the DataBus in WriteMemory() (#3633)
* Nes.Core now updates the DataBus in WriteMemory()

This will fix open bus execution following write instructions.

* Properly formatted changes in previous commit

I have addressed the requested changes.
2023-04-15 21:24:27 +03:00
YoshiRulz f2880d8325
Update `CoreComm` init in testroms project to new signature
fixes 76a29d356
2023-04-15 10:36:43 +10:00
YoshiRulz 379eeeeed8
Make `Sameboy` ctor public so testroms project can use it
fixes 9528a2030
2023-04-15 10:36:39 +10:00
vadosnaprimer c90fcbbd54 mame: numerator 0x4000'0000 and above breaks mp4 on youtube... 2023-04-14 19:32:29 +03:00
vadosnaprimer 8e6eac7bfd mame lua doesn't expose settings for optional dip switches, so hide them for now
38498868fc/src/mame/toaplan/toaplan2.cpp (L2960)
2023-04-14 19:23:50 +03:00
YoshiRulz 59562d8930
Fix `[RequiredService]`s checked for `null` 2023-04-13 08:53:14 +10:00
YoshiRulz 5f77a310c5
Remove `ServiceInjector.ClearServices`
This call in `ToolManager.Restart` was to set `[{Optional.Required}Service]`
props to `null`, but the tool form would get `Close`d immediately afterwards, so
it never gets the chance to hit the `null` path if one exists. However, some
tools are written as though they keep the stale value, for example attempting to
call a cleanup function on it in their `Closed` event handler. These will now
work as intended.
`[OptionalService]`s that can't be satisfied are set to `null` by
`ServiceInjector.UpdateServices`, so clearing those isn't necessary, and
`ClearServices` has no other usages.
2023-04-13 08:53:14 +10:00
Moritz Bender ddc3e929e9
Use source generation for VersionInfo (#3625)
* Use source generator for VersionInfo

* Remove leftover hacks

* Use same fallbacks as NixHawk when Git not available

---------

Co-authored-by: YoshiRulz <OSSYoshiRulz@gmail.com>
2023-04-12 21:14:44 +02:00
CasualPokePlayer 03aa420bd5 fix last issue in #2951 properly 2023-04-09 23:43:28 -07:00
vadosnaprimer ffd8e6897a don't keep multidisk flag on after it was set once
don't replace mame rom info icon and text with multidisk ones if there are emulation issues
2023-04-09 23:52:50 +03:00
vadosnaprimer fadc445f9c mame: print more rom info 2023-04-09 23:40:59 +03:00
vadosnaprimer 76a29d3563 allow setting OSD message duration for its callbacks
todo: simulate optional args for Action?
2023-04-09 22:08:37 +03:00
vadosnaprimer b4394af824 mame: report emulation status via rom info icon and text
mame won't care too much about how good the dump is, but it will warn you in orange that emulation is imperfect, and in red if it's broken. we happen to use rom status icon to inform the user about multidisk bundle, so using it for mame info feels natural, because it directly affects what users can safely submit to tasvideos. we warn them about bad dumps because it's banned for pub, so it's similar here.
2023-04-09 21:38:56 +03:00
vadosnaprimer 8aa03c3059 mame: add emulation issues info to RomDetails
reorder file hashes and names so it looks aligned
2023-04-09 19:22:19 +03:00
YoshiRulz 0469c04372
If a PSX `.bin` is loaded, try synthesising a `.cue`
this works but takes forever, which I'm guessing is because somewhere it's
trying to hash the whole file. that's not a new problem though
2023-04-09 10:06:06 +10:00
CasualPokePlayer 5f0683c1ae Fix #3616
This had two issues. One, relative pathing with dlls is a no-go. Our hackery with changing cwd seems to confuse lua, and while it can find the dll, it fails to load as Windows (at least) does not consider cwd for loading up dlls it appears. Secondly, people using luasockets never actually loaded up the luasockets dll, rather we were bundling it ourselves. From history it seems this was due to our lua being compiled with CLR/.NET and that didn't play nice with exceptions? Doesn't seem to be an issue anymore, but we should probably still bundle luasockets for the time being given it used in many different projects which use the same script with multiple different emulators (thus our own sockets are simply not usable).
2023-04-08 16:01:36 -07:00
YoshiRulz 8ef8d4efb9
Remove unused `kernel32` import 2023-04-09 08:02:35 +10:00
vadosnaprimer e06d32c70a Revert "throttle shouldnt act as paused when rewinding"
This reverts commit 007442773a.

fixes #3268 but unfixes #3053, which should instead be fixed by something that doesn't lead to breaking other things and the author of the "fix" giving up on the project
2023-04-08 23:07:34 +03:00
YoshiRulz 45ab749caf
Fix N64 (Ares64) system menu having a blank space on Mono 2023-04-09 05:34:19 +10:00
vadosnaprimer 4ea80410b8 mame: fix bios selection menu
api changed in 952b4ecc67
2023-04-08 10:46:28 +03:00
YoshiRulz 619c25b69a
Bump version 2023-04-08 05:12:57 +10:00
YoshiRulz 6e77c7348f
Improve error message when core does not implement mem callbacks 2023-04-08 02:16:29 +10:00
CasualPokePlayer fbe1f9b53e fix parameter order with DeltaUpdate calls
fixes 8737203f3a
2023-04-04 23:54:05 -07:00
CasualPokePlayer 389c6ebec5 fix 2mg detection
fixes 8737203f3a
2023-04-04 23:52:05 -07:00
CasualPokePlayer 8737203f3a Add ISaveRam implementation for AppleII, fix bug which caused DiskIIController to not be correctly stated 2023-04-04 23:46:26 -07:00
CasualPokePlayer 9ae5f786de fix #3610 2023-04-04 05:04:00 -07:00
CasualPokePlayer b8f3f089f2 Add in ISaveRam implementation for C64, using the deltas of disks.
Add in better docs for `DeltaSerializer`.
Fix C64 not remembering disk changes when swapping disks (swapping disks essentially just reset the disk previously)
2023-04-04 04:28:47 -07:00
CasualPokePlayer 2fc4683e6b Fix edge case with C64 states when CurrentDisk is different 2023-04-02 06:58:56 -07:00
vadosnaprimer d95cd4becb mame: use biggest int multiple of 60 as a framerate numerator
denominator is determined by taking refresh attoseconts `as_ticks(numerator)` which reduces the initial 64bit value to what can be used for video

mame needs flat 60fps for screenless machines, so we use a numerator that is a multiple, while also being a tiny bit more accurate than with 1,000,000,000
2023-04-02 16:54:28 +03:00
CasualPokePlayer df71de64c8 speedup delta stating with disks with simple track tracking, should be within acceptable performance bounds (more or less) 2023-04-02 03:48:24 -07:00
CasualPokePlayer 86b33bd3ce fix DeltaSerializer validation checks and add one more 2023-04-02 02:19:52 -07:00
CasualPokePlayer 6f7f94a06e don't give the same name to each track when stating
fixes 00e2fea901
2023-04-02 02:12:25 -07:00
CasualPokePlayer 00e2fea901 Create `DeltaSerializer`, uses simple RLE encoding so the serialized delta isn't huge, use it for C64 EasyFlash and Disks 2023-04-02 02:10:51 -07:00
CasualPokePlayer 5ca888a8af misc cleanups with previous commit 2023-04-01 19:57:47 -07:00
CasualPokePlayer a311b3b6f3 Change up AppleII's "main ram" domain, add aux ram domain
The main ram previously seemed to just be a slice of the system bus between 0 - 0xbfff. this posed two problems: that area is banked, and that area could represent main ram or aux ram. main ram now represents all of the ram main ram can possible represent, ordered like how the core orders it (which the way it does it happens to be very natural in any case), and a new aux ram domain does the same thing but with aux ram
Also some other changes put in so Rider wouldn't error on building Virtu
2023-04-01 19:54:26 -07:00
YoshiRulz 2a70b532d5
Disable Hex Editor's "Save [to rom file]" when not looking at rom
fixes 2e19451b0
not the "ROM" domain, but the "File on Disk" domain
2023-04-02 05:30:34 +10:00
CasualPokePlayer cd4c3cc353 fix various C64 state issues
Main changes here would be with cartridges, as it appears cartridge stating was just broken since 4ffcc9654a (that's all the way back in 1.13!!!) due to SyncStateInternal not actually getting used
a few other components also had some variables missing from states
disks are not properly savestated yet, it appears it was commented out due to an assumption that disks were write only, but this isn't the case
some other cleanups here, none of them actually affecting state quality here
2023-04-01 07:06:56 -07:00
CasualPokePlayer a31ecb7c0f fix new BSNES with subbsnes
fixes 22e35c45fc
2023-04-01 01:26:38 -07:00
CasualPokePlayer 22e35c45fc hook up RTC support for new BSNES, resolves #3577 2023-04-01 01:23:16 -07:00
CasualPokePlayer 116bc26556 add in entries for the various regions for DSi NAND, add in handling to autodetect region
tentatively add in the bios7i and bios9i hashes from nointro
2023-03-31 20:22:23 -07:00
CasualPokePlayer 6284c98d72 hook up clear NAND flag and dsiware saveram support
do various cleanups
enforce clear NAND flag for movie recording and retroachievements hardcore mode
2023-03-31 06:23:58 -07:00
CasualPokePlayer 7ae3f447d6 correct default for showing lightgun cursor (a casual player probably wants this on)
fixes c7ea4cbd0e
2023-03-30 20:33:00 -07:00
CasualPokePlayer c7ea4cbd0e Correct neutral Y position for SNES lightguns (fixes old BSNES lightguns), add in a controller button for offscreen shots for Snes9x and new BSNES, add UI option to disable drawing lightgun cursor for new BSNES 2023-03-30 20:25:26 -07:00
YoshiRulz 380e459bec
Copy from an editable template file when making a new Lua script 2023-03-30 21:43:27 +10:00
CasualPokePlayer 0a2d4405f0
Revamp Waterbox Setup (#3529)
* Waterbox setup has been revamped to use the latest llvm parts (llvm 16 for compiler_rt/libunwind/libcxx/libcxxabi).
* Clang is now possible to use, and is the preferred compiler (due to superior performance).
* Supported compilers are now clang 14/15/16, and gcc 12.
* Other core updates are mixed in.

---------

Co-authored-by: Morilli <35152647+Morilli@users.noreply.github.com>
2023-03-28 16:53:33 -07:00
YoshiRulz 44322e6a7d
Add comments to Gambatte's `ITraceable` impl. 2023-03-26 12:49:52 +10:00
YoshiRulz eee8a7e0cc
Split `Config.AVWriterResize` tuple into 2 props
fixes 32d2f2311
2023-03-26 12:36:24 +10:00
YoshiRulz 32d2f23117
Persist A/V settings to disk properly (resolves #1226) 2023-03-25 22:36:50 +10:00
YoshiRulz 10423abdf9
Invert default of `LuaWinform.BlocksInputWhenFocused` (resolves #3591)
fixes 0591d2e2d; now matches 2.8 behaviour
just no pleasing you people
2023-03-24 09:46:24 +10:00
YoshiRulz 480b51b274
Add keybind (hardcoded) for MainForm context menu 2023-03-22 13:28:39 +10:00
YoshiRulz 4368629e67
Use bulk peek in `IMemoryApi.{ReadByteRange,HashRegion}` 2023-03-20 12:33:08 +10:00
YoshiRulz a8bffab1b6
Add unit tests for `IMemoryApi.HashRegion` 2023-03-20 12:33:02 +10:00
YoshiRulz 32e36e28bb
Skip drawing RAM Watch OSD outside window bounds 2023-03-20 08:16:05 +10:00
YoshiRulz 291a14315d
Use a cache for `tastudio.onqueryitemicon` 2023-03-18 11:22:15 +10:00
YoshiRulz cddc092b96
Improve docs for some `tastudio` Lua lib callback functions 2023-03-18 10:27:37 +10:00
YoshiRulz 52fd5e41f8
Improve docs for `event.on{save,load}state` 2023-03-18 10:11:55 +10:00
YoshiRulz f28067e7fc
More improvements to mem hook docs
fixes 6b4f3355f
2023-03-18 10:00:50 +10:00
Morilli 44bf67e8a3 Add Satellaview entry to path config 2023-03-17 10:40:09 +01:00
CasualPokePlayer 3c7fd55f70 Mode2/2336 support (fixes #3387) 2023-03-16 20:17:55 -07:00
YoshiRulz 6c8d4c536a
Clear `MovieSession._queuedMovie` if rom load fails (resolves #3582)
for #3582, `MovieSession.QueuedCoreName`, which gets passed to `RomLoader`,
evaluated to a nonexistent core name and couldn't be cleared
2023-03-17 11:50:30 +10:00
YoshiRulz f565eeef74
Add test case for mem callback removing itself 2023-03-17 07:32:04 +10:00
YoshiRulz f021159931
Split `FirmwaresMenuItem_Click` 2023-03-17 06:37:38 +10:00
YoshiRulz 39fda0fa17
Change wording of missing firmware warning 2023-03-17 06:37:38 +10:00
YoshiRulz 7c3e35f3e7
Fix window title after loading rom via FW config (fixes #3581) 2023-03-17 06:37:38 +10:00
YoshiRulz eb6f2864ff
Only set `<PathMap/>` for Release builds
fixes 5dc385e22; also skip `SolutionDir` override if building projects
individually
2023-03-17 06:37:38 +10:00
YoshiRulz 6b4f3355fd
Correct mem callbacks docs (resolves #3522) 2023-03-16 14:48:17 +10:00
kalimag 565a0b9141 Implement specialized `IMemoryCallback` collection 2023-03-16 14:30:19 +10:00
kalimag 06c06dd35c Add some tests for MemoryCallbackSystem 2023-03-16 14:30:19 +10:00
YoshiRulz 5dc385e228
Set `<PathMap/>` so per-machine paths don't leak into build output 2023-03-16 12:39:26 +10:00
YoshiRulz 389fd5015f
s/ProjectDir/MSBuildProjectDirectory/ in MSBuild include files
I don't think anything was broken, this is just a precaution
2023-03-16 12:39:26 +10:00
YoshiRulz 38b5f16ccc
Refactor enable Roslyn Analyzers flag
kept the old name, but turns out `-p:RunAnalyzersDuringBuild=true` also works
...good thing the old name wasn't documented
2023-03-16 12:39:25 +10:00
YoshiRulz a8f26ccf08
Add `.bps` patch applier
currently unused, like `.ips` patch applier; will return to hook up to loading
(currently flagged as good dump if base was), write unit tests, and add a way to
save patched rom to disk
2023-03-16 03:32:46 +10:00
YoshiRulz eb13e46f45
Refactor `.ips` patch applier
`RomGame` is never initialised with a non-null `patch` so this was and is unused
2023-03-16 03:32:41 +10:00
CasualPokePlayer c2297283f4 Add in CDI support in DiscoHawk
(just needed to allow the file to be drag n' dropped)
2023-03-14 20:55:17 -07:00
CasualPokePlayer 809523d465 fix cheevo hashing for Jaguar CD (accounting for the proper multisession support chances)
add some notes to CDI, suppress one of the parsing sanity checks (not sure if it's right)
2023-03-14 20:39:46 -07:00
CasualPokePlayer d9ac4166cf .cdi support, seems to work
also expand the search for the jaguar cd header a bit, seems it can sometimes be at the second sector?
2023-03-14 05:16:12 -07:00
YoshiRulz 825c144d6a Add `--userdata` CLI flag 2023-03-14 14:51:41 +10:00
YoshiRulz cb71de8de1
Fix typo in .NET 6+ implementation of `DescribeIsNull` 2023-03-13 10:14:11 +10:00
YoshiRulz 51dab92826
Improve error message shown for malformed `.bk2`/`.tasproj`
of course I didn't test it
2023-03-13 03:23:04 +10:00
CasualPokePlayer 9d6a732cb4 Many cleanups in disc system
Multisession support! (resolves #3400)
The support is a bit lackluster given some constraints of our environment (e.g. the lack of a readable leadin entirely), but they don't matter for now
2023-03-11 01:28:32 -08:00
YoshiRulz 1ca1f4a397 Finalise sysID name and alphabetise 2023-03-11 07:29:23 +01:00
Morilli 17a098dfa3 implement SatellaviewCartridge in BSNESOptions 2023-03-11 07:29:23 +01:00
Morilli 3a6eda25dc add baseCartridge info to gamedb
+ implement baseCartridge parameter in code
2023-03-11 07:29:23 +01:00
Morilli 6329d6a6fd add all satellaview roms as separate firmware files
also implement corresponding loading code in the core
2023-03-11 07:29:23 +01:00
YoshiRulz c954a84cd8 Add Satellaview rom detection code 2023-03-11 07:29:23 +01:00
Morilli 76cfee6396 rename bs memory domains (and fix rom domain)
- also some other renames for clarity
2023-03-11 07:29:23 +01:00
Morilli c906c830dd Implement bsx + bs memory loading
connect satellaview when loading bsmemory

this makes rtc somewhat work

also mark SubBSNESv115 as BSX core
2023-03-11 07:29:23 +01:00
Morilli 8c780e42cb minor BSNESOptions cleanup 2023-03-10 02:24:46 +01:00
Morilli cb785c4cdb resolve TODO regarding bsnes settings 2023-03-10 02:17:35 +01:00
Morilli eef190d332 make bsnes settings `record` for easier comparison 2023-03-10 01:56:30 +01:00
YoshiRulz 2fca4282a9
Make `ApiContainer` props return `null` if req. services unavailable
specifically `MemoryEvents` and `MemorySaveState`
now they behave like `[OptionalApi]` rather than `[RequiredApi]`
2023-03-10 04:30:52 +10:00
YoshiRulz 6387291e37
Deprecate `IGuiApi.DrawText` in favour of new method `PixelText`
to match Lua
2023-03-10 03:55:05 +10:00
YoshiRulz 132029d18f
Sort out docs for text-drawing APIs, flipping drawText=>drawString 2023-03-10 03:54:55 +10:00
YoshiRulz 16afcffe81
Clean up how SGB/SNES menus for BSNES are handled
makes Satellaview a 0 LOC change, and deleting old BSNES will be easier too
2023-03-09 23:35:26 +10:00
YoshiRulz 1a30f6551e
Use LuaPictureBox' custom resize in all cases 2023-02-26 14:35:35 +10:00
CasualPokePlayer 2c3fb68776 fix PictureBox when width or height is null 2023-02-24 13:29:18 -08:00
Morilli b45668ecea Parse RTC in DsmImport
see #3555
2023-02-21 18:33:46 +01:00
CasualPokePlayer 5804ff04e7 Fix memory handling for DSi achievements 2023-02-20 12:10:58 -08:00
CasualPokePlayer 27eef71085 Fix some more edge cases against PSX RetroAchievements hashing (and do it a bit nicer)
Update rcheevos, and with that add in the new DSi console ID
Experimentally revamp the build system, I'm looking into cmake here and it seems to do a great job. The builds committed here were built with clang-cl 15.0.1 and clang 15.0.7 (for Windows and Linux respectively). gcc/clang with msys2 still works fine. gcc on Linux should still work fine. MSVC (cl) itself even works (although as a note, it doesn't work with lto (/GL) due to the force everything exported flag I set). The old Makefile is still kept for future reference.
2023-02-19 23:42:33 -08:00
CasualPokePlayer 7b4bd52150 fix edge case with PSX hashing with RetroAchievements 2023-02-15 16:23:39 -08:00
Morilli fcbc44b64f Resolve part of #3506 2023-02-12 12:30:14 +01:00
vadosnaprimer a2ff685fc1 release the mame core
I asked others and nobody minds. it's not like we're releasing a raw core that has accuracy or integration problems. it mostly works, and it's just modern mame with its current level of accuracy. if integration needs further tweaks to support more games, they will duly arrive while people use it for games that already work.

tasvideos used to only accept hawk submissions for cores marked as released in the code, which usually means the core author (or porter) considers it ready for business. I'm the original porter, and tasvideos staff, and I consider it generally ready. again, the other porter (CPP) didn't seem to mind.
2023-02-12 10:37:20 +03:00
YoshiRulz a137cc406b
Allow `EmuClientApi.SpeedMode(6400)` (to match GUI; Lua max was 6399)
logic broken since introduction in 858f133f9, though the limit wasn't 6400% at
the time, that was changed in 5f9757d7d
2023-02-10 13:53:27 +10:00
CasualPokePlayer 2350dddb69 fix pause at end of movie when playing a tasproj without tastudio
old commits seem to suggest the IsPlayingOrFinished special logic was only intended for HandleFrameLoopForRecordMode. doing it otherwise causes issues with other end movie actions (e.g. if at pause at end of movie, it will just spam pause every time you unpause the movie). when in tastudio `Settings.MovieEndAction == MovieEndAction.Record` is always true, so this only affects playing tasprojs outside of tastudio
2023-02-09 12:26:10 -08:00
CasualPokePlayer b48649a91b fix Lower Is Better checkmark with RCheevosLeaderboardForm 2023-02-09 11:52:04 -08:00
CasualPokePlayer 8c2751bb58 fix PCECD and PCFX hashing for retroachievements 2023-02-09 10:26:25 -08:00
CasualPokePlayer a61be6ba2b fix incorrect memory being used with a2600 and retroachievements 2023-02-09 08:25:58 -08:00
YoshiRulz b14a741ffe
Merge `Where` calls
fixes 0d02d5c49 and e7884f679
2023-02-09 00:47:49 +10:00
YoshiRulz eafb1fdcf5
Clean up Windows version comparison
fixes 1b8158f4c
2023-02-09 00:47:46 +10:00
zeromus 6ea9e37e33 NES PPU Viewer - SpriteViewer also needed to be drawn without getting blurred 2023-02-08 05:09:33 -05:00
zeromus 6fe91ae56c Nes PPU Viewer - undo part of ac20835172 which made ctrl+c no longer work on pattern viewer 2023-02-08 05:07:26 -05:00
zeromus 8b38237948 fix jacked up blur in patternviewer 2023-02-08 04:59:58 -05:00
zeromus 63310fcf3d NES PPU viewer - size of palettes box had got messed up by my last commit. what's going on? 2023-02-08 04:45:30 -05:00
zeromus b7b60ae7b4 NES PPU viewer: fix calculations of hovered sprites from mouse coordinates. they were pretty crashy before 2023-02-08 01:32:24 -05:00
zeromus cb162f12d6 NES PPU viewer: fix too-small sprites window which hid a bunch of the sprites 2023-02-08 01:25:49 -05:00
zeromus 1b8158f4c2 skip this stupid administrator check on old windows versions. windows isn't capable of being useful for non-administrators until windows 10. 2023-02-08 01:07:41 -05:00
zeromus 4ba7b68e66 add missing using namespace NDS to fix building 2023-02-08 00:56:32 -05:00
YoshiRulz 67466be2f4
Have TAS profile also enable NDS BIOS 2023-02-08 10:08:19 +10:00
YoshiRulz 1ca610b424
Set default `Form.Icon` to corphawk
not sure about this, and I think it also affects ext. tools
2023-02-08 07:15:25 +10:00
YoshiRulz e7884f6796
Hide debug tools from Tool Box and add ext. tools 2023-02-08 07:15:24 +10:00
YoshiRulz 8b7cba96bb
Use a single-source-of-truth for tools' icons in menus and Tool Box
reverts 733b6c49b
some more `[SpecializedTool]`s have icons now
2023-02-08 07:15:24 +10:00
YoshiRulz 0d02d5c498
Refactor `ToolBox.SetTools` 2023-02-08 07:15:24 +10:00
YoshiRulz b93eb948fd
Unindent `MainForm.DisplayDefaultCoreMenu` 2023-02-08 07:15:24 +10:00
YoshiRulz 15eed689d0
Misc. refactors in `ExternalToolManager` 2023-02-08 07:15:24 +10:00
YoshiRulz a86860faaa
Fix `--open-ext-tool-dll`
fixes 4566b744d
2023-02-08 07:15:23 +10:00
YoshiRulz 3c3ab6578e
Use system's canonical framerate for rewind duration estimate 2023-02-05 21:00:04 +10:00
YoshiRulz f473db56c3
Fix NaN propagation in RewindConfig 2023-02-05 20:56:22 +10:00
CasualPokePlayer b1e8d93f5f remove unused using from last commit
need to check what's going to be committed, the auto-using thing keeps tripping me up
2023-02-01 21:27:49 -08:00
CasualPokePlayer 46a086ed32 fix b109dc8605 2023-02-01 21:26:44 -08:00
YoshiRulz b109dc8605
Mute audio when opening modal dialogs (see #3545) 2023-02-02 05:41:44 +10:00
YoshiRulz 26991944ee
Fix `<NoWarn/>` overwriting instead of appending 2023-02-02 00:07:04 +10:00
YoshiRulz d8d9abeacd
Update OpenTK 2023-02-02 00:07:04 +10:00
YoshiRulz e7d349f48d
Update Windows version check to reflect 8.1 EOL 2023-02-02 00:07:04 +10:00
CasualPokePlayer cf0ce0f5bb fix GC killing rcheevo callbacks 2023-01-27 02:47:05 -08:00
CasualPokePlayer c4f2bed9fd sledgehammer fix any remaining issues with RAIntegration 2023-01-26 08:00:43 -08:00
CasualPokePlayer e67e646ca5 fix deadlock when loading state with hotkeys and RAIntegration is active
hotkeys don't go through messages so unlike other methods of loading a state this caused a deadlock (load state implies memory peeking to restore state)
2023-01-26 07:12:54 -08:00
CasualPokePlayer e8dd2e94f2 Fix crashes when using menu item for save/load quicksave
fixes 22ba0d5c25
2023-01-26 05:49:52 -08:00
CasualPokePlayer 66282a25aa fix a NullReferenceException this time...
this thing is getting annoying now
2023-01-26 04:32:53 -08:00
CasualPokePlayer 0170d8f0f0 resolve ObjectDisposedException
fixes 713944724d
2023-01-26 01:24:34 -08:00
CasualPokePlayer 713944724d fix deadlocks in RAIntegration for real this time (i hate this hack)
fixes f8a5adecb5
2023-01-25 23:36:46 -08:00
CasualPokePlayer 03077daf71 fix a crash when loading a quicksave right after shutting down retroachievements 2023-01-25 22:43:57 -08:00
CasualPokePlayer f8a5adecb5 fix possible deadlocks with RAIntegration due to dumb threading bs, cleanup some of this code
also make sure to reboot core when starting up RetroAchievements with RAIntegration active (RAIntegration doesn't do this itself it seems)
2023-01-25 22:28:26 -08:00
YoshiRulz 95001d0baa
Hack to fix Nymashock analog stick range (see #3528) 2023-01-26 14:57:57 +10:00
YoshiRulz c66d0c746e
Document `IMemoryDomains` invariants 2023-01-25 02:04:10 +10:00
YoshiRulz 9e8b0c604d
Add debugging helper `DescribeIsNull` 2023-01-25 01:14:50 +10:00
kalimag b174c346d4 Hex editor: unset ROM domain when loading MAME ROM
Previously, last non-MAME ROM would still appear under "File on Disk"
2023-01-20 09:29:31 +10:00
kalimag b2ed03c90d Fix NRE in `HexEditor` domain selection for MAME
Fix NRE when MAME ROM was loaded without Open Advanced
2023-01-20 09:29:31 +10:00
YoshiRulz 15056f11f2
Fix typo (resolves #3520)
fixes 007d862c5
2023-01-15 05:38:03 +10:00
adelikat 8c32157547 hotkey for toggling on screen messages 2023-01-14 12:00:37 -06:00
YoshiRulz 566d47e263
Several changes to the About dialog
- s/BizHawk/EmuHawk/
- s/multi-platform/multi-system/ because, while the former is technically true,
it's very much a Windows app, and the latter is what was intended anyway
- replaced logo w/ a nice upscale courtesy of @DrD2k9
- added VCS branch to commit link
- changed window title from VCS info to "About EmuHawk"
- added build config after release version
2023-01-14 14:31:41 +10:00
kalimag abee97b449 Remove pixels array from `DisplaySurface`; faster clearing 2023-01-08 08:53:45 +10:00
YoshiRulz bc823f4795
Clear props of type `ApiContainer` when clearing injected API props 2023-01-08 08:27:31 +10:00
YoshiRulz 3c00c24fcd
Fix `ApiInjector` trying to set get-only props of type `ApiContainer` 2023-01-08 08:26:27 +10:00
YoshiRulz 16ee704332
Deduplicate `MemoryDomainDelegateSysBusNES` 2023-01-08 07:54:20 +10:00
CasualPokePlayer 0bd2a1d89b
Resolve bigEndian nonsense for MemoryDomainDelegateSysBusNES too
TODO: This is just MemoryDomainDelegate but with a SendCheatToCore delegate allowed to be added, surely we could just add this to the existing MemoryDomainDelegate? Or better yet MemoryDomainDelegateSysBusNES could just inherit MemoryDomainDelegate if this wants to be separated (and reduce all this code duplication)
2023-01-06 10:10:14 -08:00
CasualPokePlayer 2a7cbda8c5
Correctly pass in bigEndian for MemoryDomainDelegate's BulkPeekUshort/BulkPeekUint, fixes #3516 2023-01-06 10:02:28 -08:00
CasualPokePlayer a896471164
fix MAME memory domains 2023-01-05 18:47:49 -08:00
kalimag 3f4aee0154
Return success bool from `OpenRom` APIs (squashed PR #3514)
* Return success bool from `OpenRom` APIs

* Finish propagating, update docs for other recently changed methods too

Co-authored-by: YoshiRulz <OSSYoshiRulz@gmail.com>
2023-01-06 03:50:13 +10:00
YoshiRulz 0591d2e2d2
Pass through input/hotkeys while Lua form is focused
to restore previous behaviour, call `forms.setproperty(form_handle,
"BlocksInputWhenFocused", true);`
2023-01-05 02:09:49 +10:00
YoshiRulz af9f5b9b9c
Add some sort of documentation for B/V gamedb flags 2023-01-05 00:41:25 +10:00
YoshiRulz 699ef428bf
Fix `mainmemory` lib keeping reference to unloaded core's memdomain 2023-01-03 23:46:02 +10:00
YoshiRulz 5827cbd829
`Trim()` when copying Log Window selection to clipboard
see e269bfd49
2023-01-03 23:26:36 +10:00
YoshiRulz e7d95aa07d
Disable Lua tests in CI 2023-01-03 07:31:27 +10:00
YoshiRulz ec6fe5fcf1
Change loadstate methods to return a bool indicating success 2023-01-03 06:49:29 +10:00
YoshiRulz 250b839e2c
Extract method from `LoadBranchToolStripMenuItem_Click` 2023-01-03 06:49:29 +10:00
YoshiRulz 007d862c58
Finish renaming quicksave slot 0 to 10 (resolves #3112) 2023-01-03 06:49:28 +10:00
YoshiRulz 7f33a8836d
Invert some conditionals in `MainForm` to reduce indent level 2023-01-03 06:49:28 +10:00
YoshiRulz fcf7ac1fab
Change first param of `{Save,Load}QuickSave` from string to int
also swapped bool params of `SaveQuickSave`
2023-01-03 06:49:28 +10:00
YoshiRulz 22ba0d5c25
Dedup click handlers for `File` > `Save State` and `Load State`
`File` > `Save Slot` already did this
2023-01-03 06:49:28 +10:00
CasualPokePlayer 4b30cab993
Check the correct integer type for tastudio.setplayback
New lua actually has integers so this is a long instead of a double
2022-12-31 18:10:36 -08:00
CasualPokePlayer 05ff3ab40c merge some mGBA upstream commits, partially revert c891cc2cb5 (upstream commits makes our changes not really needed) 2022-12-22 20:26:11 -08:00
CasualPokePlayer 00d450075e oops forgot a colon here 2022-12-21 00:43:52 -08:00
CasualPokePlayer c7c5ed229d add pc2 extension for wonderswan
these are pocket challenge v2 roms, which is some handheld system which is actually just a wonderswan inside so these roms work anyways with cygne
2022-12-21 00:41:42 -08:00
Morilli 603530d540 set gcAllowVeryLargeObjects to allow 2GB+ arrays 2022-12-21 07:43:34 +01:00
Morilli 79857a3b71 Revert "make a new "FixedGrowthList" and use it for the StringLogs"
This reverts commit da5fae0b01.
2022-12-21 07:42:31 +01:00
nattthebear 66c19cfcb2 Support marshalling arrays of length 0 through BizInvoker
Such arrays will be marshalled with valid and unique pointers that can be compared but not read from or written to.
2022-12-20 18:04:41 -05:00
CasualPokePlayer 5b0fe947df fix #3498 2022-12-20 10:40:03 -08:00
YoshiRulz 6678fb4296
More cleanup of switch in `RetroAchievements.SystemIdToConsoleId` 2022-12-20 18:58:17 +10:00
YoshiRulz 7703ee5f37
Refactor `IGameboyCommon.IsCGBMode` 2022-12-20 18:58:17 +10:00
YoshiRulz a54c94230f
Restore system menu behaviour re: SGB
fixes 81fe56fa6
2022-12-20 18:58:12 +10:00
Morilli 81fe56fa6e provide correct sysid in BsnesCore 2022-12-20 04:22:23 +01:00
YoshiRulz aa0e2d6a5f
Use new CartRAM domain name in GBHawk's CDL impl. (fixes #3497)
fixes 7e00b7892
2022-12-19 13:20:37 +10:00
CasualPokePlayer cee263e272 oops didn't mean to checkin this experiment (it doesn't do anything actually) 2022-12-17 21:53:47 -08:00
CasualPokePlayer 339915c013 check-in NLua to main repo
combine NLua with KeraLua (KeraLua is "gone" now I guess)
make it use the BizInvoker (so now it can properly handle the liblua5.4.so and lua54.dll names differing), also delete the liblua54.so.
minor speedup when creating a new empty table
make lua default to UTF8 internally, so we don't need to manually change the state's encoding
2022-12-17 21:51:10 -08:00
CasualPokePlayer a1da5753ee check-in NLua to main repo
combine NLua with KeraLua (KeraLua is "gone" now I guess)
make it use the BizInvoker (so now it can properly handle the liblua5.4.so and lua54.dll names differing), also delete the liblua54.so.
minor speedup when creating a new empty table
make lua default to UTF8 internally, so we don't need to manually change the state's encoding
2022-12-17 21:50:56 -08:00
Morilli 55fdcbb3d1 Don't set modifiers for key release events
this fixes a bug in 1df6ce4e38, where an incorrect modifier state could be set, causing the release event to not actually release the key. I also don't see a reason to not just not set modifiers.

For example: "Hold Tab", "Hold Shift", "Release Tab" would send a "Release:Shift+Tab" event which failed to release Tab, even though that key was initially pressed without Shift.

So, instead of trying to match the right modifiers and keys just send the released key without modifier state and let the Receive() function do the work.
2022-12-18 06:03:55 +01:00
YoshiRulz 8db15d6951
Show warning dialog when running as Superuser/Administrator 2022-12-18 12:21:43 +10:00
YoshiRulz 767e30eee5
Also rename bundled CPC firmware files (see #3494)
fixes 5be8b0aab
2022-12-18 12:02:23 +10:00
CasualPokePlayer 8d5f7b5478 make selecting user shaders not crash with the default empty string path
Path.GetDirectoryName throws if it is handed an empty string apparently
2022-12-17 12:16:03 -08:00
YoshiRulz a680739c6e
Rename bundled ZX Spectrum firmware file (resolves #3494)
fixes 5be8b0aab
2022-12-17 22:47:57 +10:00
CasualPokePlayer 58beef8a46 remove speex use in melonDS (see 5f0e6a2242 for unmanaged side changes) 2022-12-16 23:04:35 -08:00
CasualPokePlayer 5e9e9ac289 remove libspeexdsp use in old bsnes core 2022-12-16 20:45:25 -08:00
YoshiRulz c794d90878
Revert switch to system-wide Lua install on Linux
reverts ab355d469 and 25795d237
2022-12-17 13:35:14 +10:00
CasualPokePlayer 25795d2372 remove GetErrorMessage call for Linux dep checks 2022-12-16 15:26:11 -08:00
CasualPokePlayer ab355d4693 check some system lib deps on Linux and force user to provide their own liblua54 from package managers 2022-12-16 15:03:39 -08:00
CasualPokePlayer 767cc9059d Improve handling of RA http requests, add some handling in case RA sound files are missing. Normally this shouldn't be needed as docs specify if the wav file fails to load it plays the default beep sound, except actually it just throws in practice???
The 2.9 rcs apparently have the "overlay" folder missing, so the sound files aren't present. I'm assuming there's some issue with build scripts there for releases...
2022-12-15 23:45:29 -08:00
CasualPokePlayer f3ee3e7956 mGBA update, various cleanups and some reorg 2022-12-15 01:00:36 -08:00
adelikat f6503adfb8 Update virtualpads immediate when the movie status changes, huge improvement when using tastudio and virtualpad together as the record checkbox toggle now changes the readonly status of the pad 2022-12-13 08:39:29 +10:00
CasualPokePlayer 27f6800d45 fix #3489 (InitializeWork is called by itself for each gamedb file #include'd, so the event would have been set once the first gamedb file is loaded, oops), do some other cleanup here 2022-12-10 23:42:08 -08:00
CasualPokePlayer b3c7f0fa48 IPlatformLuaLibEnv -> ILuaLibraries / Win32LuaLibraries -> LuaLibraries, cleanup usage of it, fix doc error in client.gettool 2022-12-10 21:46:22 -08:00
YoshiRulz f101cb5a54
Additional corrections to newly-added Lua documentation
fixes 49cd836e1, c7781d1c1
2022-12-11 13:35:29 +10:00
YoshiRulz cbb335fec2
Fix Lua `require` not looking in Lua dir on Linux
see #3485
thanks to @CasualPokePlayer for research and initial implementation
2022-12-11 13:16:07 +10:00
CasualPokePlayer 9e4836d300 libretro handling cleanup, reorg some of this, fix some input cases, better domain names
funsie found in this cleanup: can't use `in` params with the BizInvoker as it doesn't like the read only semantics (results in some exception in CreateType)
2022-12-10 04:45:00 -08:00
CasualPokePlayer 64d693e63f call retro_unload_game before retro_deinit (libretro api specifies retro_unload_game be called before retro_deinit, in practice cores don't really care but best fix this) 2022-12-08 23:18:37 -08:00
CasualPokePlayer 29443dae49 fix #3484 2022-12-08 14:26:23 -08:00
YoshiRulz c4f4c793da
Remove unused `IPlatformLuaLibEnv` implementation 2022-12-09 05:41:49 +10:00
YoshiRulz 5197c36a5d
Remove `[Lua*StringParam]` as they're no longer relevant
fixes 45fbdb484
2022-12-09 05:40:31 +10:00
YoshiRulz 5c0143d6f6
Minor corrections to newly-added Lua documentation
fixes 1452f831a, 82c3b471a, b687dea1b, 49cd836e1
2022-12-09 05:28:36 +10:00
CasualPokePlayer 49cd836e18 log warning when using the deprecated lua bit functions 2022-12-08 04:26:54 -08:00
CasualPokePlayer 56d66ca555 add reset support to libretro, resolves #3482 2022-12-07 19:54:59 -08:00
YoshiRulz 4caa99afe3
Remove Lua in Mono warning as it's no longer relevant
fixes 45fbdb484
2022-12-07 18:46:25 +10:00
kalimag 01ab9416b5 Make script paths in .luases relative to .luases path
Restore behavior before 99dc0e03df
2022-12-07 18:24:21 +10:00
YoshiRulz df4df517b8 Add `IMovieApi.PlayFromStart`/`movie.play_from_start` (resolves #384) 2022-12-07 18:16:13 +10:00
YoshiRulz 7fdc3f992d Propagate success through to caller for movie load/restart 2022-12-07 18:16:13 +10:00
YoshiRulz 0076c8802b Add `saveChanges` parameter to `IMovieApi.Stop`/`movie.stop` 2022-12-07 18:16:13 +10:00
YoshiRulz e0a7a39b0d Have `IMovieApi.Stop` implementation use `MainForm.StopMovie` 2022-12-07 18:16:13 +10:00
kalimag 596e8d9198 Call `onexit` and cleanup when removing lua script 2022-12-07 18:15:31 +10:00
kalimag 50fc7e28da Make "Stop all scripts" behave the same as toggling them off 2022-12-07 18:15:31 +10:00
kalimag 817b258a79 Remove relative path manipulation in `LuaConsole` 2022-12-07 18:15:31 +10:00
kalimag f625771cd0 Don't create FileSystemWatcher for missing directories 2022-12-07 18:15:31 +10:00
kalimag cf2b83b102 Disable lua script if loading fails 2022-12-07 18:15:31 +10:00
kalimag bd53807b0f Store `LuaFile` `FileSystemWatcher` in dictionary
Avoid path string comparisons, `FileSystemWatcher` events may format relative paths differently
2022-12-07 18:15:31 +10:00
kalimag 6aa7c48402 Update Lua registered functions window after restart
Make registered functions window show functions for new LuaImp after core restart/reopening the Lua console
2022-12-07 18:15:31 +10:00
kalimag ee66faba0b Clean up old LuaImp before creating new one
Prevents memory/resource leak

Causes open forms to be closed on core restart
2022-12-07 18:15:31 +10:00
kalimag 3a70fb65f8 Refactor disabling Lua script into separate method 2022-12-07 18:15:31 +10:00
kalimag 7c7ac64ae6 Stop discarding Lua session save directory
Previously any path would into ".\foo.luases" and be saved in exe dir
2022-12-07 18:15:31 +10:00
kalimag 9ee788195a Improve Lua `FileSystemWatcher` thread safety
Make FSW invoke the entire event handler on main thread.

Avoids theoretical race condition and thread safety issues with the linq query.
2022-12-07 18:15:31 +10:00
kalimag 733a8bee88 Dispose FileSystemWatchers in LuaConsole 2022-12-07 18:15:31 +10:00
kalimag 28d6415190 Remove running scripts before loading session
Clean up scripts instead of just clearing script list
2022-12-07 18:15:31 +10:00
kalimag cc10de4033 Refactor removing Lua scripts into separate method 2022-12-07 18:15:31 +10:00
kalimag 564a1e4a67 Remove obsolete `LuaConsole.RunLuaScripts`
Method is mostly a duplicate of `EnableLuaFile`, only called when loading a session or an already loaded script.

In either case it didn't actually start the scripts due to an inverted condition, and would stop running scripts without doing the required cleanup.
2022-12-07 18:15:31 +10:00
kalimag 5d143ca879 Properly start scripts after loading Lua session
Previously, scripts would display as enabled but not actually run until toggled off and on.
2022-12-07 18:15:31 +10:00
kalimag 0effd435f6 Fix issues when opening same Lua script multiple times 2022-12-07 18:15:31 +10:00
kalimag 14e713837b Change remaining `Config.DisableLuaScriptsOnLoad` refs to Settings
Resolve inconsistent use of duplicate property on `Config` and `LuaConsoleSettings`, finishes partial refactoring from 324a50a

This will effectively reset this setting to default in existing configs.
2022-12-07 18:15:31 +10:00
YoshiRulz a8e0192281
Use FLPs so UI scale doesn't break Record Movie dialog (see #2605)
disables resizing the dialog; default is big enough and the `TextBox`es can
scroll
2022-12-07 15:43:25 +10:00
YoshiRulz 632f063073
Cleanup `RecordMovie` ctor 2022-12-07 15:43:24 +10:00
YoshiRulz 400b1b589b
Inline `RecordMovie.InitializeComponent` (Designer file) 2022-12-07 15:43:21 +10:00
YoshiRulz 102874e480
Fix N64 header detection being swapped (fixes #3477)
fixes abeaa2a10
how ironic
2022-12-07 14:34:52 +10:00
YoshiRulz 62f6f3b471
Fix Win32LuaLibraries init'ing incorrectly on `DeveloperBuild = false` 2022-12-07 14:27:19 +10:00
YoshiRulz def5df44fa
Fix double call to `UIHelper.ScaleX` in `ControllerConfig` (see #2605)
fixes 93c47b87b
2022-12-07 05:29:27 +10:00
Morilli 5e6c4a2bbd fix justifier controller never working oops 2022-12-06 19:42:30 +01:00
Morilli 96cc3f8745 BSNESv115: implement an extended gamepad controller with 4 extra buttons
this is a breaking change for existing movies, but only when a non-gamepad controller was used, which is rare
2022-12-06 19:21:08 +01:00
CasualPokePlayer 339994c5a7 change these to using var 2022-12-06 09:46:12 -08:00
CasualPokePlayer b687dea1b0 change every IntPtr<->int cast to IntPtr<->long. we got 64 bit integers with lua now, and a pointer is 64 bits, so might avoid some dumb bug due to truncations and some ungodly amount of ram being used
TODO: see if we can skip this cast nonsense. the lua tests indicate IntPtr should pass through fine, being considered "userdata", probably better so the user can't just pass raw numbers for the handle.
2022-12-06 04:53:35 -08:00
CasualPokePlayer bc79664461 fix implicit lua number to .net conversion
fix .net exceptions not halting the running script
fix inconsistency with stdout and lua console printing errors, both should end in a newline now
print the inner exception of a lua exception (i.e. the .net extension) if possible
2022-12-06 02:52:57 -08:00
CasualPokePlayer eb00019c86 fix passing numbers for string args in .net lua functions (old engine had this behavior, granted "bad user" if they relied on this), add appropriate test
fix passing sbyte/char as args, add appropriate tests
cleanup the lua auto unlock hack, using a nice ref struct + dispose to handle it
2022-12-05 23:21:23 -08:00
CasualPokePlayer 920682688b deprecate lua bit functions which have direct operator counterparts in new lua 2022-12-05 18:23:11 -08:00
CasualPokePlayer dcd570bf87 fix mainmemory.write_bytes_as_dict 2022-12-05 16:46:22 -08:00
Morilli 4a49fc174b Improve LsmvImport in numerous ways
- previously, every second frame was empty (lol), since 2016 i believe
- now imports as (sub)bsnes115 movie instead of bsnes, allowing to import subframe inputs and delayed resets
- imports controller types correct(er)ly
2022-12-05 16:28:22 +01:00
Morilli 10ba45d462 BSNESv115+: actually provide IBoardInfo properly 2022-12-04 22:48:29 +01:00
YoshiRulz abeaa2a106
Be less lazy about N64 header detection in byteswapper
fixes 82c3b471a, 9660c16a0
2022-12-05 04:54:19 +10:00
CasualPokePlayer 9660c16a0a fix N64 roms coming through multidisk bundler in ares 2022-12-04 01:35:58 -08:00
CasualPokePlayer 3dd36f5f07 revert the explicit try/finally use for PeekByte/PokeByte monitor domain methods, testing seems to show the ref struct use makes EnterExit allocation (now forced to the stack) a non-issue performance wise 2022-12-03 18:30:09 -08:00
CasualPokePlayer f01463e2b3 Convert EnterExitWrapper to a readonly ref struct, this should be a speedup in all cases. Will need to experiment to see if this mean the try/finally from #3296 can be avoided 2022-12-03 17:46:49 -08:00
YoshiRulz d508b734d6
Fix `MemoryApi.{Read,Write}ByteRange` edge cases 2022-12-04 09:23:28 +10:00
YoshiRulz af44a85cfd
Add unit tests for `IMemoryApi.{Read,Write}ByteRange` 2022-12-04 09:23:28 +10:00
YoshiRulz dc4efc3644
Fix typos and whitespace in `MemoryApi.cs` 2022-12-04 09:23:27 +10:00
YoshiRulz 1bdff05442
Use read-only collection types in `IMemoryApi` 2022-12-04 09:23:25 +10:00
YoshiRulz cba206efec
Add `IUserDataApi.Keys`/`userdata.get_keys` 2022-12-04 04:06:58 +10:00
YoshiRulz c2d5a9c931 Banish empty conditional blocks 2022-12-04 02:11:41 +10:00
YoshiRulz 84d2866f53
Clean up usage of `LuaFile.Enabled`/`Paused` 2022-12-04 01:43:02 +10:00
CasualPokePlayer f798021bba CloseRom acts like rebooting the core, so make it just reset Lua libs (more properly fixes #3226 without any yield nonsense)
Slight revert of 2efae13af4 (still want to set running scripts as it's used later)
Fix detaching registered functions (old logic was broken, Stop would null out the LuaRef used for creating the new dummy thread for the detached function. best solution i've come up with is to simply pass a callback over for creating the thread, nicely encapsulating that functionality)
Various cleanups, don't need VS complaining about old pattern matching code here anymore...
2022-12-03 04:57:58 -08:00
CasualPokePlayer 15b2264cb4 Use LuaThread Yield here instead of directly using LuaState's 2022-12-02 19:45:29 -08:00
CasualPokePlayer 51f01efdc4 Properly handle errors when running a lua script, using Resume/Yield methods added to the LuaThread class (see f904fa0d53) 2022-12-02 14:44:05 -08:00
Morilli ae11dcc6af replace default bsnes with bsnes115 2022-12-02 20:21:21 +01:00
YoshiRulz 6174398fb4
Also reset padding when removing last Lua script (resolves #1509) 2022-12-03 01:06:06 +10:00
YoshiRulz a9756b60a2
Clear OSD + surfaces when removing a Lua script (resolves #3014)
they were already being cleared when closing the Lua Console
note the "Erase Stale/Stuck Lua Drawing Layers" button does not clear OSD,
leaving that as it is for now
2022-12-03 01:02:26 +10:00
CasualPokePlayer 2efae13af4 prevent some NREs occurring with the new Lua stuff 2022-12-01 14:59:36 -08:00
YoshiRulz 999e487557
Add `bizstring.pad_{start,end}` helpers 2022-12-02 06:18:32 +10:00
YoshiRulz ca72f113df
Rename `event.onmemory*`, phase 1 (resolves #759) 2022-12-02 05:55:42 +10:00
YoshiRulz 6381448472
decimal is not floating-point
fixes fdbb34dff
2022-12-02 04:27:29 +10:00
YoshiRulz 5603e5ac01
Reorder items in Tools menu 2022-12-02 04:24:24 +10:00
YoshiRulz 3dcc3ff89f
Improve handling of exceptions thrown in `Form.Load` handlers
obviously only benefits forms inheriting `FormBase`
2022-12-02 03:48:36 +10:00
CasualPokePlayer 9393e1b764
Fix #3417 and improve handling of `default.tasproj` (squashed PR #3462)
* Fix #3417 and improve handling of default.tasproj

* expose SetMovieController in the MovieSession interface (please don't rely on it anywhere else)

* don't use this explicit public in the interface

(is this mentioned anywhere? i assume this is proper style)

* use this helper function
2022-12-02 03:44:56 +10:00
feos 10a38270e5
forgot a char 2022-12-01 19:12:45 +03:00
feos bace52c4f8 fix #2119 2022-12-01 19:10:57 +03:00
dependabot[bot] 47c494a5a6
Bump System.Drawing.Common in main solution (#3464)
Bumps [System.Drawing.Common](https://github.com/dotnet/runtime) from 5.0.2 to 5.0.3.
- [Release notes](https://github.com/dotnet/runtime/releases)
- [Commits](https://github.com/dotnet/runtime/compare/v5.0.2...v5.0.3)

---
updated-dependencies:
- dependency-name: System.Drawing.Common
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-02 01:22:46 +10:00
CasualPokePlayer 45fbdb4844
Move to NLua/KeraLua/Lua5.4 (#3361) 2022-12-01 00:51:02 -08:00
CasualPokePlayer fdbb34dff6
Lua tests (#3373) 2022-11-30 23:55:24 -08:00
CasualPokePlayer 92c1cdff22
RetroAchievements Support (#3407) 2022-11-30 23:51:17 -08:00
CasualPokePlayer eb1cef1ffc update mame to 0.250 2022-11-30 20:22:04 -08:00
CasualPokePlayer 8667dd9ee7 c# to previous commit 2022-11-27 23:29:54 -08:00
CasualPokePlayer 6baee38717 add n64 to multidisk bundler list 2022-11-27 05:51:47 -08:00
CasualPokePlayer 9420c8b21c merge latest ares, hook up its new N64DD support, make ares use AxisContraint (see #3453), some other cleanups here 2022-11-27 05:44:00 -08:00
CasualPokePlayer c23b063733 basic virtualpad + default controls for TIC80, mark it as released 2022-11-26 19:54:45 -08:00
YoshiRulz c49a8d338c
Prefix `socketServerScreenShot` blob with length too (resolves #3461)
fixes b1602dae0
2022-11-26 18:42:10 +10:00
YoshiRulz b8182f9149
Extract `ConcatArray` helper 2022-11-26 18:42:05 +10:00
Moritz Bender 1df6ce4e38
Fix key release events with modifiers not getting handled correctly (#3402) 2022-11-25 11:00:44 +01:00
CasualPokePlayer bae71326bf Fix hex editor for MAME when Open Advanced is not used 2022-11-25 01:31:02 -08:00
YoshiRulz 9a0403617b
Clean up SHA1 2022-11-24 20:15:35 +10:00
YoshiRulz 4566b744d9
Remember trusted ext. tools 2022-11-24 20:06:27 +10:00
YoshiRulz f9ac3c4b32
Clean up `MainForm.ExternalToolMenuItem_DropDownOpening` 2022-11-24 20:06:20 +10:00
adelikat e269bfd49f Log window - when copying pasting "MD5:2345" and Sha1, strip the md5 and sha1 out. I just want the number if I'm copying pasting the single line. If someone finds this objectionable, feel free to revert, but this savesme a lot of time 2022-11-23 10:54:59 -06:00
adelikat 392d126173 remove an unused method 2022-11-23 10:11:45 -06:00
YoshiRulz 683aa263a0
Include `ControllerDefinition._orderedControls` in clone ctor
I don't think this is used, but as the caching was new in 2.8, going to include
this just in case
2022-11-23 15:35:45 +10:00
YoshiRulz 52acda9a02
Re-add an assignment in `InputManager.SyncControls` (fixes #3458)
partially reverts 781c152bf
also removed now-unused method `Controller.ForceType`
2022-11-23 15:29:02 +10:00
CasualPokePlayer 3f352792a6 remove unused using from experiments in previous commit 2022-11-22 09:18:51 -08:00
CasualPokePlayer da5fae0b01 make a new "FixedGrowthList" and use it for the StringLogs
this is mostly to workaround OOM issues with VERY large movies (>134217728 frames).
so large just the list of string references is "too big" and exceeds the .net 2GB limit.
even the on disk method fails here, as the offsets list (note, long and reference are the same size) becomes too big
this probably gives a bit of speedup for "normal" movies, as the generous 16MB growth amount would likely be plenty for the movie, although i haven't test this much
2022-11-22 09:10:19 -08:00
YoshiRulz b967e6028d
Fix inconsistent application of colours from GTK theme, if available
still no idea why I can set dark theme on Ubuntu but not Manjaro, but now menus
won't use a white-to-black gradient with white text
2022-11-23 02:51:54 +10:00
Morilli 589823d009 GPGX: add setting to disable per-line sprite limit
- resolves #3440
- includes manually cherry-picked e0ef0902e96bd9d71cb49c64505e755007e7452c
2022-11-22 14:44:39 +01:00
CasualPokePlayer 248e87b6d1 try to load a different core if an autodetected mame rom ends up failing to load 2022-11-21 18:28:56 -08:00
CasualPokePlayer 51826c4c17
Fix wrong MBC5 mapper being given a battery
0x1A is MBC5+RAM, 0x1B is MBC5+RAM+BATTERY
2022-11-19 20:44:55 -08:00
Morilli 0cb63e8d6a BSNESv115+: Implement overscan and aspect ratio correction settings 2022-11-18 13:08:27 +01:00
CasualPokePlayer 0bd182e6cc properly handle "NO GOOD DUMP KNOWN" mame rom hashes
(note, these roms are not actually in the romset, so the singular hash in movies doesn't have to be affected here)
2022-11-17 17:45:49 -08:00
CasualPokePlayer d507246033 c# side for previous commit 2022-11-16 21:33:55 -08:00
CasualPokePlayer d0266816a5 Fix #3448. Support MAME 7z romsets 2022-11-16 17:32:20 -08:00
CasualPokePlayer 4479fec74d Add in the actual c# code for 5ae4470466
Apparently forgot to actually add this in for the commit >:
2022-11-16 15:35:37 -08:00
CasualPokePlayer 62c3b4b8e3
Use a small dll for handling the msabi<->sysv adapter (#3451)
make a small dll for handling the msabi<->sysv adapter, using only assembly (taken from generated optimized rustc output) and handcrafted unwind information (c# exceptions in a callback seem to work fine in testing)
additionally, allow floating point arguments. this really only needs to occur on the c# side. msabi and sysv agree on the first 4 floating point args and for returns, so no work actually has to be done adapting these
with assembly being used, we can guarantee rax will not be stomped by compiler whims (and avoid potential floating point args from being trashed)
2022-11-16 09:02:13 -08:00
CasualPokePlayer a0de42b1b3 remove struct hack, it's not actually needed
out double is System.Double& while double is System.Double, so it doesn't actually trip paramenter verifier
2022-11-15 01:12:31 -08:00
CasualPokePlayer eec86ad81a Use actual doubles for figuring out aspect ratio
Fixes issues when mame sends over < 1 bounds which round down to 0 with a long cast (resulting in div by 0 exceptions)
Also fix some oopsies with incorrect function signatures.
Remove MAME string docs as they aren't really relevant anymore, as only MameGetString handles lua string handling now
2022-11-15 00:57:30 -08:00
CasualPokePlayer 715f4f497c add some missing mame mnemonics 2022-11-11 08:45:02 -08:00
Morilli c21fedc76a BSNESv115+: add option for disabling ppu sprite limit 2022-11-10 23:22:17 +01:00
CasualPokePlayer 066297d5e7
MAME Waterbox (#3437) 2022-11-10 00:05:25 -08:00
YoshiRulz e7e587d625
Restore old behaviour of "Always use recent path for ROMs"
fixes 41d46dd37, see #1574
2022-11-08 06:30:12 +10:00
YoshiRulz 948084a97e
Use `Movie.NotActive` extension instead of negated `IsActive` 2022-11-07 06:10:37 +10:00
YoshiRulz 84cc71e454
Use `DialogResult.IsOk` extension everywhere and clean up 2022-11-07 06:03:55 +10:00
YoshiRulz 36cb62a792
Create and use `ToolStripDropDownItem.ReplaceDropDownItems` extension 2022-11-07 06:03:55 +10:00
YoshiRulz 5df9879842
Refactor `MultiDiskFileSelector.BrowseButton_Click` 2022-11-07 05:27:15 +10:00
YoshiRulz 04f34ac7af
Add `Util.BreakDebuggerIfAttached` helper 2022-11-07 04:37:34 +10:00
YoshiRulz f1f0f1695c
Encapsulate `OpenFileDialog`/`SaveFileDialog` 2022-11-05 09:10:11 +10:00
YoshiRulz 2db5235319
Cache and reuse `FilesystemFilterSet`s 2022-11-05 09:10:11 +10:00
YoshiRulz 1232157cc1
Improve caching of `FilesystemFilterSet.ToString` 2022-11-05 09:10:11 +10:00
YoshiRulz c153505b58
Invert some conditionals to reduce nesting 2022-11-05 09:10:10 +10:00
YoshiRulz df63853cd5
Add `IDialogParent` interface to a couple of config dialogs 2022-11-05 09:10:05 +10:00
YoshiRulz 8949b1aa6b
Make sure `CheckLib` in `Program` static ctor disposes GUI properly 2022-11-04 07:08:54 +10:00
YoshiRulz c891cc2cb5
Don't ignore mGBA skip BIOS setting when recording (resolves #2465)
also disable skip BIOS with TAS profile and enable with Casual profile
also removed `DeterministicEmulation ||= !SkipBios`, does it matter?
2022-11-03 12:04:16 +10:00
YoshiRulz 77f824ab55
Clean up `MGBAHawk.DeterministicEmulation` assignment 2022-11-03 11:56:01 +10:00
YoshiRulz 13a01340de
Refactor Libretro ControllerDef generation, fixing input display
see #3360
2022-11-03 11:02:53 +10:00
YoshiRulz 781c152bf6
Remove old ControllerDef copying that was messing with ControlsOrdered 2022-11-03 11:02:52 +10:00
YoshiRulz a8f571f2d6
Reinstate `GameInfo.NullInstance`'s name, and only instantiate it once
reverts 8dcea2470
`PathEntryCollection.RetroSystemAbsolutePath` extension didn't like this, there
may be others, and I don't want to look through them all
2022-11-03 11:02:44 +10:00
YoshiRulz 3e79e68d1d
Dedup in `CheatEdit.GetCheat` 2022-11-02 01:05:12 +10:00
YoshiRulz 414c21609b
Disallow updating cheats when multiple rows selected (resolves #1726) 2022-11-02 01:01:09 +10:00
YoshiRulz 5ae23c63bf
Change "Edit" button in Cheats dialog to read "Overwrite"
kept the mnemonic because idk
2022-11-02 01:00:16 +10:00
YoshiRulz fd2772707b
Update `forms.drawImageRegion` documentation with a diagram
only embeds on TASVideos Wiki, which I held off on updating because there are a
lot of changes and we can do them all at once
2022-10-30 18:19:23 +10:00
CasualPokePlayer 8ee75879e6 Rework MAME integration a bit
The periodic callback is now used as a way to service "commands" sent from the main thread
Upon servicing a command, the mame thread will set the current command to NO_CMD then wait for the main thread allow the mame thread to continue
During this wait, the main thread may optionally set the next command (done here for STEP -> VIDEO), ensuring the next callback will service that command
A dummy "WAIT" command can be sent to trigger this waiting behavior, allowing the main thread to safely touch mame while the mame thread is frozen (important for mem accesses and probably savestates?)

A/V sync is also reworked. We can assume that 1/50 of a second worth of samples will be sent each sound callback. We can also assume 1/FPS of a second worth of time will be advanced each frame advance
So, we can just give hawk 1/FPS worth of samples every GetSamplesSync, if they are available. If we have less (probable on first few frames), we'll just give all the samples, and hope it balances out later.
2022-10-29 17:07:50 -07:00
CasualPokePlayer cc71882059
BSNES Memory Domain Fixes (#3423)
* Use SameBoy submodule symlink for BSNES

* SGB memory domains

* Fix SGB saveram issues (extra data like rtc will be saved correctly now here)

* Various cleanups, avoid unneeded unsafe use, a little better EnterExit use

Co-authored-by: Morilli <35152647+Morilli@users.noreply.github.com>
2022-10-28 19:22:49 -07:00
Morilli 256a8617e9 Fix #3399 by always calling UpdateViewerMouseover 2022-10-27 01:30:41 +02:00
CasualPokePlayer dd33e92a9f ensure ClockRate in the Bk2Header uses . instead of , 2022-10-21 02:34:59 -07:00
CasualPokePlayer c8d4e606af suppress updates while rebooting core, fixes #3424 2022-10-21 02:19:22 -07:00
CasualPokePlayer f29113287e add Jaguar to MultiDiskBundler menu 2022-10-11 21:51:26 -07:00
YoshiRulz 2b4d9c0c7d
Add debug utility to byteswap N64 roms 2022-10-11 10:12:49 +10:00
YoshiRulz 5b859960e9
Move types for debug menu to own files 2022-10-11 10:12:49 +10:00
YoshiRulz 82c3b471a5
Minor refactors to byteswapping (N64 rom loading and Lua bit library) 2022-10-11 10:12:45 +10:00
YoshiRulz bb4ba2184f
Fix `forms.*` acting on every LuaPictureBox, not the specified one
fixes #3395
this has been broken since introduction in 2ddadeae2
2022-10-08 11:11:40 +10:00
YoshiRulz 7930a79cef
Prompt to disable cheats when starting movie playback (resolves #3389) 2022-10-08 10:42:10 +10:00
YoshiRulz 28c53cfa21
Fix `APIContainer.Comm` not having `HTTP`/`Sockets` on first boot 2022-10-06 11:53:11 +10:00
CasualPokePlayer 2fa46efda6 add jaguar db, change db parser to prefer the strongest hash available, fix potential edge case if a crc32: prefix is present (and simplify the code) 2022-10-04 22:05:38 -07:00
CasualPokePlayer c547a20f8e Use `LoadOther` for GBS files, cleanup the code a little, update SameBoy version info 2022-10-03 15:49:09 -07:00
CasualPokePlayer 9528a2030f GBS support using SameBoy 2022-10-03 01:55:14 -07:00
CasualPokePlayer 0c6f0523a0 Update sameboy, expose audio channel enable/disabling, cleanup settings to go through a single call/struct 2022-10-02 21:40:00 -07:00
CasualPokePlayer 8732e561a1 Better Jaguar Virtual Width/Height
Jaguar VPad
Proper Jaguar default controls
Remove a lot of unneeded `ReSharper disable once UnusedMember.Global` in vpads (Global has been gone for a while now...)
Set VirtualJaguar to released
2022-10-02 18:53:34 -07:00
CasualPokePlayer 2e5c62f632 default Jaguar bios to not be skipped, some games rely on Jaguar bios running on boot 2022-09-30 23:54:13 -07:00
CasualPokePlayer be771c134c default to KSeries bios instead of MSeries bios, as it seems to be more compatible 2022-09-30 21:56:19 -07:00
CasualPokePlayer 5f509525bc [virtualjaguar] less screen changing spam 2022-09-30 21:44:34 -07:00
YoshiRulz 158c897702
Use `Google.FlatBuffers` NuGet package and check in new Nyma codegen 2022-09-30 05:33:18 +10:00
YoshiRulz 5544bc526a
Add missing import
fixes 9e9e041bb
2022-09-30 03:52:05 +10:00
YoshiRulz 9e9e041bba
Fix AOoRE when loading TAStudio w/ cheats(?)
partially reverts dd4f9aaf6
InputRoll code is too inscrutable for me to determine the actual cause so I just
left a `Debug.Assert`
2022-09-30 03:25:13 +10:00
CasualPokePlayer f8a4524df7 add in missing platform framerates, add in Jaguar CD iding for movie file, fix aspect ratio for jaguar 2022-09-28 17:25:34 -07:00
YoshiRulz 79d43dab1d
Extract constants used for `NamedLuaFunction.Event` 2022-09-29 08:54:23 +10:00
YoshiRulz 9815b377d1
Also protect against mutation of `IEnumerable` for `onconsoleclose`
see 7a26546cf, fixes dc66b4357
2022-09-29 08:54:16 +10:00
YoshiRulz 7a26546cfc
Maybe fix mutation of IEnumerable (`InvalidOperationException`)
fixes 3024bc0d0
2022-09-29 05:21:08 +10:00
CasualPokePlayer 70a21ee07e push c# side for memtrack support 2022-09-28 03:28:01 -07:00
Morilli 9fa38b8d78 Fix #3398 2022-09-27 13:58:56 +02:00
YoshiRulz b2bacdecd2
Fix double call to pure method 2022-09-25 22:26:41 +10:00
YoshiRulz 3cbdd36fe0
Deduplicate some code in `MainForm` 2022-09-25 07:04:21 +10:00
YoshiRulz 728f393eb1
Clean up `MainForm.CheckHotkey` 2022-09-25 07:04:21 +10:00
YoshiRulz d7c79a5f03
Fix "Toggle All Cheats" hotkey behaviour re: separators 2022-09-25 07:04:13 +10:00
CasualPokePlayer 3122078dfd tweak jaguar cpu tracelogger 2022-09-24 06:23:24 -07:00
CasualPokePlayer ff5c8d4e52 more jag disasm tweaks 2022-09-24 04:38:06 -07:00
CasualPokePlayer c92c2bf661 fix jag risc disasm 2022-09-24 04:30:05 -07:00
CasualPokePlayer 38b4b98fc0 minor touchups to jag risc disassembler 2022-09-24 04:29:00 -07:00
CasualPokePlayer c9618b3f92 c# side to jag debugging improvements 2022-09-24 04:15:05 -07:00
CasualPokePlayer 6113f3c17b partial jagcd support (doesn't seem to completely work here)
fix some issues with vjaguar cleanup
add mem/trace callbacks and get/set reg support
2022-09-23 01:05:41 -07:00
CasualPokePlayer 71e3dfed74
fix #3388 2022-09-18 22:44:26 -07:00
CasualPokePlayer 38d3d36199 fix opcode address in exec callbacks + tracing (thanks prefetch)
sp/lr/pc for r13/r14/r15 for tracing
fix a bad for threaded renderer's thread start callback
2022-09-18 02:39:31 -07:00
CasualPokePlayer 5e34dc6166 Always savestate expansion pak regardless of settings.
All the disable expansion pak setting actually does is tell the game the expansion pak is not available.
However, not all games actually abide by this, some will use the expansion pak area anyways.
Video plugins also end up just using a "segfault test" to determine if the expansion pak is present or not
So video plugins may use the expansion pak area too
This ends up causing savestates sometimes just crashing the game if the expansion pak ends up used

Resolves #3092, other state issues might be solved with this (I suspect #3328 is caused by this)
2022-09-17 13:11:31 -07:00
CasualPokePlayer de38781081 Implement Rumble for Nyma 2022-09-17 01:36:51 -07:00
YoshiRulz de1e7eef69
Document socket response format 2022-09-16 22:37:15 +10:00
CasualPokePlayer afccbe8aa6 Fix hang with "Go to Address" dialog in RamSearch
resolves #3384, fixes cc4acd9c64
2022-09-14 19:39:03 -07:00
YoshiRulz 1bf2bb758c
Change serialisation of Jaguar VSystemID
also fixed line ending
2022-09-12 17:13:15 +10:00
CasualPokePlayer 483258a04d virtualjaguar port, resolves #1907 2022-09-11 21:38:46 -07:00
CasualPokePlayer 34c504d7b9 update ds disassembler 2022-09-10 20:53:05 -07:00
YoshiRulz d2965c2185
If dummy sound chosen in config, try DirectSound (maybe fixes #3379)
- if DirectSound fails (i.e. dummy is in config for a reason), then skip the
error dialog as the user has probably seen it already, and set it back to dummy
- if DirectSound succeeds, leave it, it will be written to config (there's a
mute setting for people who really don't want sound)
- copied the init config code so s/DirectSound/OpenAL/ on Linux
- could probably try OpenAL on Windows when DirectSound fails but whatever
2022-09-08 08:39:25 +10:00
YoshiRulz 707ec53bd5
Move `SoundConfig.ApplyNewSoundDevice` logic to callsite 2022-09-08 08:23:01 +10:00
Moritz Bender 6f0953aaa3
Implement snes graphics debugger for the new bsnes core (#3367)
* Partial port of graphics debugger to new BSNES

* minimal "working" copy-paste

* small fix for the previous commit

* Implement more stuff

* no idea whose responsibility "EnterExit" is but this should work

* add support for backdropcolor

i have 0% trust in this code

* implement mode7, apply backcolor on load

* 🙈

un-"implement" the nonfunctional scanlinehookmanager as well as the non-functional palette setting logic
- this may actually break config lol

* don't break libsnes config

* Provide IBSNESForGfxDebugger in the subbsnes core

* Remove redundant semicolon

* Clean up diff of `comboPalette_SelectedIndexChanged`

* Fix crash

Co-authored-by: YoshiRulz <OSSYoshiRulz@gmail.com>
2022-09-03 19:13:56 +02:00
YoshiRulz 28d62e69d7
Enable menu mnemonics (Alt+X) for MainForm on Linux 2022-09-03 19:59:08 +10:00
Bruno Valadão Cunha f024986ffc
Added 'Edit marker frame' feature (squashed PR #3351)
* Added 'Edit marker frame' feature
* Changed Edit Marker Frame icon to clock
* Hotkey tooltip + Prevent changing to a frame that already has marker
* Forgot to delete this icon, was replaced by Clock.png
* De-rookie here and there
* Clean up diff
2022-09-03 12:08:23 +10:00
CasualPokePlayer 09e8c7a9b6 ensure ds firmware settings represent sync settings if real firmware isn't used
resolves possible cause for #3377
2022-09-02 15:11:34 -07:00
CasualPokePlayer 70906c9004 quick fail is the user is somehow running EmuHawk as a 32 bit process 2022-08-29 17:01:26 -07:00
CasualPokePlayer b588212e17 remove unused using (cruft from experimentation), remove unneeded enum values 2022-08-29 16:36:32 -07:00
CasualPokePlayer e198122691 output a more helpful error message on windows for GetErrorMessage 2022-08-29 16:33:41 -07:00
CasualPokePlayer 06226e78cf add way to obtain error message in ILinkedLibManager, use it to display an error code for init lib checks 2022-08-29 15:34:44 -07:00
CasualPokePlayer 463780a875 more cleanly deal with dummy hashes
fixes a515672
2022-08-28 03:13:23 -07:00
CasualPokePlayer a515672d4d fix #3159 2022-08-28 02:56:31 -07:00
YoshiRulz 14f470a9a7
Improve encapsulation of `ToolFormBase` props 2022-08-28 03:39:18 +10:00
YoshiRulz faf4a8b24f
Remove unused "TAStudio states" path
TAStudio prop unused since 5bf21e391, path was still in use until b1296dd9b
2022-08-28 03:09:59 +10:00
CasualPokePlayer c761d6d807 fix changing mupen expansion pack setting 2022-08-26 13:30:44 -07:00
YoshiRulz a344ee2288
Fix modifier key check in `TAStudio.TasView_MouseDown` 2022-08-24 09:44:24 +10:00
YoshiRulz 61c34eca74
Minor refactor to not mutate local in `TAStudio.TasView_MouseDown` 2022-08-24 09:44:17 +10:00
CasualPokePlayer 352977c7ea speedup HashRegion/ReadByteRange/WriteByteRange for waterbox cores (doesn't do anything for non-wbx cores) 2022-08-23 03:09:23 -07:00
YoshiRulz 5906fd154e
Fix typo
fixes a95c4f182
2022-08-22 01:21:22 +10:00
CasualPokePlayer afdfa065bd missed apostrophe somehow 2022-08-19 23:46:03 -07:00
CasualPokePlayer 9174d17bd8 tic80 settings for enabling/disabling controllers, proper mnemonics 2022-08-19 23:43:55 -07:00
CasualPokePlayer 98a8cdf693 remove gongshell, add "simple" code for opening win32 context menu (gongshell's only actual use), re: #2261 2022-08-19 00:24:50 -07:00
YoshiRulz 64bc762439
Mute new MSB3270 warnings
no sure if these are the result of a .NET SDK update or my NuGet experiment
2022-08-18 17:16:40 +10:00
YoshiRulz 3a3494aedb
Add missing attribute to `events.can_use_callback_params` param 2022-08-18 17:12:15 +10:00
YoshiRulz 8d484ac196
Hardcode edge cases in `MovieConversionExtensions` to pass test
the argument in every real call is from `IMovie.Filename`, which is never
assigned null, and I don't think it's assigned anything but an absolute path
2022-08-17 19:05:32 +10:00
CasualPokePlayer 2ecb572892 fix nyma light guns, resolves #3359 2022-08-17 01:57:40 -07:00
YoshiRulz 7cde8bb466
Add and use 2 extension methods for splitting path into dir+filename 2022-08-17 17:35:07 +10:00
YoshiRulz dce961357a
Refactor `IGameInfo.FilesystemSafeName` extension
it doesn't make any sense to split this string into dir+filename, it shouldn't
contain a slash
2022-08-17 17:35:07 +10:00
YoshiRulz 2b59cfc1c4
Small refactor in `DiscMountJob.RunBizHawk` 2022-08-17 17:35:07 +10:00
YoshiRulz 10478e23f1
Remove redundant dir exists checks 2022-08-17 17:35:07 +10:00
YoshiRulz f228b01bdf
Rename `IMainFormForTools.SetWindowText` to `UpdateWindowTitle`
in practice there is only one implementation and it just called the other method
(which is inherited from `FormBase`)
2022-08-17 17:35:06 +10:00
YoshiRulz d5bf542a3c
Cache `ToolStripRenderer` used by `FormBase.FixBackColorOnControls` 2022-08-17 17:35:06 +10:00
YoshiRulz 322ed164bf
Remove backing field of `FormBase.BlocksInputWhenFocused` 2022-08-17 17:34:59 +10:00
Peter Jorgensen 3958348e94
Add auto save state on close (squashed PR #3218)
resolves #1861

* Add configuration for auto-saving state on exit
* Update MainForm to auto save on close game if configured
* Fix config serialization test.
* Revert unnecessary changes to Designer file
* Move autosave configuration into Save States menu off of File
* Undo previous test changes
* Remove explicit size on menu item.
* Fix logic
2022-08-17 14:27:50 +10:00
Morilli 7ffa605b28 BSNESv115: fix crash when audio output is disabled
(fixes 039d822144)
2022-08-17 01:35:02 +02:00
Moritz Bender 039d822144
BSNESv115+: Replace the 'snes_audio_sample' callback with a dynamic audio sample vector to reduce callbacks (#3010)
* BSNESv115+: Replace the 'snes_audio_sample' callback with a dynamic audio sample vector to reduce callbacks

* fix integration for subbsnes core

* reduce buffer allocations
- also make frame setter private now that it's possible
2022-08-15 20:50:26 +02:00
Morilli f1e11dfc36 simplify Stream.ReadAllBytes extension and use it more 2022-08-15 20:35:57 +02:00