The following warnings occurred:
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 895 - File: showthread.php PHP 7.3.33 (Linux)
File Line Function
/showthread.php 895 errorHandler->error




Users browsing this thread: 1 Guest(s)
30,000 damage patch and 24 bit monsters HP patch conflict

#1
Posts: 3,971
Threads: 279
Thanks Received: 237
Thanks Given: 58
Joined: Oct 2011
Reputation: 65
Status
Tissue-aware
After the post of someone who couldn't get the game run properly with the 2 patches mentioned in the title, I discovery that there is a conflict between the two patches. They use the same free space in bank C0. To resolve this, I suggest doing the following steps. I won't release a super patch which makes both patches work together as I'm not the creator of any of the two...

First apply the 30,000 damage patch. It's the one that change the most code while the 24 bit monster HP change less code. The second step consist of writing manually the 24 bit HP patch .This patch consist of 2 jump to free space in bank C0 where you put the rest of the code. Originally the two routine you jump to where starting at C0/D613 and C0/D631. Here they are:

First routine (C0/D613):

Code:
99 F4 3B     STA $3BF4,Y
99 1C 3C     STA $3C1C,Y
DA           PHX
8A           TXA
4A           LSR A
4A           LSR A
4A           LSR A
4A           LSR A
4A           LSR A
AA           TAX
E2 20        SEP #$20
BF 50 CF CF  LDA $CFCF50,X
99 78 3C     STA $3C78,Y
99 79 3C     STA $3C79,Y
FA           PLX
C2 20        REP #$20
6B           RTL

Second routine(C0/D631):

Code:
B9 F4 3B    LDA $3BF4,Y
E5 EE       SBC $EE
99 F4 3B    STA $3BF4,Y
48          PHA
08          PHP
98          TYA
E9 08 00    SBC #$0008
30 2F       BMI (2F bytes down)
28          PLP
68          PLA
F0 03       BEQ (3 bytes down)
90 13       BCC (13 bytes down)
6B          RTL
48          PHA
E2 20       SEP #$20
B9 78 3C    LDA $3C78,Y
10 04       BPL (4 bytes down)
C2 20       REP #$20
68          PLA
6B          RTL
C2 20       REP #$20
68          PLA
C2 02       REP #$02
6B          RTL
48          PHA             
E2 20       SEP #$20
B9 78 3C    LDA $3C78,Y
D0 05       BNE (5 bytes down)
C2 20       REP #$20
68          PLA
18          CLC
6B          RTL
3A          DEC A
99 78 3C    STA $3C78,Y
C2 20       REP #$20
68          RTL
38          SEC
6B          RTL
28          PLP
68          PLA
6B          RTL

I suggest writing these two portions of code elsewhere. There is plenty of free space in C0 starting at C0/DC10 up to C0/EF9F. This is more than enough. The only thing left to do is to change the offset of the two JSL in the following portion of code. You will also need to put any NOP you see. This code is also taken from the 24 bit HP patch applied to a clean ROM:

First Jump

Code:
C2/1342: 22 31 D6 C0     JSL $C0D631
C2/1346: EA              NOP
C2/1347: EA              NOP
C2/1348: EA              NOP
C2/1349: EA              NOP

Second Jump

Code:
C2/2CCB: 22 13 D6 C0     JSL $C0D613
C2/2CCF: EA              NOP
C2/2CD0: EA              NOP

That's it! This should make both patches work together!
  Find
Quote  
[-] The following 1 user says Thank You to madsiur for this post:
  • Gi Nattak (04-18-2012)



Messages In This Thread
30,000 damage patch and 24 bit monsters HP patch conflict - by madsiur - 04-17-2012, 11:06 PM

Forum Jump:

Users browsing this thread: 1 Guest(s)


Theme by Madsiur2017Custom Graphics by JamesWhite