AppleIIAsm-Collection/source/d5_strings/T.MIN.SUB.SUBDEL.ASM
nathanriggs 9b12b6fd9b HOUSEKEEPING
- getting ready for major changes for 0.6.0.
- be sure to download the 0.5.0 release to ensure proper functionality, as these rountines will not work together in the SRC or BIN folder during the transition
- Beginning to significantly alter documentation
2019-12-17 17:19:24 -05:00

38 lines
764 B
NASM

]SUBLEN EQU BPAR1
]SUBIND EQU BPAR2
]STR EQU WPAR1
SUBDEL
DEC ]SUBIND
INC ]SUBLEN
LDY #0
LDA (]STR),Y
SEC
SBC ]SUBLEN
STA RETLEN
INC RETLEN
:LP1
INY
LDA (]STR),Y
STA RETLEN,Y
CPY ]SUBIND
BNE :LP1
LDX ]SUBIND
TYA
CLC
ADC ]SUBLEN
TAY
DEX
DEY
:LP2
INY
INX
LDA (]STR),Y
STA RETURN,X
CPX RETLEN
BNE :LP2
:EXIT
LDA RETLEN
RTS
CPY #255
BEQ :EXIT