sporchia / alttp_vt_randomizer

ALttP VT Randomizer and API
https://alttpr.com/
MIT License
315 stars 147 forks source link

games generated with MSU-1 support do not save #540

Closed burnt43 closed 5 years ago

burnt43 commented 6 years ago

Console or Emulator: SD2SNES running firmware 1.8.0 running on a SNES Jr. (SNS-101)

Original Filename: ALttP - VT_no-glitches-29_normal-standard_uncle-ganon_753867122.sfc

Description of problem: On the randomizer site if I generate a game with 'Background Music (set to "No" for MSU-1 support)' set to 'No', then no save file will be created (an .srm file in /sd2snes/saves of flash drive).

Steps to Reproduce:

  1. generate a game with background music set to 'No'
  2. copy the generated file into a directory that has all the pcms, etc. for the new music to play and rename the file to match the filenames (such as alttp_msu.sfc). although I do not think you even need the music or manifest files at all. I think any game with music off will not save. Edit: A generated file with background music off will save fine on its own. It's only after putting in a directory with the files needed to get the MSU-1 music working will it not save.
  3. load up the game and start a new game
  4. walk out of link's house and save and quit
  5. shut off the console
  6. turn on console (now the file select screen will be blank)

Unsuccessful Troubleshooting:

  1. I thought the issue is with the filename. I renamed all the pcm and other files to be of the format that the randomizer creates. That is to say I renamed the pcm files like "ALttP - VT_no-glitches-29_normal-standard_uncle-ganon_753867122-1.pcm"
  2. No .srm file was created so I made a blank file with the name ALttP - VT_no-glitches-29_normal-standard_uncle-ganon_753867122.srm in /sd2snes/saves. I thought maybe the game/flash cart/console would see the empty file and start writing data there. This is not the case.
  3. Tried it on a different SNES console with the same SD2SNES (not sure what I was thinking was going to change but it was worth a shot).
  4. I tried downgrading SD2SNES firmware to 0.1.7e. Did not work.
  5. I tried a few other soundpacks. All the sound packs did play their music fine, but the game would not keep a save after powering off the console.
  6. I placed an empty .srm file into the directory where the music and .sfc files are. The SD2SNES seems to recognize this .srm file and it moves it to /sd2snes/saves but will not write to it.

Other Things of Note:

  1. I have a version of Donkey Kong Country with an applied patch that enables MSU-1 support and this game is able to save just fine all other things being equal.
  2. games generated from alttpr site with background music on DO save normally and I have no issue.
burnt43 commented 6 years ago

This seems like its a problem with my SD2SNES. I used a US ROM and patched it with a patch designed for the US version from romhacking.net and loaded it up on my SD2SNES. The new music worked OK, but the game would not keep a save. A ROM generated from lttpr site without music enabled and no 'lttp_msu.msu' file will keep a save just fine.

burnt43 commented 6 years ago

Ok, I have found the solution if anyone cares. You have to quit back to the SD2SNES menu for it to write the srm file. I'm not sure why this is. Other games do save just fine when powering off without going back to the menu. Something about LTTP+MSU makes this needed.

  1. download a lttr rom with music set to off
  2. place this file in a directory with all the pcm files
  3. create a blank .msu file in the same directory
  4. make sure all files (.sfc, .pcm, and .msu) have the same prefix such as 'lttp_msu'
  5. turn on your snes with sd2snes
  6. make sure 'In Game Hooks' on! I think by default in sd2snes 1.8.0 this option is disabled. I remember this working without having to change options in 0.1.7e
  7. After S+Q make sure to press Select+X+L+R to return to the sd2snes menu. This will then write keep your save (write to .srm file in /sd2snes/saves)
miketrethewey commented 6 years ago

Are we good to close this one then? I guess I forgot about the in-game hooks. We can keep it available for reading though for other users who may end up having a similar situation.

KatDevsGames commented 6 years ago

