profi200 / open_agb_firm

open_agb_firm is a bare metal app for running GBA homebrew/games using the 3DS builtin GBA hardware.
GNU General Public License v3.0
908 stars 44 forks source link

Save detection fails on Pinball Challenge Deluxe (Europe). #7

Open vaguerant opened 4 years ago

vaguerant commented 4 years ago

This game has saving support but doesn't include any of the typical save type strings, so it would need to be hardcoded as an exception. The publisher Ubisoft decided to pull the EEPROM before release, presumably as a cost-cutting measure, but saving support was left in the game and I can confirm saving works on real GBA hardware with a flash cart.

With apologies, I have no idea what save type the game expects, so I'm not any help in terms of getting this working.

profi200 commented 4 years ago

It can't be auto detected. Can only add it to the override list. If the devs intended it not having a EEPROM/Flash/SRAM chip it would be better making that optional imho.

vaguerant commented 4 years ago

Just for reference here's a thread about this game on the old Pocket Heaven homebrew message board:

http://archive.is/bAQiB

It includes a quote from Binary9's director of development, Stewart Gilray, where he talks about the game being designed with saving in mind.

The thread also has some discussion about what save type we think the game uses; it seems it may actually be SRAM rather than EEPROM since it works on SRAM-only flash carts without any form of patching.

EDIT: So after some discussion/thinking out loud on Discord, my theory is now that saving was not just left in, but rather intentionally switched from EEPROM to SRAM for compatibility with flash carts, where SRAM was standard.

I believe the game was originally designed around (8 KB) EEPROM saving as Gilray states in the above-linked thread. When publisher Ubisoft told the devs they would not be getting save support, I suspect they unofficially switched to using SRAM saving, knowing this would at least allow saving to work on flash carts. They presumably didn't use the SDK saving and strings in order to avoid it being noticed by Ubisoft or Nintendo that their game was now deliberately targeting unlicensed copying devices.

This would explain the various weirdnesses around saving in Pinball Challenge Deluxe, which imply that it's more complex than just leaving in SRAM support after the hardware was pulled. Gilray said EEPROM (presumably 8 KB) but it actually uses 32 KB SRAM, it only uses ~3 KB out of that even though SRAM would undoubtedly be more expensive, and it doesn't have the save type strings included in all other games that save officially.

Gilray is quoted in the linked thread encouraging people to play on flash carts for the save support. I think he knew this would work not just because saving was left in the ROM, but because he and Binary9 specifically tweaked the game for flash card save support once they knew saving in the retail version was off the table.

All of this happened 18 years ago, so hopefully nobody will get in trouble if this theory is correct.