Home › Forums › Destiny of an Emperor › MidKnigT about that Critical Formula…
- This topic has 14 replies, 2 voices, and was last updated 14 years, 6 months ago by
MiDKnighT.
-
AuthorPosts
-
October 17, 2011 at 7:58 pm #5224
sonic.penguin
ModeratorAfter tinkering with it, and testing at 00, most hits are acquiring the notation of "officer did critical damage" however, damage done is not critical and doesn't make the "snapping" sound of a critical hit. I have a feeling that 39948 does not contribute to adding critical hits even though it says it does. Any ideas?
October 17, 2011 at 8:34 pm #39552MiDKnighT
ModeratorI'll look into it further. It's obviously doing something because it's telling you that you scored a critical hit but perhaps there is more to the formula that we haven't uncovered yet.
October 17, 2011 at 8:47 pm #39553sonic.penguin
ModeratorQuote:I'll look into it further. It's obviously doing something because it's telling you that you scored a critical hit but perhaps there is more to the formula that we haven't uncovered yet.I thought the same thing. But that only tells you that critical damage is scored, but doesn't contribute to critical damage rate. You should be able to see in your damage that it is around the normal range
October 17, 2011 at 8:50 pm #39554MiDKnighT
ModeratorQuote:I thought the same thing. But that only tells you that critical damage is scored, but doesn't contribute to critical damage rate. You should be able to see in your damage that it is around the normal rangeHow are you seeing this? You won't really see it with Rebel force and such hitting you as their damage isn't much to begin with.
I was seeing damage increases by generals with this.
October 17, 2011 at 9:18 pm #39555sonic.penguin
ModeratorQuote:How are you seeing this? You won't really see it with Rebel force and such hitting you as their damage isn't much to begin with.I was seeing damage increases by generals with this.
Take note of damage on anything. If you set the value to 00 which is crit every hit, every hit should go "fzfzfz" and deal around 2x damage. What happens is every hit "says" critical hit, but you dont have the sound fx or the damage increase.
October 17, 2011 at 10:19 pm #39556MiDKnighT
ModeratorOK I'll test it out later.
October 20, 2011 at 4:05 am #39557MiDKnighT
ModeratorNote to self:
00:9826:85 14 STA $0014 = #$26
00:9828:B9 14 E7 LDA $E714,Y @ $E718 = #$00
00:982B:85 15 STA $0015 = #$00
00:982D:98 TYA
00:982E:0A ASL
00:982F:A8 TAY
00:9830:BD 9C 61 LDA $619C,X @ $61AB = #$B9
00:9833:D9 40 E7 CMP $E740,Y @ $E744 = #$00
00:9836:B0 0C BCS $9844
00:9838:BD A8 61 LDA $61A8,X @ $61B7 = #$81
00:983B:D9 41 E7 CMP $E741,Y @ $E745 = #$00
00:983E:B0 04 BCS $9844
00:9840:46 15 LSR $0015 = #$00
00:9842:66 14 ROR $0014 = #$26
00:9844:20 63 C1 JSR $C163
00:9847:A5 7C LDA $007C = #$AD
00:9849:C9 F0 CMP #$F0
00:984B:90 04 BCC $9851
00:984D:A9 33 LDA #$33
00:984F:D0 0C BNE $985D
00:9851:A5 AD LDA $00AD = #$CF
00:9853:65 AE ADC $00AE = #$E3
00:9855:85 AD STA $00AD = #$CF
00:9857:29 0F AND #$0F
00:9859:AA TAX
00:985A:BD 38 99 LDA $9938,X @ $9947 = #$13 <– value being used to calculate damage
October 20, 2011 at 12:41 pm #39558MiDKnighT
ModeratorThe "random" value is stored in $007C. The problem before was that we check this value several times. Ie…we compare it for the critical hit text, we compare it for the boom sound, we compare it for the high hit. We need for:
– The random value to be higher
or
– Change every comparison…
I like the first option better. Looking at the code to find a way.
October 20, 2011 at 1:11 pm #39559MiDKnighT
ModeratorGot it!
I'm using the 2nd option due to lack of space to add new code (not worth adding it somewhere else). There are 3 checks:
00:AC19:A6 7C LDX $007C = #$4F
00:AC1B:A9 00 LDA #$00
00:AC1D:A4 7A LDY $007A = #$01
00:AC1F:F0 02 BEQ $AC23
00:AC21:A9 02 LDA #$02
00:AC23:E0 F0 CPX #$F0 <
Check whether to make "critical hit" sound00:9847:A5 7C LDA $007C = #$62
00:9849:C9 F0 CMP #$F0 <
Check whether to do "critical hit" damage00:9920:A5 7C LDA $007C = #$B4
00:9922:C9 F0 CMP #$F0 <
Check to see if "critical hit" text is usedIn the ROM:
0x3AC33: E0 F0 <– for the sound
0x39859: C9 F0 <– for the damage
0x39932: C9 F0 <– for the text
And we have the "how bad will a critical hit hurt value":
00:984D:A9 33 LDA #$33
Default is 33 (51). This value is stored in:
0x3984D: A9 33
So if we were to make a critical hit twice as likely and make it hurt twice as bad we would make the following changes:
0x3AC33: E0 E1
0x39859: C9 E1
0x39932: C9 E1
0x3985D: A9 66
Adding this to the ROM hacking guide.
October 20, 2011 at 6:50 pm #39560sonic.penguin
Moderatorkudo's, I knew you'd get it before too long, now to make some adjustments…
October 21, 2011 at 1:04 am #39561sonic.penguin
ModeratorQuote:And we have the "how bad will a critical hit hurt value":00:984D:A9 33 LDA #$33
Default is 33 (51). This value is stored in:
0x3984D: A9 33
So if we were to make a critical hit twice as likely and make it hurt twice as bad we would make the following changes:
0x3AC33: E0 E1
0x39859: C9 E1
0x39932: C9 E1
0x3984D: A9 66
Just an FYI at 3984D the values are E7 B0 not A9 66, even in the original DOAE. Are you sure that is the right line? Haven't tested it yet… and on that first line do you mean 3984D or 984D?
October 21, 2011 at 3:09 am #39562MiDKnighT
ModeratorThat was a typo. It's 3985D.
October 21, 2011 at 10:25 am #39563sonic.penguin
ModeratorQuote:That was a typo. It's 3985D.Good thing this is a living document hehehe
October 21, 2011 at 12:35 pm #39564sonic.penguin
ModeratorUpping crit power WAY messes up the game. Doubling it from 33 -> 66 makes people hit around 15,000-20,000 with a halberd and Bei Ji (zeal) and thats on end-game foes lol. I think just adjusting rate is the best unless you severely underpower weapons which would be a lot more work…
October 21, 2011 at 12:37 pm #39565MiDKnighT
ModeratorYa I don't advocate doubling it. As you said it's too much. Was just showing that example for how to change it. In my mod I raised it from 31 to 35.
-
AuthorPosts
- You must be logged in to reply to this topic.

