Posts posted by McMarkis
-
-
-
-
-
Edited by McMarkis
Compiling 'NHL Hockey' Source Code
Happy to share that the 'NHL Hockey' (92) source code now compiles successfully. The code is available on my GitHub repository—enjoy exploring and building upon it!
Community discoveries and tools are welcome and will be added to the repository for everyone’s benefit. Please feel free to share suggestions, report issues, or submit pull requests!
For convenience, you can simply download the zip file and run the included
build.batfile.Technical Info
For those interested, below is some more detailed info on what was needed to get the code compiling.
- The original compiler used to build the source code was not included, so a different compiler ASM68k was used to compile the source.
- Each compiler is different and makes decisions / optimizations based on the opcode. IE move vs moveq vs move.l specific changes were needed.
- The included Macros needed to be written differently to work with this compiler.
- Custom Hex Macro needed to be written.
- Math: Power of 2 was not supported and needed to be re-written.
- RSSET was needed to create symbol definitions without generating data. DS. vs RS.
- Globals weren't needed
- Parent labels were needed in some instances were calculations were being performed on local labels
-
Used the original symbols file and bin file to compare opcodes and ram locations. 99.91% match now
Findings From Source
TBD - Will update with info as it comes in. Such as file formats etc.
-
Edited by McMarkis
Updated RAM MapNERD Notes:
Had to steal some RAM from the Penalty Summary Ram Map. Left enough room for 20 penalties. Highest ever recorded was 14 penalties.There is a "Checks For" RAM Map of 52 bytes starting at Wram address 168E.
First 26 bytes for home team, next 26 bytes for away team. Each byte is associated with the Roster Index # for the player.
IE: If Chicago was the home team; 168E = Belfour, 168F = Waite, 1690 = Roenick... If Pittsburgh was the away team. 16A8 = Barrasso 16A9 = Wregget 16AA = Lemieux.
There is a "Checks Against" RAM Map of 52 bytes starting at Wram address 16C2.
First 26 bytes for home team, next 26 bytes for away team. Each byte is associated with the Roster Index # for the player.
IE: If Chicago was the home team; 16C2 = Belfour, 16C3= Waite, 16C4 = Roenick... If Pittsburgh was the away team. 16DC= Barrasso 16DD = Wregget 16DE = Lemieux.
{$13c3+[$95]} = Jersey# of Player doing the hit
{$12a3+[$95]} = Player Roster Index -1 of player doing the hit [0 based that's why]
{$13c3+[$91]} = Jersey# of Player being hit
{$12a3+[$91]} = Player Roster Index -1 of player being hit [0 based that's why]
Detailed info can be found in Dev NotesRetroArch SAVE STATE Info:
offset = 65430 decimal for RetroArch 1.17 Snes 9x=================================
// Home Player Stats// Checks
fseek($fr, 8864 + $offset + $i);
$Chksfor = hexdec(bin2hex(fread($fr, 1)));fseek($fr, 8916+ $offset + $i); 8854
$ChksA = hexdec(bin2hex(fread($fr, 1)));=================================
// Away Player Stats//Checks
fseek ($fr,8890+ $offset + $i); 8828
$Chksfor = hexdec(bin2hex(fread($fr, 1)));fseek ($fr,8942+ $offset + $i);
$ChksA = hexdec(bin2hex(fread($fr, 1))); -
Edited by McMarkis
Fixed HexProblem:
GENS was tracking Body Checks per player in the game as a hidden stat, while the SNES version was not. We would like to record Checks For and Against in the SNES version as a stat so it can be extracted from the save state and used on the website.Technical Details:
When a Body Check is recorded in the game, also record who performed the check and the player that was checked, similar to the other Player Stats (G, A, Sh)
This can now be extracted from the save state with all the other stats. Plus you can also choose to show the Checks For, in the Player Stats Screen.Patch:
Download the patch tool to patch an existing ROM, or create a new one.
Hex Version:
Replace old hex values with new hex values. (Just use the patch tool, its easier)
-
Edited by McMarkis
11 minutes ago, kidswasted said:In your screenshot I noticed a hack I've never seen previously, "Edit Lines All Positions Hack". Has that been released or still being worked on?
Just released it, I really want to start up the Pond Hockey 3v3 proper with 1 Defense and 2 Forwards. This allows us to do that now.
-
Have you ever wanted to put Ray Bourque as a forward? This hack enables the option in Edit Lines to assign forwards and defensemen to any position
Technical Details:
The SNES code was performing very specific checks to prevent Forwards and Defense from swapping positions. I wrote new code that displays all forwards and defense in Edit Lines. I combined this code with the Missing Extra Attacker Bug Fix, to allow the swapping of forwards and defense.Patch:
Download the patch tool to patch an existing ROM, or create a new one.
Hex Version:
1) Replace old hex values with new hex values. (Just use the patch tool, its easier)
=========================== Headerless ROM (.SFC) =========================== ROM Offsets: (hex) D8C96 Old: C9 01 00 New: 20 78 CE ROM Offsets: (hex) D8E1A Old: 10 21 22 00 93 9B New: EA EA EA 4C BA CE ROM Offsets: (hex) DCE78 Old: FF New: 48 A5 A5 18 6D 9F 1D 85 95 AE 9F 1D E8 A5 95 20 72 8D CF 8F 1D 9F F0 07 C6 95 CA D0 F0 80 1E CA A5 A5 18 6D 9F 1D ED 8B 1D 85 95 20 72 8D 48 A5 A5 86 AF 18 6D AF 00 85 95 68 20 7C 8D 68 C9 01 00 60 22 00 93 9B 8D A3 1D 22 00 D3 9E A5 A5 8D AB 1D 22 DC 92 9B 18 6D A3 1D 8D A3 1D AD AB 1D 4C 3B 8E =========================== Headered ROM (.SMC) =========================== ROM Offsets: (hex) D8E96 Old: C9 01 00 New: 20 78 CE ROM Offsets: (hex) D901A Old: 10 21 22 00 93 9B New: EA EA EA 4C BA CE ROM Offsets: (hex) DD078 Old: FF New: 48 A5 A5 18 6D 9F 1D 85 95 AE 9F 1D E8 A5 95 20 72 8D CF 8F 1D 9F F0 07 C6 95 CA D0 F0 80 1E CA A5 A5 18 6D 9F 1D ED 8B 1D 85 95 20 72 8D 48 A5 A5 86 AF 18 6D AF 00 85 95 68 20 7C 8D 68 C9 01 00 60 22 00 93 9B 8D A3 1D 22 00 D3 9E A5 A5 8D AB 1D 22 DC 92 9B 18 6D A3 1D 8D A3 1D AD AB 1D 4C 3B 8E -
Edited by McMarkis
Problem:
There is a bug in the SNES version that prevents the extra attacker from coming on the ice if he is currently in the lineup. As a result, the extra attacker never comes on the ice when the goalie is pulled or when the other team gets a penalty.Example: Carson is the extra attacker for L.A. If you replace Robitaille with Carson and pull the goalie, you are left with 5 skaters and no Goalie.
Solution:
On the GENS side, when editing lines, if you insert the extra attacker into your lineup, the replaced player will automatically become the new extra attacker.Example: Carson is the extra attacker for L.A. If you replace Robitaille with Carson, Robitaille now becomes the Extra Attacker.
Technical Details:
The SNES code was performing very specific checks to prevent Forwards and Defense from swapping positions. The GENS code didn't care, so I ported a version of the GENS code to SNES.New Code:
See uploaded image at the end of the post, if interested.
Patch:
Download the patch tool to patch an existing ROM, or create a new one.
Hex Version:
1) Replace old hex values with new hex values.
=========================== Headerless ROM (.SFC) =========================== ROM Offsets: (hex) D8C96 Old: C9 01 00 New: 20 78 CE ROM Offsets: (hex) DCE78 Old: FF New: 48 A5 A5 18 6D 9F 1D 85 95 AE 9F 1D E8 A5 95 20 72 8D CF 8F 1D 9F F0 07 C6 95 CA D0 F0 80 1E CA A5 A5 18 6D 9F 1D ED 8B 1D 85 95 20 72 8D 48 A5 A5 86 AF 18 6D AF 00 85 95 68 20 7C 8D 68 C9 01 00 60 =========================== Headered ROM (.SMC) =========================== ROM Offsets: (hex) D8E96 Old: C9 01 00 New: 20 78 CE ROM Offsets: (hex) DD078 Old: FF New: 48 A5 A5 18 6D 9F 1D 85 95 AE 9F 1D E8 A5 95 20 72 8D CF 8F 1D 9F F0 07 C6 95 CA D0 F0 80 1E CA A5 A5 18 6D 9F 1D ED 8B 1D 85 95 20 72 8D 48 A5 A5 86 AF 18 6D AF 00 85 95 68 20 7C 8D 68 C9 01 00 60 -
Edited by McMarkis
Problem:
There is a bug in the SNES code responsible for calculating the Hot/Cold Bonus for every player attribute (Speed, Agility, etc.).
As a result, no attribute receives a negative bonus; instead, the attribute is consistently given the maximum boost (15) if the bonus was negative.
An unsigned division error caused the bug, the details can be found here.Solution:
Fix the division error if the Boost is negative, preventing the Max Boost from being applied. This limits the Boost from (-3 to +3) per attribute as intended.Technical Details:
We convert the negative number to positive for the division, then revert it to negative and apply the bonus. If the number was already positive, no changes are required.New Code:

