stella-emu / stella

A multi-platform Atari 2600 Emulator
https://stella-emu.github.io
GNU General Public License v2.0
620 stars 112 forks source link

Feature request Cheat Search #163

Open Cibomatto2002 opened 7 years ago

Cibomatto2002 commented 7 years ago

Most emulators has some kind of Cheat Search will we see one one day? Also any plans to add the Atari 5200 and 7800?

sa666666 commented 7 years ago

I will look into the cheat stuff when I have more time, but definitely not before the 5.0 release.

As for adding 5200 and 7800 support, probably not ever. There are other projects that do these, and spreading my time among 3 emulators will result in none of them being good.

thrust26 commented 3 years ago

An idea:

  1. user defines maximum number of value to cheat -> number of bits to search for
  2. user sets the current value (+/-1) or none
  3. user plays the game so that the number changes
  4. user sets the new, current value or the expected delta
  5. Stella presents a list of RAM values which have changed accordingly (using matching deltas and maybe the expected values (+/-1). This is quite similar to the RAM search in the debugger.
  6. if the list is too large the user can decide to repeat from step 3
  7. user accepts the list, defines the requested value and the cheats are generated (see below) and added to the game's cheat list (all disabled)
  8. user tests the cheats one by one and (hopefully) identifies the correct one
  9. user deletes the wrong cheats
  10. done! 😄
    • We need a new cheat method. Currently we are patching the ROM. This is way too complicated for the average user and also very complex when we try to do do this automatically. Therefore this approach requires patching the RAM and freezing the relevant bits.
sa666666 commented 3 years ago

There is already a RAM continuous write cheat. See RamCheat.cxx. I guess this class can be extended or built upon.

thrust26 commented 3 years ago

Yes, that would work well. We would have to extend it to support individual bits and extended RAM and RAM banks.