Jump to content
NHL'94 Forums

Leaderboard

Popular Content

Showing content with the highest reputation since 04/12/2024 in all areas

  1. For those who don't want to watch me ramble for over an hour on my stream (btw stream is here - https://www.twitch.tv/videos/2120586640) Using the source code from 92 (Link - NHL Hockey Source Code), we are now able to find out how things work a lot easier than finding a needle in a haystack like we had done in the past. NHL94 has improved upon 92, but much of the code is the same (with some refinements and added things, like bonuses). The most important thing is we have an idea how the RAM is laid out (basically all the variables for the game). How does checking work in 94? Weight is involved. Where you are on the rink is involved (You're getting checked against the boards? You're getting knocked down). Checking rating is involved. Also, impact value is involved (how hard you are hitting depending on your velocity and your opponents velocity, and the distance between the 2 of you). Are you controlling the player checking, or is the AI? Also, the weight bug (lets lighter players check heavier players, regardless of a lot of factors above) - Here's the checking formula for 94: Check if checking player is in checking animation If impact value is more than 20 decimal, the check will initiate. If not, there will only be momentum transferred between the 2. Starting value for calculation (120 decimal or 240 decimal if player controlled) - Subtract (Wgt * 8) of player checking - Add (Wgt * 8) of player being checked - Divide total by 2 - Check if player will hit the wall (see below) - Subtract impact value - If the total is 0 or negative, proceed to knock down. - If total is positive, then check if player will hit wall. If he will, proceed to knock down. - If total was positive, and player is not near a wall, then randomize the result from above (the RNG will choose a number >= 0 and < result from above) - Load the checking attribute (which is Chk rating * 5 + bonuses (Hot/Cold and 3rd Period Bonus). Divide it by 2 (Value will be between 0 and 15) - Next, subtract Checking value from above from the RNG result. If the answer is <= 0, then proceed to knock down. If positive, then check Agression attribute and see if there will be a penalty from the hit. Knock down section also checks for penalty from contact, but there is slightly less of a chance of a penalty compared to them not getting knocked down. After this part of the code, it will check for toddle (related to stickhandling). This checking formula is almost the same as it is in 92, except for the fact that some math is different (there's no bonuses, attributes are on a 0-15 scale instead of 0-6), the starting value for ALL checks is 60 decimal. In 94, the attributes are stored in RAM with a 0-30 scale (which is why you see a divide by 2 in a few places here). What's the weight bug problem? Lighter player can check heavier players with ease, when player controlled. This is because of the large boost given to the starting value. The subtracting and adding of the weight in this formula is done "byte" size, which means that value can never be over 255, it will overflow and 256 = 0 (it will start over at 0). Because of this, the rest of the calculation is pretty much thrown out the window (impact value will play a very small role in a weight bug check). So how to fix the weight bug? Remove the boost to the starting value when player controlled. I believe this may have been left in during testing, since the formula itself is almost the save as in 92. If the starting value was set to 120 decimal for both AI and player controlled checks, we would see much more "realistic" results. Weight difference won't be a huge factor anymore (still a bit of a factor), but impact and checking attribute would play more of a role. What's impact value? This is something I was able to figure out using the source code. The game tracks the velocity of the players (speed + direction). When it senses 2 players are close enough for contact, it will calculate a transfer of momentum between the players (when players hit, they slow down, bump each other back, etc). So it will calculate impact based on the velocity of both players, and the distance between them. The players speed is controlled by their acceleration, which in turn is controlled by Wgt and Agl attributes. So the faster a player is going, the more impact they will cause. If 2 skaters are skating at each other, the impact will be higher. If a player getting checked is skating away from the checker, the impact will be lower. If you hit the player near the end of your speed burst, the impact may be lower (not going as fast as you originally were). Funny thing is even with the weight bug, its actually harder for Theo Fleury (3 wgt) to check Marty McSorley (14 wgt), than it would be for him to check someone like Mats Sundin (7 wgt). He needs some impact to check Marty, where as with Mats, as long as he meets the minimum impact value to initiate the checking calculation, hes knocking him down. Here are some examples with weight and impact: 4 wgt checking (player controlled) a 10 wgt with minimal impact just makes it to the knock down phase (-4). 4 wgt AI player can do it with a ton of impact though (and some RNG luck). Closer weights here. 5 wgt AI checking a 7 wgt player with 50 impact value can definitely have a shot with some RNG luck (RNG result would be between 0 and 18 here), then subtracting the Checking attribute (0-15 scale after divide by 2). Marty McSorley might be able to survive this check from Theo Fleury with the right RNG and minimal impact. AI controlled Mario Lemieux might struggle knocking down Mike Gartner with low impact. Gotta get a good RNG roll (low value here).
    6 points
  2. With the checking source discovered, am I the only one who wants to know how to tweak the values? I'm thinking along the lines of increasing the range of effect, so you can go from half the dudes no-selling like a jabroni to now half the dudes flipping out like Hong Kong kung fu movie minions. Too much?
    2 points
  3. 1 point
  4. The RNG function needs a value sent to it and returns a result. In the Hot/Cold thread, you are only changing the value being sent to the RNG function for Hot/Cold. The RNG function has 2 different ways it can be used: - Sending it a value, and it will give a result of (- value <= result < value) - Sending it a value and it will give a result of ( 0 <= result < value) Hot/Cold uses the first way, Checking is using it the second way. The RNG function is used all over the place.
    1 point
  5. Last night was the best night of games all year. What a finish. Sorry about your Wings though, I was rooting for them. That Perron goal sent me through the roof!
    1 point
  6. 00344 - Located in: Lafitte, Louisiana, United States H07136 - Located in: pictou, NS, Canada H24460 - Located in: Bentleyville, Pennsylvania, United States A17558 - Located in: Mankato, Minnesota, United States A24244 - Located in: South Elgin, Illinois, United States
    1 point
  7. This is a really interesting concept and the contrast is well done (haven't had a chance to see it in action yet) but I'm also hoping reception was favorable enough for a color version. 😉
    1 point
  8. Well with the wife away all weekend and into next week Ill get more completed. The schedules is trickiest thing. But they are date accurate.
    1 point
  9. Hey there - I’ve moved my efforts to working on a mod for NHL Legacy just so I have more surfaces to mod and make something more realistic. It runs on less devices because it has a high CPU overhead, but it’s had great results (see attached). Sadly I only have time for one mod lately, so this mod is not going to be worked on much more (if ever).
    0 points
×
×
  • Create New...