News: 11 March 2016 - Forum Rules
Current Moderators - DarkSol, KingMike, MathOnNapkins, Azkadellia, Danke

Author Topic: Removing an In-Game Code (Streets of Rage 2)  (Read 1380 times)

eskayelle

  • Full Member
  • ***
  • Posts: 159
  • NBA Jam 2KTE / TMNT of Rage / Pong de las TMNT Dev
    • View Profile
Removing an In-Game Code (Streets of Rage 2)
« on: November 28, 2019, 08:04:14 am »
I'd like to disable the code in the Genesis SoR2 game where holding A and B on the second controller while selecting Options allows an enhanced menu.

I ran some trace logs while entering the code and looked for CMP.I values that are multiples of 0x10.  I tried changing those bytes so the comparison would never equal, and thus the code won't work.

I've had no luck so far finding the comparison value, and I'm not sure of the breakpoint I need to write.  Any advice?
I once wrote a blog.  Maybe you'll find something in it useful?  https://www.romhacking.net/forum/index.php?topic=30593.0

Cyneprepou4uk

  • Hero Member
  • *****
  • Posts: 593
  • I am the baldest romhacker
    • View Profile
Re: Removing an In-Game Code (Streets of Rage 2)
« Reply #1 on: November 28, 2019, 08:27:12 am »
Pause emulator, load save, launch logger, hold start or whatever you need to go to options, unpause emulator, make log1. Then do the same thing, but this time hold a + b as well, and make log2. Compare these two logs, see where they differ.

Quote
I'm not sure of the breakpoint I need to write

A read breakpoint at 2nd player held buttons address

eskayelle

  • Full Member
  • ***
  • Posts: 159
  • NBA Jam 2KTE / TMNT of Rage / Pong de las TMNT Dev
    • View Profile
Re: Removing an In-Game Code (Streets of Rage 2)
« Reply #2 on: November 28, 2019, 09:13:27 am »
Thanks.  I actually did the comparison exercise, but there isn't really a "squelch duplicates" option in gens mod, so it's a bit tough to find the differences, which was why I ended up going the CMP.I route.

I'm not familiar with the held buttons addresses, so I'm hoping a Mega Drive hacker may be able to shed some light on those.  I was looking for $A100xx addresses in the tracelog, but my brute force work wasn't getting me results.
I once wrote a blog.  Maybe you'll find something in it useful?  https://www.romhacking.net/forum/index.php?topic=30593.0

Cyneprepou4uk

  • Hero Member
  • *****
  • Posts: 593
  • I am the baldest romhacker
    • View Profile
Re: Removing an In-Game Code (Streets of Rage 2)
« Reply #3 on: November 28, 2019, 10:54:53 am »
Not sure what are you complaining about. I was able to find that branch in like 10 minutes https://imgur.com/a/IfB8b8i

eskayelle

  • Full Member
  • ***
  • Posts: 159
  • NBA Jam 2KTE / TMNT of Rage / Pong de las TMNT Dev
    • View Profile
Re: Removing an In-Game Code (Streets of Rage 2)
« Reply #4 on: November 28, 2019, 12:07:19 pm »
Thanks!  No complaints here; I just had a fair amount of volume between the logs that I honestly didn't know how to interpret (I was finding differences above this part of the log and got lost because of it).  Looks like if I change the byte at $FC5E to a BRA, that should do the trick.

P.S., I've been reading through your NES hacking tutorials.  Good stuff in there.  Looking forward to your next translations of the tutorials.
I once wrote a blog.  Maybe you'll find something in it useful?  https://www.romhacking.net/forum/index.php?topic=30593.0

Cyneprepou4uk

  • Hero Member
  • *****
  • Posts: 593
  • I am the baldest romhacker
    • View Profile
Re: Removing an In-Game Code (Streets of Rage 2)
« Reply #5 on: November 28, 2019, 01:05:34 pm »
 :)