Jump to content
NHL'94 Forums

chaos

Admin
  • Posts

    2,105
  • Joined

  • Last visited

  • Days Won

    83

Everything posted by chaos

  1. The code to determine if there will be an injury is in the FallDown subroutine at 0x14428 (move.l #$A0, d0). The subroutine to determine injury type starts at 0x144AC. I updated the post above.
  2. Here's a GIF with the value at 0xAC1D set to 03 instead of 09. You are right! The puck slows down. Upon further investigation, it seems that the puck always has the flag pfdoff set to ON. So it will always be using this value on deceleration (when it is on the ice. If there is any Z height to the puck it won't decelerate like this). Players will also use this when decelerating for a pass though.
  3. Here's GIFs. First one is vanilla 94. Second one is with the value at 0xAC11 changed to 03 (from 06)
  4. I edited my above post. When receiving a pass they will not slow down as much. A higher number means less reduction to velocity. That value at AC10 is being used as a divisor in a way. It's being used to shift the velocity x number of times (in original case, 6 times). Which would divide the velocity by 64 in the case of 6. That result is then subtracted from the velocity and stored as the new velocity. So a lower number, the faster the deceleration, since the result before subtracting is higher.
  5. #1 - Yes, this code: ROM:0000AC10 7406 moveq #6,d2 ROM:0000AC12 082B 0000 0062 btst #0,$62(a3) ; pfdoff - player deceleration ROM:0000AC18 6700 0004 beq.w _off ROM:0000AC1C 7409 moveq #9,d2 is testing for a flag that is set when the player is assigned to receive a pass. EDIT: They will slow down at a slower rate (9 instead of 6). You can look in 94 source code at the asspassrec subroutine. #2 - So AC05 is a weird one. ROM:0000ABFA 7811 moveq #$11,d4 ROM:0000ABFC 4A78 D06E tst.w (word_FFD06E).w ROM:0000AC00 6700 0004 beq.w _notoside ROM:0000AC04 7816 moveq #$16,d4 So the $11 is used as the factor with the velocity before adding it to the player's position. In the 92 source, it's looking to see if the player is offsides here, and if so, will make them "appear" to skate quicker to get onside, by using $16 instead of $11. 94 has this test of a variable instead. The problem is, this variable is only set on startup (in the Begin subroutine), and the value stored in it is related to the VDP Control. I've never seen a situation yet when it was set, it always seems to be 0. So it will always skip 0xAC04 instruction. 92 does this whole part differently.
  6. No, finding that was pretty impressive without looking at the disassembled code!
  7. Hi Adam, @kingraph pointed this out on Discord to me. Just to give you a better explanation, this is used for deceleration of the player and the puck in "normal" situations. It is used as a divisor to the player/puck's velocity. Every frame, the player decelerates. Acceleration is done separately if needed (input from dpad). At 0xAC1D, the value of $09 is used when the player needs to slow down quicker (to receive a pass from another player). At 0xABFB, the value of $11 is multiplied with the velocity before adding it to the X or Y position of the player. You can probably mess with any or all of these to change the physics of skating.
  8. It would just make everything like a CB check, since CPU and player would use the 120 decimal as a base instead of the 240 for the player. Also, lighter wgt players can still have a chance of knocking down heavier players if checking at speed. This would increase the impact of the check, and also use the Chk rating and RNG.
  9. What the CB check fix does is just make all checks starting with the 240 base value. The fix above removing the bit shift makes all checks use the 120 value. You can 4E71 all of that if you want, and get the same effect as removing the bit shift
  10. I just checked the AI suggested code with the LSL, it should work as intended. It's possible an opcode is messed up. Just stick with your code
  11. Keep your code if it works fine. Did you add the change I made? The code McMarkis posted won't work because it's not Exclusive ORing the right bits. Needs that LSL.B #7, D1 part
  12. The hand byte is $0076 in 94 FYI. ($74 is Fight) Not sure if this would work. The hand orientation is just one bit, and the flag for which net they are shooting on is bit 7 of 62. So when you EOR, it would be comparing bit 0 of 62 offset, which is the deceleration bit. You would have to do an LSL.B #7, D1 before the EOR to line up the bits. I feel like there could be an easier way to do this, but this should work, and who cares, we aren't crammed for space. CB8C is the ROM location in 94 for the code where you want to inject (tst.b($76(a3))
  13. Yeah, I did a lot of testing to see when the Glv/Stk values are read and used. I think the Ovr is just a holdover, and like @AdamCatalyst said, the Overall isn't saved anywhere, it's just calculated when needed. My guess is they made this change to improve the goalie. Though the Overall does favor Agl, PkC, and DfA, which are the most important attributes for a goalie.
  14. In 92, according to the source code, Glv and Stk rating were used to determine if a rebound would occur, or the goalie would hold onto the puck. It also took in account the frame animation. So the higher the value, the sooner in the frame animation the goalie can make the save. This code is still there in 94, with some changes. But, the code never uses the value in any calculation. It just ignores it, and uses Puck Control instead. The GlvR is the only one used, in a case where the goalie can make a glove save if the value is above a 2.2 (so a 2 with a +1 Hot/Cold rating). This is used during save selection, which is a whole different routine. I'll do a writeup soon about goalies. I haven't done all the research on them yet, since its much different than how 92 does it (you can skate with a goalie and control it in 94, unlike 92), but I am 99.5% sure the Glv/Stk ratings don't matter.
  15. 94 uses Puck Control. It has all those look up tables, then does nothing with them. Which is a real shame, because I thought that was a great idea. The Glv/Stk ratings of a goalie in 94 dont matter.
  16. The problem is related to how it checks where the puck is. The other positions, it will check both sides of the rink (goal line and blue line). For some reason, center only checks one side of the rink. In the 92 source, it's checking both sides, so in 92, the C will behave like it should (when puck is in offensive zone on defense, they will sit near offensive blue line). This should be an easy fix, I just haven't looked at it deeply.
  17. This is true! Have to port over the sprites and animations though. It's essentially possible though
  18. The wingers have 2 specific player assignments: asswingo and asswingd. These are used by the CPU to determine what the RW and LW should usually do when their team has the puck, or when their team does not. asswingo - Winger on offense When the team has the puck, the winger (when he doesn't have the puck) will have the asswingo assignment. Depending on where the puck is, the RW and LW will skate to different zones on the ice. Take a look at the photo of the rink and its colored zones (in this photo, the team is shooting at the top goal. Everything will be referenced like that): The rink has extra areas marked on it. There is a line going up the center of the ice to divide the rink in half horizontally (X direction). I also lightly shaded the area in the offensive zone here the game considers the "slot". The location the RW and LW skate to inside the zones will be randomized. When shooting up in this case, the LW will be in the left side zones, and the RW in the right side zones. When their team has the puck: - In their defensive zone, the LW and RW will skate to the lower zone right above their defensive blue line, near the face-off dots. - In the neutral zone, the wingers will skate to the upper zones right below the offensive blue line (yellow). - In the offensive zone, the wingers will skate to the blue zones. - Below the goal line in the offensive zone, the wingers will skate to the reddish zones. The wingers react a little differently than centers. When calculating what zone to skate to, the puck's velocity is also taken into account. For example, if the puck is going to be crossing into the offensive zone, the wingers will already be skating towards those zones, whereas the center will wait until it enters the zone. When playing with offsides, the wingers most likely will be offsides more often than other players. Once the RW and LW skates to their location, they will stay there. The game uses the puck location in reference to the blue lines and goal lines to determine where to have the wingers will skate to. So in a way, you can "reset" their position in the zone by moving the puck over one of the lines and back. This will change the RNG, and the wingers will skate to a different spot in the zone. There's also a small chance their position will be reset while waiting based on the frame counter, without having to move over the lines. Defensive Awareness is used by the RW and LW as a "timer". The higher the Awareness, the lower the timer. When the timer is up, the game will check if the winger should skate to a new location. It will also check if the winger needs to switch to defense. So a longer timer (lower DfA), it will take longer for the winger to react to the change. If neither team has the puck (loose puck), the wingers will still skate to these zones depending on the puck's location. If one of the wingers is the closest to the loose puck, they will end up being switched to assnearest and try to get the puck. Should also note that the game does check if the player is offsides (if offsides is on) when the Awareness timer is up. It will move the player out of the offensive zone if needed. asswingd - Winger on defense On defense, the game will check where the puck is. If the puck is in the defensive zone, it then checks if the puck is past the goal line (behind the net area). If the puck is behind the goal line, the winger will move to the goal line in Y. In X, it will move to the same X position as the puck if the puck is on the wingers side of the rink, and will move to 100 pixels from center if the puck is on the other side of the rink. For reference, that is halfway between the face-off dot and the boards. If the puck is in the defensive zone, but above the goal line, it will move to 158 pixels from center ice in Y and will move the same as above in X. In Y, this is inline with the top most light reflections if defending the top zone. If the puck is out of the defensive zone, it will move to the same Y as the puck, and it will move the same as above in X. This will usually cause the winger to forecheck, causing the winger to switch to assnearest more often than other skaters. Defensive Awareness is used by the wingers as a "timer" here as well. When the timer is up, the game will check which team has the puck. If the other team still has it, the wingers will stay on asswingd. If their team has it, they will switch to asswingo. If the puck is loose, the wingers will stay on asswingd, unless they are the closest to the puck, which then they will get the assnearest assignment.
  19. The center has 2 specific player assignments: asscentero and asscenterd. These are used by the CPU to determine what the Center should usually do when their team has the puck, or when their team does not. asscentero - Center on offense When the team has the puck, the Center (when he doesn't have the puck) will have the asscentero assignment. Depending on where the puck is, the Center will skate to different zones on the ice. Take a look at the photo of the rink and its colored zones (in this photo, the team is shooting at the top goal. Everything will be referenced like that): The rink has extra areas marked on it. There is a line going up the center of the ice to divide the rink in half horizontally (X direction). I also lightly shaded the area in the offensive zone here the game considers the "slot". The location the C skates to inside the zones will be randomized. - When the team has the puck in their defensive zone, the C will skate to the lower zone right above their defensive blue line. - When the team has the puck in the neutral zone, the C will skate to the upper zone right below the offensive blue line (yellow). - When the team has the puck in the offensive zone, the C will skate to the blue area. - When the team has the puck below the goal line in the offensive zone, the C will skate to the reddish area. Once the C skates to their location, they will stay there. The game uses the puck location in reference to the blue lines and goal lines to determine where to have the C skate to. So in a way, you can "reset" the C position in the zone by moving the puck over one of the lines and back. This will change the RNG, and the C will skate to a different spot in the zone. There's also a small chance their position will be reset while waiting based on the frame counter, without having to move over the lines. Defensive Awareness is used by the C as a "timer". The higher the Awareness, the lower the timer. When the timer is up, the game will check if the C should skate to a new location. It will also check if the C needs to switch to defense. So a longer timer (lower DfA), it will take longer for the C to react to the change. I should also note that if neither team has the puck (loose puck), the C will still skate to these zones depending on the puck's location. If the C is the closest to the loose puck, they will end up being switched to assnearest and try to get the puck. asscenterd - Center on defense When the opposing team has the puck, the C will be switched to asscenterd to play defense. Defensively, the C will keep half the distance from the center of mid ice in X and the puck. When the puck is out of the defensive zone, the C will skate in Y half the distance between the high defensive slot and the puck. For example, if the puck is at center ice in Y, the C will skate to a little above their blue line. If the puck is at the offensive goal line, the C will skate to a little below (in the neutral zone) the offensive blue line. If puck is in defensive zone, the C will stay halfway in between the puck and center ice in X, and will stay at in the upper slot in Y. When looking at the rink photo above, if he is defending the top zone, he will stay in the same Y as the second set of light reflections. Defensive Awareness is used by the C as a "timer" here as well. When the timer is up, the game will check which team has the puck. If the other team still has it, the C will stay on asscenterd. If their team has it, they will switch to asscentero. If the puck is loose, the C will stay on asscenterd, unless they are the closest to the puck, which then they will get the assnearest assignment. There’s a bug! If you are defending the top zone, your C will skate towards center ice from your defensive slot as the puck moves towards center ice. Once it passes center ice, the C will actually skate past the puck. If you are defending the bottom zone, your C will stay near the offensive blue line when the puck is deep in the offensive zone, and will skate backwards while the puck moves towards the center line and your blue line. This bug only affects the C. Jamie Baker at the proper location when defending the lower zone: Jamie Baker not at the proper location defending the top zone:
  20. The game uses "assignments" for the players (and the puck) to tell them what to do and in what situations to do them. For example, there's an assignment to hold the Stanley Cup after winning the playoffs, an assignment to go to the bench, or go to the penalty box, fist pump when you score, stop the puck from flipping, etc. Below is the list of assignments. Some of them are straight forward with their descriptions: (yes, there is an assfight and assfwatch, but unfortunately, they are empty) A majority of these assignments are specific to CPU players. Some of them are used by "joystick" controlled players, as the NHL92 source code likes to call it. I haven't found the name of one of them, though I think it's to make the CPU goalie skate to get the puck in the corner, but it also might not be used anymore. Each player has a list of assignments. They can be done in order, or a new one can be forced to start immediately (it will replace the current assignment). Depending on situations that are checked, the assignment can be changed on the fly. Many of these assignments are temporary, like assscore and assstanley. Once these temporary assignments are done, the game will "exit" them and move to the next assignment. Some assignments have permanent spots on the assignment list. They are always on there. These are assignments that are specific to a position, and is what the CPU player will be doing in most cases. These are near the top of the list, the "Os and the Ds". A CPU player will either be doing the offense assignment, or the defensive assignment in most cases. These assignments tell the players where to go on the ice relative to where the puck is. For example, if the puck is in the attack zone, those players on offense that do not have the puck will skate to specific zones, and their position in the zone is randomized. The CPU player with the puck will have a different assignment, called "asspuckc". This assignment would be used to determine if the CPU player will shoot or pass, where they will skate to, etc. The players on defense will also go to specific zones, and the one nearest the puck will get a special assignment called "assnearest". This player will possibly attempt to check the player with the puck, and will be the more aggressive one on defense. Each loop through the assnearest assignment, the game will check and see if there is a defensive player closer to the puck, and will change assignments if needed. The assnearest assignment is also given to players on both teams that are nearest to a loose puck. Those players will attempt to retrieve the puck for their team. I will post more detail about each offense and defensive assignment, along with the assnearest assignment, as these are the most important ones.
  21. In the game, a player can get injured for the game, or injured for the period. But there are some players who can never get a game injury (except if they get hit by a goon, more on that later)! What causes an injury? When the game determines a player is getting knocked down (the check is successful), it will check if there should be an injury. The impact value of player will be used in the calculation. To determine if there will be an injury: (starting at ROM address 0x14428) - Start with $A0 (160 decimal) - RNG (result will be from 0 up to 160 decimal) - Compare the impact of the player to the result (the impact value is calculated when the 2 players are about to collide, using their weight and velocity). - If the RNG result is higher than the impact, there will be no injury. If it is lower or equal to the impact, there will an injury, as long as the clock is running (no injuries post whistle) I should note that the impact value is cumulative. If the player was recently hit into, but survived the check (did not fall down), they will have a previous impact value stored. This value will decrease by 1 each frame (there are 60 frames in a second in Genesis). So if there are 2 checks in quick succession, the impact value will be much higher than from a single check. Also, any player collision causes impact, not just a check (bumping into a player for example, or getting hit by the puck). Injury for the period or game? Once the game determines there's an injury, it will now figure out the type of injury. In this case both the player who caused the injury and the player who is getting injured is used to figure this out. Each player has an H/F attribute byte, which stands for Hand/Fight. Now fighting is not in NHL94, but the Fight byte is used to determine injury type. The Hand part of the byte is just the first bit, which would make the number even or odd. The Fight portion of the byte is always even. For example, Jeremy Roenick has an H/F byte of 3. The number is odd, which makes him a Righty. His fight portion of the byte is 2 (round the odd number down to an even number to get the Fight). Alexnder Mogilny has an H/F byte of 4. The number is even, making him a Lefty. His fight portion of the byte is 4 (no rounding needed). Code to determine if injury for game or period (subroutine starts at 0x144AC. The starting code is for scroll locking on the injured player, and adding to the crowd meter. This part of the code starts at 0x144FE): - Get the Fight byte of the player checking, and divide it by 4 (no remainder) - Check if the result is 0 (which would be an H/F of 3 or below) - If zero, the injury will be for the period - If not zero (H/F of checker 4 or above): - Check if the result was 3 (H/F of 12, which is the max) - If it was 3, player is injured for the game - If less than 3 (H/F is 4-11): - Check the Fight byte of the player being injured - If the Fight byte is 2, 6, or 10 (H/F 2,3,6,7,10,11), the player will be injured for the game. - If the Fight byte is 0, 4, or 8 (H/F 0,1,4,5,8,9), the player will be injured for the period. There are 5 "goons" in the game with an H/F of 12. When these players cause injuries, they will always be for the game: Grant Ledyard (BUF) Louie DeBrusk (EDM) Shawn Cronin (PHI) Tony Twist (QUE) Basil McRae (STL) In all other cases, player that have an H/F of 0,1,4,5,8 or 9 will never be injured for the game. So in the above example, JR will be injured for the game if he's injured by a player with an H/F of 4 or above. If Mogilny is injured, it will always be for the period, unless by one of the goons, then it's for the game. Another fun example: If Mogilny injures JR, it will be for the game (Mogs H/F is a 4).
  22. Should be much harder for lighter guys to check heavier guys. Heavier guys should be able to check lighter guys
  23. A League Champs: S1: Uncle Seth S2: angryjay93 S3: Uncle Seth S4: kingraph S5: angryjay93 S6: Uncle Seth S7: Corbettkb S8: angryjay93 S9: angryjay93 B League Champs: S1: sonoffett87 S2: hokkeefan2 S3: Tickenest S4: szpakman S5: kazelegend S6: Wittgenstein S7: INDIO * (replaced skankhunt42) S8: jv S9: kidstwasted C League Champs: S2: INDIO S3: TecmoDPS S4: Charlesworth S5: Big Valboski S6: skankhunt42 S7: SOH S8: NewJerseyKiller S9: Stantonator Draft Cameos: S2: Jeremy Roenick S3: Luc Robitaille (no show) S4: Russ Courtnall S5: Teemu Selanne S6: None S7: None S8: None S9: None CDL Season 10 I plan on starting this league in a few weeks. I will give it till 1/3/25 for S9 players from A, B, and C Leagues to let me know if they are returning. Once the time is done (or I've heard from everyone), there may be some open spots. Open spots in A will be filled by previous A league caliber players (ones who have played in A and still qualified to stay in A), or I will do a play in of sorts from top B teams to determine replacements (though I doubt we will need this). Open spots in B will more than likely be filled by C league players from S9, with a play in as well. This all depends on who signs up. There may be exceptions to the rule (where someone of B quality returns, they would participate in the play-in as well). Note, the only thing holding up the draft will be A and B signups. Once this is figured out, I will announce the start of the draft (along with the draft order). Draft show TBD. C league signups will be open up to the day of the A/B League Draft, and are open to anyone. Current league cap is 26. This may change, depending on signups. C league signups will be limited to the number of A/B league teams. Relegation and Promotion The criteria is still the same. Last season we had 13 teams in A, and 13 in B. 2 players from A will be moving down (worst reg season record, not counting the fill-ins), 2 players from B will be moving up to A, and another 2 moving down to C, and at least 1 player from C will be moving up to B (the other will either be the top reg. season winner, or the result of a play-in). As of right now: Moving up to A - kids wasted (B Champ) and Chris O (next best reg season record based on tiebreakers) Moving down to B - Dantml7 (.229 win PCT) and szpakman (.091 win PCT) Moving up to B - Stantonator (C Champ) and skills324 (best reg season record) Moving down to C - niuhuskie (.417 win PCT) and LeifErikson (.229 win PCT). If there is a play-in for B, both will be allowed to play. Again, this could change, depending on who is returning, signing up, etc. There could be more movement. Sign-ups C League is more of like a "farm" league, where coaches will choose (via a Team Selection Draft) one of the drafted A/B teams to play a season with, continued with a playoff. The C Champ and the team with the best reg. season record will be promoted to B league the following season, and allowed to partake in the A/B draft. This league is geared more towards the guys who are more novices at the game, especially draft leagues. They can choose a team during the Team Selection Draft that fits their abilities. C is open to any player whose setup has been CONFIRMED to work (they will have a role assigned to them in Discord). Sign-up deadline will be the day of the A/B League Draft, and cannot exceed the total amount of A/B teams (currently 26). League spots are for CDL9 returnees first. Empty spots in A and B will be filled by my choice; see first paragraph. Draft News Once A/B returnees all report, and I fill out the remaining spots, I will post the draft order. The draft order will use the previous season's record as a base. The A champ will pick last in the list, the B champ will pick 15th, and the 2nd promoted player from B will pick 18th. The 2 teams from A that were relegated will pick 16th and 17th. The C champ will pick 5th, and the 2nd promoted player/winner of play-in will pick 8th. The rest of the selections will go by winning pct and playoff performance from CDL 9, regardless of A or B league. As far as the draft show, we will do a post A/B draft show, analyzing the teams and hopefully giving some insight that can help the C league players before their Team Selection Draft. League Info Stuff not changing from S9: - 5 min periods, 10 min OT, 1 min Penalties - Quicker control and longer range of Goalie - 0 Team Bonuses and PP/PK bonus - Warm/Cool Bonus (very slight hot/cold, attributes in the Edit Lines screen will be accurate) - Small Home Team Bonus in the Playoff ROM (+1), to make home ice a little more meaningful. - Reduced Penalty Shot timer Stuff changing from S9 and previous seasons: - Goalie Boosts - +1 to Agl, +1 to DfA, +1 to PkC (previously +1 Agl, and +1 to all Stk/Glv). All Stk/Glv will be returned to normal values. After scouring the code, Stk/Glv do nothing. They were previously used in NHL92, but 94 uses Puck Control instead. Puck Control is used to determine if the goalie holds on to the puck after a shot, or if the puck will bounce off for a rebound chance. . DfA is used to assist in the goalie in tracking the puck. The goal of this league was to always give the goalies an advantage over the regular ROM. We'll see how these changes affect game play this season! Rules Warning! There are glitches in the game. A majority of them are unavoidable. Some of them are able to be triggered. In this league, anything goes. If a glitch causes a goal against you, you are free to talk about it with your opponent and decide an outcome, and come to an agreement. But there is no rule stating they have to reciprocate the goal. Double penalty shot? Play to the whistle. Next time blow your opponent out if he does something to piss you off. One rule regarding pulling the goalie - It must be done while having possession, or before a faceoff in the offensive or neutral zone. Let me know if you are returning or not, by posting below, or in this Discord thread - CDL10 Signups and Returnees. If I don't hear from you, I will assume you are not returning. List of returnees:
  24. That's interesting, because according to the code, it should skip those instructions if in vertical mode. I wonder if you are skipping setting the horizontal flag in your modified code somewhere. btst #sfhor,sflags beq .nhor exg d0,d1 neg d0 sub #horoff,d1 bra .crange .nhor sub Hpos,d0 sub Vpos,d1 The btst instruction is testing if the bit is set or not. It's checking the #sfhor flag, which is set when in horizontal mode (side bar). The beq instruction will branch the code to .nhor if the bit is not set (beq meaning the previous instruction set the conditional "Zero" flag, which is set when the check reads a zero or "cleared, not set"). And the label .nhor stands for "not horizontal" I'll have to try this out on a regular ROM and see how it works
  25. Looks like this part of the code in 92 source in VIDEO.ASM: find3d sub routine horoff = 197 find3d ;input - d0=xfield,d1=yfield,d2=height off field ;output - d0=xscreen,d1=yscreen btst #sfhor,sflags beq .nhor exg d0,d1 neg d0 sub #horoff,d1 bra .crange .nhor sub Hpos,d0 sub Vpos,d1 .crange cmp #128+16,d0 bgt .offscr cmp #-(128+16),d0 blt .offscr add #128+128,d0 add d2,d1 asr #1,d2 add d2,d1 cmp #112+32,d1 bgt .offscr cmp #-(112+32),d1 blt .offscr neg d1 add #112+128,d1 rts .offscr move #osflag,d1 rts You are changing the add #128+128, d0 instruction. Maybe for horizontal, you can try changing the sub #horoff, d1 instruction. The value #horoff is $C5 (197 dec). you can change this value at 16931 in the 94 ROM (currently C5). It won't run this instruction if you are in vertical mode, so worth just trying to adjust that.
×
×
  • Create New...