home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Transactor
/
Transactor_07_1985_Transactor_Publishing.d64
/
strip & clean
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2023-02-26
|
1KB
|
86 lines
0 rem strip & clean (aug 29/84) :
1 :
2 rem 0 statements, 2 functions
3 :
4 rem keyword characters: 14
5 :
6 rem keyword routine line ser #
7 rem f/strip$( strip 3984 045
8 rem f/clean$( clean 3988 046
9 :
10 rem u/cifchr (2560/003)
11 rem u/cifnum (4092/047)
12 :
13 rem ================================
14 :
609 .asc "strip$[168]clean$[168]"
1609 .word strip-1,clean-1
2560 cifchr cmp #$5b
2562 bcc cic1
2564 clc
2566 bcc cic2
2568 cic1 cmp #$41
2570 cic2 rts
2572 ;
3984 strip lda #$80
3986 .byte $2c
3988 clean lda #0
3990 pha
3992 jsr $aef4
3994 jsr $b6a3
3996 sta t3
3998 pla
4000 sta t4
4002 txa
4004 pha
4006 tya
4008 pha
4010 lda t3
4012 jsr $b47d
4014 pla
4016 sta $23
4018 pla
4020 sta $22
4022 stx $24
4024 sty $25
4026 ldx #0
4028 stx t5
4030 ldy #$ff
4032 cln1 iny
4034 cpy t3
4036 beq cln4
4038 lda ($22),y
4040 and #$7f
4042 jsr cifchr
4044 bcs cln2
4046 jsr cifnum
4048 bcs cln2
4050 bit t4
4052 bmi cln1
4054 bvs cln1
4056 cmp #$20
4058 bne cln1
4060 clc
4062 cln2 sta ($24,x)
4064 lda t4
4066 and #$80
4068 bcs cln3
4070 ora #$40
4072 cln3 sta t4
4074 inc t5
4076 inc $24
4078 bne cln1
4080 inc $25
4082 bne cln1
4084 cln4 lda t5
4086 sta $61
4088 jmp $b4ca
4090 ;
4092 cifnum cmp #":"
4094 bcc cin1
4096 clc
4098 bcc cin2
4100 cin1 cmp #"0"
4102 cin2 rts
4104 ;