Users browsing this thread: 1 Guest(s)
Boomerang & Sniper 75%

#7
Posts: 145
Threads: 47
Thanks Received: 0
Thanks Given: 0
Joined: Jan 2020
Reputation: 0
Status
None
(02-18-2020, 09:58 AM)madsiur Wrote: You need to add tags and label your branches:

Code:
org $C238FD
branch1:
org $C235BB
branch2:
...
BPL branch1
...
BNE branch1
...
JMP branch2
Now the error are the BPL branch1, BNE branch 1, JMP branch2. 


header

org $C238FE

org $C238FD
branch1:
org $C235BB
branch2:

LDA $3EF9,Y
BPL branch1 $38FD     ; (Exit if not target not Floating)
INC $BC       ; (Add 1 to damage incrementor; this keeps the behavior the same for cases where you attack
             ; a flying enemy with a command other than fight, but you can move it down with the others
             ; if you don't care about that.
LDA $B5
CMP #$00
BNE branch1 $38FD     ; (Exit if command not Fight?)
INC $BC
INC $BC
INC $BC       ; (Add another 3 to damage incrementor)
LDA #$08
STA $B5       ; (Store Throw for *purposes of animation*)
LDA $B7       ; (get graphic index)
DEC
STA $B6       ; (undo earlier adjustment, save as Throw parameter)
JMP branch2 $35BB     ; (Update a previous entry in ($76) animation buffer
              ;                       with data in $B4 - $B7)

(02-18-2020, 04:07 AM)Subtraction Wrote: If you want to change the odds, write a subroutine similar to C2/4B53 that sets the carry 75% of the time instead of 50%.
If you want it to do more damage, you could add more "INC $BC"s, but that'd take up more space and you'd have to move some or all of the code to a subroutine. It's probably better to just replace the "INC $BC"s with something like "LDA $BC, ADC #$05, STA $BC"

I don't get the "ADC #$05", I assume the 05 is the dmg x5, but what is "ADC" in hex? Which game spec docs do I find this?
  Find
Quote  



Messages In This Thread
Boomerang & Sniper 75% - by doofenH - 02-17-2020, 11:11 AM
RE: Boomerang & Sniper 75% - by Subtraction - 02-18-2020, 04:07 AM
RE: Boomerang & Sniper 75% - by doofenH - 02-18-2020, 09:28 AM
RE: Boomerang & Sniper 75% - by madsiur - 02-18-2020, 09:34 AM
RE: Boomerang & Sniper 75% - by doofenH - 02-18-2020, 09:52 AM
RE: Boomerang & Sniper 75% - by madsiur - 02-18-2020, 09:58 AM
RE: Boomerang & Sniper 75% - by doofenH - 02-18-2020, 10:19 AM
RE: Boomerang & Sniper 75% - by madsiur - 02-18-2020, 10:27 AM
RE: Boomerang & Sniper 75% - by doofenH - 02-18-2020, 10:44 AM
RE: Boomerang & Sniper 75% - by madsiur - 02-18-2020, 01:28 PM
RE: Boomerang & Sniper 75% - by Subtraction - 02-20-2020, 04:00 AM
RE: Boomerang & Sniper 75% - by doofenH - 02-19-2020, 01:16 AM
RE: Boomerang & Sniper 75% - by madsiur - 02-19-2020, 01:27 AM

Forum Jump:

Users browsing this thread: 1 Guest(s)


Theme by Madsiur2017Custom Graphics by JamesWhite