fix Tetrisk 128k

This commit is contained in:
Peter Ferrie 2019-01-16 13:12:57 -08:00
parent 9d104061f4
commit 329f867fd6

View File

@ -524,38 +524,47 @@ ProDOS_enter
sta sizehi sta sizehi
sta sizelo sta sizelo
jsr hddopendir jsr hddopendir
ldx @handles+1
lda bleftlo
sta @sizelo-1, x
lda blefthi
sta @sizehi-1, x
lda #0 lda #0
sta blkidx sta blkidx
beq @jmp_zp ;always beq @jmp_zp ;always
@imp_seek @imp_seek
ldx @handles+1 jsr @set_rdwrbuff
lda @sizelo-1, x
sta bleftlo
lda @sizehi-1, x
sta blefthi
lda #0 lda #0
sta blkidx sta blkidx
sta blkofflo sta blkofflo
sta blkoffhi sta blkoffhi
sta reqcmd sta reqcmd
jsr @set_rdwrbuff jsr @reset
ldx sizelo
beq @seek64
sta sizehi
sta sizelo
jsr @seekreset
inc ldrlo
bne @seek64
inc ldrhi
@seek64
lda ldrhi lda ldrhi
sta sizehi sta sizehi
lda ldrlo lda ldrlo
sta sizelo sta sizelo
jsr hddrdwrpart jsr @seekreset
lda ldrhi lda ldrhi
ora ldrlo ora ldrlo
bne @jmp_zp bne @jmp_zp
dec blkidx dec blkidx
beq @jmp_zp ;always beq @jmp_zp ;always
@seekreset
jsr hddrdwrpart
@reset
lda #$ff
sta blefthi
sta bleftlo
rts
@imp_read @imp_read
lda #cmdread lda #cmdread
!byte $2c !byte $2c
@ -670,10 +679,5 @@ ProDOS_enter
@handle @handle
!byte 0, 0 ;only up to two handles at a time !byte 0, 0 ;only up to two handles at a time
@sizelo
!byte 0, 0 ;only up to two files at a time
@sizehi
!byte 0, 0 ;only up to two files at a time
@saved_zp @saved_zp
!fill (last_zp - first_zp) + 1 !fill (last_zp - first_zp) + 1