Subsystem-based Gameboy games use incorrect save file names when played on SGB
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 14.1k
- Forks
- 2.2k
- Avg merge
- 7h 35m
- Merged PRs (30d)
- 51
Description
Note: I am making a guess that this is a RA problem since, AFAIK, RA is responsible for managing .srm files
Description
Subsystem-based Super Gameboy games use incorrect save file name (just .srm instead of rom file name.srm)
Expected behavior
The save file should be named according to the Gameboy rom file.
Actual behavior
A rom file name SRM is created, but this file is mostly empty. The actual save data is contained in a file named .srm.
foo.srm contains the actual save data, renamed it from .srm. The other file, despite its name, does not contain save data for Pokemon.
Steps to reproduce the bug
- Acquire copies of Super Gameboy 2 (J) and Pokemon Blue (U)
- Install and load the bsnes core.
- Using the Subsystems/Load Super Game Boy menu, load Pokemon Blue and then Super Gameboy 2, begin playing.
- Go through the intro of Pokemon and save at the first opportunity.
- Close RA gracefully.
- Examine the default saves folder.
Version/Commit
- RetroArch: 1.10.0
Environment information
- OS: macOS Monterey 12.2.1
- SGB2 rom:
Super Game Boy 2 (Japan).sfc - Game rom:
Pokemon - Blue Version (USA, Europe) (SGB Enhanced).gb
Log
[INFO] [Environ]: SET_SUBSYSTEM_INFO.
[INFO] [Subsystem]: Setting current subsystem to: 0(sgb) Content amount: 2
[INFO] [Subsystem]: Subsystem id: 0 Subsystem ident: sgb Content ID: 0, Content Path: /Volumes/Emulation/GB/Pokemon - Blue Version (USA, Europe) (SGB Enhanced).gb
[INFO] [Subsystem]: Subsystem id: 0 Subsystem ident: sgb Content ID: 1, Content Path: /Volumes/Emulation/SNES/Roms/Super Game Boy 2 (Japan).7z#Super Game Boy 2 (Japan).sfc
[INFO] [Content]: Updating firmware status for: /Users/karu/Library/Application Support/RetroArch/cores/bsnes_libretro.dylib on /Users/karu/Documents/RetroArch/system
[INFO] [Core]: No content, starting dummy core.
[INFO] [Core]: Content ran for a total of: 00 hours, 00 minutes, 00 seconds.
[INFO] [Core]: Unloading core..
[INFO] [Core]: Unloading core symbols..
[INFO] [Video]: Average monitor Hz: 59.998800 Hz. (5.774 % frame time deviation, based on 2048 last samples).
[INFO] === Build =======================================
[INFO] CPU Model Name: Apple M1
[INFO] Capabilities: MMX MMXEXT SSE SSE2 SSE3 SSSE3 SSE4 SSE4.2 AES AVX AVX2
[INFO] Built: Jan 21 2022
[INFO] Version: 1.10.0
[INFO] =================================================
[INFO] [Input]: Found input driver: "cocoa".
[INFO] [Core]: Loading dynamic libretro core from: "/Users/karu/Library/Application Support/RetroArch/cores/bsnes_libretro.dylib"
[INFO] [Environ]: GET_CORE_OPTIONS_VERSION.
[INFO] [Environ]: GET_LANGUAGE: "0".
[INFO] [Environ]: RETRO_ENVIRONMENT_SET_CORE_OPTIONS_V2_INTL.
[INFO] [Environ]: GET_LOG_INTERFACE.
[INFO] [Environ]: SET_CONTROLLER_INFO.
[INFO] [Environ]: SET_INPUT_DESCRIPTORS:
[INFO] [Remaps]: Remap directory: "/Users/karu/Library/Application Support/RetroArch/config/remaps".
[INFO] [Overrides]: Redirecting save file to "/Users/karu/Documents/RetroArch/saves/bsnes.srm".
[INFO] [Overrides]: Redirecting save state to "/Users/karu/Documents/RetroArch/states/bsnes.state".
[INFO] Redirecting save state to "/Users/karu/Documents/RetroArch/states/Pokemon - Blue Version (USA, Europe) (SGB Enhanced) + Super Game Boy 2 (Japan).state".
[INFO] Redirecting save file to "/Users/karu/Documents/RetroArch/saves/Pokemon - Blue Version (USA, Europe) (SGB Enhanced).srm".
[INFO] Redirecting save file to "/Users/karu/Documents/RetroArch/saves/Super Game Boy 2 (Japan).srm".
[INFO] [Content]: Content loading skipped. Implementation will load it on its own.
[INFO] [Content]: Core requires uncompressed content - extracting archive to temporary directory.
[INFO] [Content]: Content successfully extracted to: "/var/folders/fc/2ft31gkn2xn4by4cd8l_dllh0000gn/T/Super Game Boy 2 (Japan).sfc".
[INFO] [Content]: Content loading skipped. Implementation will load it on its own.
[libretro INFO] GB ROM: /Volumes/Emulation/GB/Pokemon - Blue Version (USA, Europe) (SGB Enhanced).gb
[libretro INFO] SGB ROM: /var/folders/fc/2ft31gkn2xn4by4cd8l_dllh0000gn/T/Super Game Boy 2 (Japan).sfc
[INFO] [Environ]: GET_SAVE_DIRECTORY.
[INFO] [SRAM]: Skipping SRAM load.
[INFO] [Core]: Version of libretro API: 1, Compiled against API: 1
[INFO] [Audio]: Set audio input rate to: 47921.08 Hz.
[INFO] [Video]: Set video size to: 1410x1080.
[WARN] [Video]: 0RGB1555 pixel format is deprecated, and will be slower. For 15/16-bit, RGB565 format is preferred.
[INFO] [GL]: Found GL context: "cocoagl".
[INFO] [GL]: Detecting screen resolution: 960x720.
[INFO] [GL]: Vendor: Apple, Renderer: Apple M1.
[INFO] [GL]: Version: 2.1 Metal - 76.3.
[INFO] [GL]: Using resolution 1410x1080.
[INFO] [GL]: Default shader backend found: glsl.
[INFO] [Shader driver]: Using GLSL shader backend.
[INFO] [GLSL]: Checking GLSL shader support ...
[WARN] [GL]: Stock GLSL shaders will be used.
[INFO] [GLSL]: Found GLSL vertex shader.
[INFO] [GLSL]: Found GLSL fragment shader.
[INFO] [GLSL]: Linking GLSL program.
[INFO] [GLSL]: Found GLSL vertex shader.
[INFO] [GLSL]: Found GLSL fragment shader.
[INFO] [GLSL]: Linking GLSL program.
[INFO] [GLSL]: Found GLSL vertex shader.
[INFO] [GLSL]: Found GLSL fragment shader.
[INFO] [GLSL]: Linking GLSL program.
[INFO] [GL]: Using 4 textures.
[INFO] [GL]: Loaded 1 program(s).
[INFO] [Font]: Using font rendering backend: "bitmap".
[INFO] [Video]: Graphics driver did not initialize an input driver. Attempting to pick a suitable driver.
[INFO] [Input]: Found HID driver: "iohidmanager".
[INFO] [Joypad]: Found joypad driver: "hid".
[INFO] [Video]: Found display server: "null".
[INFO] [CoreAudio]: Using output sample rate of 48000.0 Hz
[INFO] [CoreAudio]: Using buffer size of 24576 bytes: (latency = 64 ms)
[INFO] [Display]: Found display driver: "gl".
[INFO] [Environ]: SET_SUBSYSTEM_INFO.
[INFO] [Playlist]: Loading history file: "/Users/karu/Library/Application Support/RetroArch/config/content_history.lpl".
[INFO] [Playlist]: Loading history file: "/Users/karu/Library/Application Support/RetroArch/config/content_music_history.lpl".
[INFO] [Playlist]: Loading history file: "/Users/karu/Library/Application Support/RetroArch/config/content_image_history.lpl".
[INFO] [Playlist]: Loading favorites file: "/Users/karu/Library/Application Support/RetroArch/config/content_favorites.lpl".
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Begin at the Subsystems/Load Super Game Boy path and the save-directory/SRAM handling shown in the log. Reproduce with the listed bsnes setup, then verify that the actual Game Boy save data is written under the Game Boy ROM filename rather than .srm.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100