This procedure is unnecessary. The sd2snes switches from periodic/auto saving to manual saving when MSU support is enabled. This is normal behavior. The sd2snes will persist SRAM on any VECTOR_RESET. All you need to do is hit the reset button on the console to cause the sd2snes to persist its SRAM when in manual saving mode.

Also, the alttp randomizer project recommends that you do NOT enable sd2snesw In-Game Hooks.

On 8/28/18 9:39 PM, James Carson wrote:

Ok, I have found the solution if anyone cares. You have to quit back to the SD2SNES menu for it to write the srm file. I'm not sure why this is. Other games do save just fine when powering off without going back to the menu.

  1. download a lttr rom with music set to off
  2. place this file in a directory with all the pcm files
  3. create a blank .msu file in the same directory
  4. make sure all files (.sfc, .pcm, and .msu) have the same prefix such as 'lttp_msu'
  5. turn on your snes with sd2snes
  6. make sure 'In Game Hooks' on! I think by default in sd2snes 1.8.0 this option is disabled. I remember this working without having to change options in 0.1.7e
  7. After S+Q make sure to press Select+X+L+R to return to the sd2snes menu. This will then write keep your save (write to .srm file in /sd2snes/saves)

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/sporchia/alttp_vt_randomizer/issues/540#issuecomment-416794484, or mute the thread https://github.com/notifications/unsubscribe-auth/AD5Vm8b9hfcaCHwxVhBKp71HveA1bDuBks5uVfDZgaJpZM4WM_8f.

burnt43 commented 6 years ago

@mmxbass, I just use that method then. @miketrethewey, Close it up!

burnt43 commented 6 years ago

@mmxbass, Well that method didn't work. I turned off in-game hooks and S+Q then reset my console. My save was there but after powering off the console and reloading the game it was not there.

This may not be the ideal solution but using in games hooks and using the back to menu key press it working for me so I will be using this solution.

burnt43 commented 6 years ago

I tried again on 1.8.0 with in game hooks disabled. After S+Q I held down the reset button. There was an amber light then a red light came on. After I shutoff the console and then turned back on and my save was there! Seems you cannot simply press reset it needs to be held down for a bit.

KatDevsGames commented 6 years ago

I'm usually pretty forceful with buttons so it's entirely possible that you need to HOLD. The sd2snes documentation isn't clear on this point. We should probably just say something safe like a full second in the documentation.

On 8/29/18 12:32 PM, James Carson wrote:

I tried again on 1.8.0 with in game hooks disabled. After S+Q I held down the reset button. There was an amber light then a red light came on. After I shutoff the console and then turned back on and my save was there! Seems you cannot simply press reset it needs to be held down for a bit.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/sporchia/alttp_vt_randomizer/issues/540#issuecomment-417017430, or mute the thread https://github.com/notifications/unsubscribe-auth/AD5VmyH6haJTQUCTpEu3wVEkX7QS9DC7ks5uVsI1gaJpZM4WM_8f.

burnt43 commented 6 years ago

I figure since pressing the reset button starts the process for writing an srm file you gotta wait for the IO to the SD card to complete and I don't think the SD2SNES is going to tell the SNES to hold off on resetting until I finish writing to the SD card. Either you give it enough time or you don't.

april commented 6 years ago

Note that the SD2SNES FAQ explicitly calls out that this will be the behavior for any game that uses MSU-1:

MSU1 games cannot autosave because access to the SD Card is reserved exclusively to the MSU1 features. It must be ready to serve MSU1 requests at any time. Therefore, to save your .SRM file with MSU1 games, a soft reset (hold reset button / use in-game button combination) must be carried out.

In my experience, any A1-rated SD card will have no problems / glitches with MSU-1, and require only the tiniest amount of reset time to save properly. You can get them for $10-15 pretty easily and they make this problem go away entirely as long as you follow the SD2SNES instructions.