Special thanks to @chaos for helping with the assembly and providing GENS documentation on player attributes, bonuses etc.Patch:
Download the patch tool to create your own ROM or patch an existing ROM.
Hex Version:
1) Replace old hex value with new hex value.
=========================== Headerless ROM (.SFC) =========================== ROM Offsets: (hex) FD224 Old: B9 12 1A 4A 4A New: 20 32 FB EA EA ROM Offsets: (hex) FFB32 Old: FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF New: B9 12 1A 10 09 49 FF 1A 4A 4A 49 FF 1A 60 4A 4A 60 =========================== Headered ROM (.SMC) =========================== ROM Offsets: (hex) FD434 Old: B9 12 1A 4A 4A New: 20 32 FB EA EA ROM Offsets: (hex) FFD32 Old: FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF New: B9 12 1A 10 09 49 FF 1A 4A 4A 49 FF 1A 60 4A 4A 60 -
Edited by McMarkis
On 1/1/2021 at 1:41 PM, chaos said:NOTE: These were tested with Genesis, but I'm guessing it's the same for SNES.
I have documented all the Player Attributes + Team Bonuses + Hot/Cold Code in the SNES rom. Below are the details.
Overall very similar except for the rescaled attribute values and the HUGE Hot/Cold bug on the SNES side.Genesis / SNES Comparison:
Player Attribute Details:

