Minor optimizations

This commit is contained in:
Pecusx
2023-05-25 21:40:06 +02:00
parent 1edf0d5a1e
commit 1389675fce
4 changed files with 8 additions and 10 deletions
+5 -7
View File
@@ -1401,7 +1401,6 @@ FalloutOfLine
ldy #0 ldy #0
lda (temp),y lda (temp),y
sta ydraw sta ydraw
lda (temp),y
clc clc
adc #1 adc #1
sta (temp),y sta (temp),y
@@ -1441,11 +1440,11 @@ NothingToFall
; starting point ; starting point
getrandomY ;getting random Y coordinate getrandomY ;getting random Y coordinate
sec ; sec ; ???
lda random lda random
cmp #screenheight-(margin*4) ;it means that max line=199 cmp #screenheight-(margin*4) ;it means that max line=199
bcs getrandomY bcs getrandomY
clc ; clc ; C is clear
adc #(margin*2) adc #(margin*2)
sta ydraw sta ydraw
sta yfloat+1 sta yfloat+1
@@ -1762,16 +1761,15 @@ DOTOldLowestValue
:3 asl ; *8 :3 asl ; *8
clc clc
adc #<TanksNames adc #<TanksNames
sta temp ; TextAddress sta LineAddress4x4 ; TextAddress
lda #0 lda #0
adc #>Tanksnames adc #>Tanksnames
sta temp+1 ; TextAddress+1 sta LineAddress4x4+1 ; TextAddress+1
mwa temp LineAddress4x4
;find length of the tank's name ;find length of the tank's name
ldy #7 ldy #7
@ @
lda (temp),y lda (LineAddress4x4),y
bne end_found bne end_found
dey dey
bne @- bne @-
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.