Users browsing this thread: 1 Guest(s)
Order in menu

#6
Posts: 200
Threads: 1
Thanks Received: 10
Thanks Given: 0
Joined: Oct 2015
Reputation: 18
Status
None
reply as to whether you want Black/White/Gray mixed together or not.  you still haven't specified.

eh, i'll assume you don't want them mixed.  try this for Bank C2:

1) make a 54-byte ROM table of each Magic spell ID's desired position within its H/A/E category, with 0 being the first position.  it can go in any bank.

2)

Code:
hirom
header   ; comment out as needed

org $C255C1
JSR extra_attack
nop

org $C255CB
JSR extra_effect
nop

org $C255D5
JSR extra_healing
nop

; --------------------

org $C2????    ; pick a free address

extra_attack:
LDA $C2574B,X
bra common

extra_effect:
LDA $C25751,X
ADC #$18
bra common

extra_healing:
LDA $C25757,X
ADC #$2D

common:
phx
tyx
clc
adc new_table,x  ; new_table is 3-byte address
plx
rts

now to give Bank C3 a shot:

Code:
hirom
header   ; comment out as needed

org $C34F7A

jsr extra1

loop:
jsr extra2
INC
INY
DEC $E0
bne loop
RTS

; ----------------

org $C3????   ; you find a free space address

extra1:
pha
tya
sta $e1   ; seeing as they're not using this half...
pla
rts

extra2:
pha
tax
lda new_table,x
clc
adc $e1
tax
pla
STA $7E9D89,X
rts

if i move "INC / INY" into extra2 and pull extra1 inline, it'll be a little faster.

then again, most of the slowness is coming from JSRing inside a loop.  maybe we should move that entire loop into extra2; it'll only take 6 more bytes.  likely worth the tradeoff.
Quote  



Messages In This Thread
Order in menu - by fedorajoe - 12-31-2016, 03:40 AM
RE: Order in menu - by GrayShadows - 12-31-2016, 09:36 PM
RE: Order in menu - by B-Run - 12-31-2016, 10:05 PM
RE: Order in menu - by fedorajoe - 01-01-2017, 06:36 PM
RE: Order in menu - by GrayShadows - 01-01-2017, 07:26 PM
RE: Order in menu - by assassin - 01-01-2017, 07:49 PM
RE: Order in menu - by assassin - 03-01-2017, 12:34 AM

Forum Jump:

Users browsing this thread: 1 Guest(s)


Theme by Madsiur2017Custom Graphics by JamesWhite