Bonuses / Disadvantages:
· PP + : Positive (0 to +3) Applied to the team on the PP
· PK - : Negative (-3 to 0) Applied to the team on the PK
· Home/Away +/-: Negative or Positive (-3 to +3) based on your teams Home/Road
· Rubber Band +: Positive +2 applied when losing or tied early in the third or in OTGoalies: Do not get Bonuses / Disadvantages applied to their attributes, only Hot/Cold.
Hot/Cold function:
1) Takes a random number (-12 to +12) divides by 2 then divides by 2 again.
2) Adds this number back to the rescaled value.
3) Constraints the attribute to stay within the 0 to 15 range.
Hot/Cold Bug:
A division error on the (-12 to +12) causes HUGE fluctuations in SNES, often resulting in large positive jumps.
I would say this is similar to the GENS weight bug, in terms of being a coding errorExample of the Bug:
1.Starting Values:
- Benoit Brunet's agility was originally 2 out of 6.
- This value was rescaled to 5 out of 15. No bonuses were applied.2.Random Number Impact:
- A random number of $F5 (-11 in decimal) was generated to adjust agility due to "Hot/Cold" status.
- This number should be halved (divided by 2) twice in the calculation.3. First Division by 2:
- Instead of correctly calculating -11 ÷ 2 = -5, the instruction treats the number as if it’s positive (unsigned), which gives a wrong result of 245 ÷ 2 = 122.
4.Second Division by 2:
- The incorrect value 122 is halved again to get 61.
- This should have instead halved -5 to get -2.5.Adding the Original Agility Value:
- The program adds the original rescaled value of 5 to the incorrect 61, resulting in 66.
- The correct calculation should have been 5 + (-2) = 3.6.Capping the Result:
- Since 66 is greater than the maximum allowed agility of 15, the value is capped at 15.
- In the correct calculation, the final agility value would have been 3, which is already under the cap.**Summary:**
Due to the bug, Benoit Brunet's agility incorrectly increases to the maximum value (15) instead of decreasing to (3) as it should, because the negative number was mistakenly treated as a positive number during the calculations.
-
-
Skip EA + Flying Pucks Intro Screens
Problem:
It takes forever [24 Seconds] before you get to the "Game Setup" screen on the SNES version of 94. We would like to speed this up similar to the GENS version [4 Seconds].
Solution:Simply skip the code that loads the EA Sports Screen, and the Flying Pucks Screen. This now takes less than 4 seconds to get to the "Game Setup" Screen
Technical Details:
The code below is executed when the ROM starts up.
Code:
- Change the JSL (Jump Sub-Routine) to NOP (No Operation) to skip the EA Intro
- Change the JSL (Jump Sub-Routine) to NOP (No Operation) to skip the Flying Pucks Intro
New Code:
Download the patch tool to create your own ROM or patch an existing ROM.
Hex Version:
1) Replace old hex value with new hex value.
Headerless ROM (.SFC) ROM Offsets: (hex) F8289 Old: 22 36 F4 9F New: EA EA EA EA ROM Offsets: (hex) F82C0 Old: 22 18 B1 9D New: EA EA EA EA Headered ROM (.SMC) ROM Offsets: (hex) F8489 Old: 22 36 F4 9F New: EA EA EA EA ROM Offsets: (hex) F84C0 Old: 22 18 B1 9D New: EA EA EA EA -
Edited by McMarkis
Fix Y Button Bug Allowing Checked Players to Instantly Stand Up
Problem:
When a player is knocked down, pressing the Y button causes them to get up instantly. This behavior doesn't occur on GENS or the previous version, NHLPA 93.The knocked down player should stay down for 3 seconds as intended.
Solution:The Y button performs a 'Hook / Hold' animation when you don't have the puck. The existing code already prevents "Hook/Hold" if your player is "Speed Boosting"
- To improve this, we add an additional check when the Y button is pressed to determine if the controlled player's animation is in the 'Knocked Down' position.
- If the player is knocked down, exit the routine without performing the "Hook / Hold" animation similar to "Speed Boosting" code.
Technical Details:
The code below is executed when the Y button is pressed without the puck.
Code:
- Load the selected player animation/action, 0 = Standing, 1 = Knocked Down or Passing, 8 = Slapshot, F342 = Speed Boost
- Check if the player is knocked down
- If the player is knocked down then branch to RTL (Exit).
- If the Player is NOT knocked down then continue back to the original code.
New Code:
Download the patch tool to create your own ROM or patch an existing ROM.
Hex Version:
1) Replace old hex value with new hex value.
Headerless ROM (.SFC) ROM Offsets: (hex) F2251 Old: BD E3 14 New: 4C C5 FB ROM Offsets: (hex) F7BC5 Old: FF FF FF FF FF FF FF FF FF FF FF FF New: BD E3 14 C9 01 00 F0 03 4C 56 A2 6B Headered ROM (.SMC) ROM Offsets: (hex) F2451 Old: BD E3 14 New: 4C C5 FB ROM Offsets: (hex) F7DC5 Old: FF FF FF FF FF FF FF FF FF FF FF FF New: BD E3 14 C9 01 00 F0 03 4C 56 A2 6B -
4 hours ago, kidswasted said:
This is incredible. I wonder if slapshots will be more successful now.
Unfortunately no, this logic happens after the game has decided the puck is going in the net. I still have to find the code for shooting and goalie save logic.
But anything that was going to hit the post will now be a goal. -
Disable / Reduce frequency of the puck hitting the posts
Problem:
Reduce the Insane amount of times the puck hits the post in SNES.
Solution:
There are a few things you can do:- Remove the check to see if the puck hits the cross bar or post, this results in a goal when it normally would hit the post.
- Keep the check but make the cross bar height higher and or the side posts further out.
- Keep the Crossbar check but skip the posts check. This would probably be the best balance if you still want some posts in the game.
Technical Details:
The code below is executed when the puck is about to go into the net. As mentioned above there are a few hacks you can apply.
Code:
- Hijacking the code at this location; we can jump to the goal logic (jmpToGoalLogic) and skip all the post checks. (Always a goal, no post)
- Changing this value from #$000D to a larger hex value (000F) will make the crossbar height higher (Not visually just in code)
- Changing this value from #$0012 to a larger hex value (0014) should make one side of the net wider (Not visually just in code)
- Changing this value from #$FFEF to a smaller hex value (FFEB) should make the other side of the net wider (Not visually just in code)
New Code:
I simply chose option 1; to skip all the logic that checks if the post was hit, and always jump to the Goal Logic.
I have included that patch in the tool and the Hex example below.
Download the patch tool to create your own ROM or patch an existing ROM.
https://github.com/Mhopkinsinc/NHL94SNESVault/releases
Hex Version:
1) Replace old hex value with new hex value.
Headerless ROM (.SFC) ROM Offsets: (hex) F1230 Old: AD F9 0D New: 4C 0F 92 Headered ROM (.SMC) ROM Offsets: (hex) F1430 Old: AD F9 0D New: 4C 0F 92 -
-
Disable Penalty Shots
Problem:
Request for the option to turn off Penalty Shots.
Solution:
This hack allows you to disable Penalty Shots regardless if Penalties are On or Off.Technical Details:
The change is simple but finding it was tricky. We just have to branch to the code that signals no penalty shot.
Old Code:
1) Checks if the BreakAwayActive flag is set and if it is, Branches to 9EC068, this code sets up a flag to call a penalty shot.
2) The code at 9EC068 Sets a flag to call a penalty shot by setting the value to #$FFFF
New Code:
1) Still checks if the BreakAwayActive flag is set but now it Branches to 9EC06D instead of the 9EC068
2) The code at 9EC06D sets a flag to signal NO penalty shot by setting the value to #$0000
Download the patch tool to create your own ROM or patch an existing ROM
https://github.com/Mhopkinsinc/NHL94SNESVault/releases
Hex Version:
1) Replace old hex value with new hex value.
Headerless ROM (.SFC) ROM Offsets: (hex) F4064 Old: 03 New: 08 Headered ROM (.SMC) ROM Offsets: (hex) F4264 Old: 03 New: 08 -
Disable Interference Penalty With Penalties ON
Problem:
Request to disable Interference penalties as certain individuals despise it, and feel it is called too often in SNES.
Solution:
This hack allows you to disable the Interference Penalty while still keeping all other penalties ON.Technical Details:
This one was simple, we just have to prevent the check to assess goalie interference by skipping.
Old Code:
Modified Code: Change the BMI (Branch If Minus) to BRA (Branch Always)
Download the patch tool to create your own ROM or patch an existing ROM
https://github.com/Mhopkinsinc/NHL94SNESVault/releases
Hex Version:
1) Replace old hex value with new hex value.
Headerless ROM (.SFC) ROM Offsets: (hex) F3AA8 Old: 30 New: 80 Headered ROM (.SMC) ROM Offsets: (hex) F3CA8 Old: 30 New: 80 -
Edited by McMarkis
Pull Goalie with L+R Trigger
Problem:
Pausing the game to pull the goalie kills game flow.
Solution:
This hack allows you to pull / insert the goalie by pressing L+R trigger buttons. Also plays the beep SFX to notify users of the action.Technical Details:
Similar to the "Defense Ctrl" code injection method, we have to swap out some of the existing code and insert a jump to new code that we create. This new code will be placed in the free space at the end of the 9E bank.
Old Code:
Hijack Instruction LDY.B and LDA.W and JSR (Jump) to the new code we wrote.
Run new code that checks if the goalie is in net and if L+R are pressed for player 1 or 2.
I have included the rom to play around with or compare for differences if interested. Or you can download the tool and create your own ROM.
https://github.com/Mhopkinsinc/NHL94SNESVault/releases
Hex Version:
1) Hijack old code and point to the new code
Headerless ROM (.SFC) ROM Offsets: (hex) F50BF-F50C3 Old: A4 91 B9 AA 17 New: 20 6E FB EA EA Headered ROM (.SMC) ROM Offsets: (hex) F52BF-F52C3 Old: A4 91 B9 AA 17 New: 20 6E FB EA EA2) Insert new code that allows you to pull goalie with L+R Trigger
Headerless ROM (.SFC) ROM Offsets: (hex) F7B6E-F7BC4 OLD: FF's NEW: A2 00 00 AC 91 00 B9 AA 17 C9 00 FF D0 01 60 B9 C1 FB DD 84 1C F0 09 E8 E8 E0 04 00 D0 F1 80 2D BD 76 07 29 FF 00 C9 30 00 D0 22 B9 AA 17 F0 07 C9 FF FF F0 02 80 16 49 FF FF 99 AA 17 22 07 D4 9F A9 00 70 85 64 A9 05 00 22 7D A1 80 A4 91 B9 AA 17 60 01 00 02 00 Headered ROM (.SMC) ROM Offsets: (hex) F7D6E-F7DC4 OLD: FF's NEW: A2 00 00 AC 91 00 B9 AA 17 C9 00 FF D0 01 60 B9 C1 FB DD 84 1C F0 09 E8 E8 E0 04 00 D0 F1 80 2D BD 76 07 29 FF 00 C9 30 00 D0 22 B9 AA 17 F0 07 C9 FF FF F0 02 80 16 49 FF FF 99 AA 17 22 07 D4 9F A9 00 70 85 64 A9 05 00 22 7D A1 80 A4 91 B9 AA 17 60 01 00 02 00Limitations:
- This only works for Player 1 and Player 2, if both players are on the same team, Player 1 gets control of this option.
- Only works during game play, you can't pull / insert your goalie in between whistles.
-
-
Edited by McMarkis
Trace Logging
In this tutorial we will be taking the RAM values we found in the finding RAM values tutorial , and tracing where the code in the ROM, is writing to that RAM value. Confused?
Basically we are tracing whenever the Away teams goalie (CPU) is being pulled because of a powerplay, or in the 3rd period when the CPU is losing by 1 or 2 goals.Setup emulator and launch the game:
- This builds on the first tutorial, so I assume you already have the MESEN2 emulator installed and know how to launch the rom.
- Get the game to a position where you are winning by 1 or 2 goals in the third period with close to 1:20 minutes left. Then make a save state and pause the game.
- File ==>Save State ==>Select an empty slot
Launch the Trace Logger:
Now were going to add a trace condition to Log writes for the Away Goalies Ram Address $17AC
- Click Debug ==> Trace Logger
This looks confusing, but the only thing you really need to understand here is the trace condition.
-
#1 in the screen shot (Condtion) needs to copied from here and pasted in. IsWrite && MemAddress >= $017AC && MemAddress <=$017AD
- What this is doing is anytime a write (IsWrite) is happening to RAM (MemAddress) greater than or equal to (>=) $017AC and (&&) less than (<=) $017AD; log it to the trace window. $017AC + $017AB contains the Away teams goalie.
- #2 in the screen shot (Clear log) needs to be pressed to clear the log before you start the game again.
- #3 allows you to save the log file to your computer if you want. (Not required for this example)
Now we are going to play the game again and make sure the CPU has the puck and is over the center ice line with less than 1 minute left. This will cause the CPU to pull its goalie and we should see a trace in the log appear.
If everything goes according to plan, you should see some traces show in the Trace log window when the goalie gets pulled.
- #1 in the screen shot is the RAM value for the away goalie we were talking about $17AC
- #2 in the screen shot is the new value it was set to FF 00; this means Pulled goalie in the game.
-
#3 in the screen shot is the location in the ROM .sfc file that code executed to set the RAM value.
-
This one is a little tricker to understand. We can now look at the decompiled rom and see exactly what game code was running that sets this value. We will cover this in a more advanced topic.
-
This one is a little tricker to understand. We can now look at the decompiled rom and see exactly what game code was running that sets this value. We will cover this in a more advanced topic.
Homework:
- You now have the general knowledge to find RAM values in the emulator and then trace them to find the exact location in the ROM where that logic is.
- Use what you have learned to try and find other RAM values that you may be interested in. Maybe try and find the game clock ticking down in RAM.
- If this didn't work for you, just restore the save state and try again.
-
Edited by McMarkis
Added 2nd tutorialNHL 94 [SNES] ROM / RAM Hacking School
As a tribute to @Tony H and his ROM hacking tutorial on the GENS side, I have created a version of his tutorials for SNES.
SNES Tutorials
- Finding RAM values like the ones used to identify how the CPU pulls the goalie.
- Trace Logging RAM values to see what code is being run
Tools that you need
- SNES debug emulator MESEN2
- NHL 94' rom in .sfc or .smc format
-
Edited by McMarkis
Finding Ram Values
In this tutorial we will be searching for RAM values, like the ones used to identify how the CPU pulls the goalie. The Home and Away team goalies are stored in the emulators RAM, we will learn how to find those values in RAM by doing a simple search in the emulator.
Tools that you need:
- SNES debug emulator MESEN2
- NHL 94' rom in .sfc or .smc format
Setup emulator and launch the game:
- Launch the emulator and load the rom ==>File ==>Open
- (Optional, keyboard works fine) Setup your joystick under settings ==> Input ==> SNES ==> Port 1 Setup
- Setup a Regular Season game and navigate to the Start Game screen
Launch the Memory Search:
Now were going to do a simple Memory Search to find the starting Home Goalie Ram value
- Click Debug ==> Memory Search
- #1 in the screen shot (Compare To) needs to be set to Previous Search Value
- #2 in the screen shot (Operator) needs to be set to Equal
- #3 in the screen shot will apply the Search filters to all the Work RAM memory, Go ahead and click the Apply Filter button.
- Results: You can't tell right now, but the results have filtered out some of the RAM values that have changed, this is good.
Now we are going to change the Goalie to Racicot and perform another search, because we increased the goalie from the first Goalie - Roy to the second Goalie - Racicot, we want to search for RAM values that have increased (Greater than).
- #4 in the screen shot (Compare To) needs to be set to Previous Search Value
- #5 in the screen shot (Operator) needs to be set to Greater than
- #6 in the screen shot will apply the Search filters to all the Work RAM memory, Go ahead and click the Apply Filter button.
- #7 in the screen shot shows the results, we have filtered down a lot of values, this is good.
Now we are going to change the Goalie back to Roy and perform another search, because we decreased the goalie from the second Goalie - Racicot back to the first Goalie - Roy, we want to search for RAM values that have decreased (Less than).
- #8 in the screen shot (Compare To) needs to be set to Previous Search Value
- #9 in the screen shot (Operator) needs to be set to Less than
- #10 in the screen shot will apply the Search filters to all the Work RAM memory, Go ahead and click the Apply Filter button.
- #11 in the screen shot shows the results; wow, we have filtered down to 2 values. One of these is our Home teams Goalie RAM value. $126D or $17AA
One last trick here is to leave Roy as the starting goalie, making sure you haven't changed it from the last search, and start the game. We can apply another filter during game play for RAM values that haven't changed (Equal).
- #12 in the screen shot (Compare To) needs to be set to Previous Search Value
- #13 in the screen shot (Operator) needs to be set to Equal.
- #14 in the screen shot will apply the Search filters to the remaining Work RAM memory, Go ahead and click the Apply Filter button.
- #15 in the screen shot shows the results. Only one value left $17AA, this is our Home teams Goalie RAM value.
Now you can see the value for $17AA change from 00 (Roy) to 01 (Racicot) or FF (No Goalie)
Homework:
- Using the same steps above, see if you can find the Away teams RAM value. Just make sure you set your controller to the away team for this exercise.


NHL '94: Wide Display Mode (“widescreen”) Hack v2.0
in Sega Hacking Projects
I found it in the 92 code, I can move the whole faceoff window over. The bad news is it just adds to x, so it will always push it right. Is that what you wanted?

I still have to map it to the 94 code where its happening. But progress