Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New emulator: DraStic (integrated with GameSwitcher and auto-resume) #1281

Merged
merged 51 commits into from Dec 13, 2023

Conversation

Sichroteph
Copy link
Member

@Sichroteph Sichroteph commented Nov 16, 2023

Integration of Drastic:

- The Game Switcher and Keymon now utilize Miyoo's recentlist.json instead of Retroarch's content_history.lpl.
- The system converts the old Game Switcher list to the new one.
- Keymon has been modified to account for Drastic.
- Scraper now supports NDS games.

Game Switcher:

  • Retroarch games and those launched from the Emu folder (Type = 5) are displayed.
  • The old logic involved parsing the Retroarch game path + core and reconstructing cmd_to_run.sh. The new logic calls the appropriate launch.sh for each console.
  • The code adapts to recentlist.json or recentlist-hidden.json, whether the user chooses to hide the recent panel or not.
  • The code rearranges the recentlist itself when launching a game from the list, a task previously handled by Retroarch.
  • Since the new list can contain apps, not just games, a new integer is assigned to the game structure to track the corresponding line number in the list.

Migration:

  • A file named "listMigration.h" is generated to restore the Game Switcher game list to its previous state. This function parses the Retroarch list to reconstruct the correct commands in the Miyoo recent list.
  • This file operates independently, facilitating easy removal after some time.
  • It was chosen to fully respect the mainUI logic, even by called the absolute paths like this :
    "/mnt/SDCARD/Emu/GB/../../Roms/GB/Metroid 2 - Return of Samus.gb"
  • The migration function also renames old screenshots to adhere to the new hashes.
  • After migration, a flag file is created in /mnt/SDCARD/Saves/CurrentProfile/config/.recentListMigrated, ensuring the process occurs only once per profile.

Keymon :

A DRASTIC profile is added, configuring the menu button actions and the proper termination method.
(A button combo is chosen to end Drastic, as SIGTERM was corrupting the savestates.)

Runtime :

The audioserver is initiated, if needed, before launching the Game Switcher in case the user is coming from a standalone incompatible with.
It now allow to boot on standalones.

Possibilities :

Before, games launched by the Game Switcher did not adhere to the specifics outlined in launch.sh. It is possible to adjust the CPU frequency for each Retroarch console, with a suggestion to lower it for Gameboy games to increase gameplay time significantly.

GameSwitcher_003

schmurtzm and others added 30 commits October 20, 2023 11:34
- Drastic 1.5 from Steward-Fu
- removed useless files
- removed liscenced bios file
- removed duplicated libs which are already in Onion shrunken Parasyte
- cpuclock moved from local folder to Onion bin files
- removed set clock speed to 1200 at exit (already managed by MainUI)
- use only stop_audioserver.sh
- set "frameskip_type" to 2 and "threaded_3d" to 1
- created a dedicated Onion icon
- Disable threaded_3d (better performance but some graphical bugs)
- Disable compress_savestates and backup_in_savestates for better stability of save states
- replace libSDL2-2.0.so.0 : Improved video performance up to 20% only works in Keypad mode
- remove readme_miyoo.pdf (will be reported in documentation)

Credits Steward-Fu
Co-authored-by: Aemiii91 <44569252+Aemiii91@users.noreply.github.com>
Co-authored-by: Schmurtz <schmurtz@gmail.com>
Co-authored-by: Sichroteph <Sichroteph@users.noreply.github.com>
Update libs to "drastic-v1.6_autostate_test1.zip" from Steward-Fu.
Enable "auto_state" in settings.json
Change select sendkey to menu sendkey
It will try to load the ressource in this order :
current_theme/skin/extras/splash-save.png
current_theme/skin/extras/screen_off_save.png
.tmp_update/res/splash-save.png
removed useless files
removed duplicated libs which are already in Onion shrunken Parasyte
cpuclock used from Onion bin files
use only stop_audioserver.sh
set "frameskip_type" to 2 instead of 4
Use dedicated Onion icon
Removed shortcuts splashscreen
png2raw script section commented

Todo :
If required : a shortcut splashscreen with infopanel
Optionally : modify the libs to support the native Exo font from Onion
(our default fonts : https://onionui.github.io/docs/theme-design#default-fonts-credit-aemiii91
Drastic SDL2 menu font : https://github.com/steward-fu/nds_miyoo/blob/d989f8b417760ee411887437442da4b45ec0bd41/sdl2/src/video/mmiyoo/SDL_video_mmiyoo.h#L82C61-L82C61)
Sichroteph and others added 14 commits November 21, 2023 10:47
Fix the "Saving progress" screen shows again for a split second when exiting GameSwitcher using B
--no-footer option
Displays "Saving ..." when exiting a game
the splash screen is no longer displayed when the device is turned off
Based on "drastic-v1.6_glitch_test.zip"  from Steward-Fu
Support 752x560 resolution
Still include an additional theme declined to 752x560 too.
(There should exists only one at once, but if both exists then the priority goes to RECENTLIST_HIDDEN_PATH)
Drastic Onion integration seems ready.
HD resolution has been fixed for MM v4 (752x560)

Last important modification could be to move save states to Onion "Saves" folder :
steward-fu/nds#35

And two details :
Better wallpaper notifications : steward-fu/nds#39
Show the display resolution : steward-fu/nds#40
Steward has solved 3 requests 👍🏻  :
- Move save states to Onion "Saves" folder : steward-fu/nds#35
- Better wallpaper notifications : steward-fu/nds#39
- Show the display resolution : steward-fu/nds#40
@schmurtzm schmurtzm added this to the v4.3 milestone Dec 9, 2023
@schmurtzm schmurtzm marked this pull request as ready for review December 13, 2023 22:25
@schmurtzm schmurtzm added this pull request to the merge queue Dec 13, 2023
Merged via the queue into main with commit 1067613 Dec 13, 2023
4 checks passed
@schmurtzm schmurtzm deleted the FEAT-NDS-integration branch December 13, 2023 23:40
@Aemiii91 Aemiii91 changed the title FEAT: Drastic integration New emulator: DraStic (integrated with GameSwitcher and auto-resume) Jan 6, 2024
@Aemiii91 Aemiii91 added the enhancement New or improved feature label Jan 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New or improved feature
Projects
Status: Done / Ready for release
Development

Successfully merging this pull request may close these issues.

None yet

3 participants