1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-24 11:31:31 +00:00

Split files

This commit is contained in:
Karri Kaksonen 2022-04-16 19:15:19 +03:00 committed by mrdudz
parent e0c7880e34
commit f0e16514e0
3 changed files with 181 additions and 197 deletions

View File

@ -7,7 +7,7 @@
.export _cputc
.export _textcolor
.import _gotoxy, _gotox, _gotoy, pusha0
.import _gotoxy, gotox, gotoy, pusha0
.import pushax
.import _screen
.import CURS_X, CURS_Y
@ -101,9 +101,9 @@ umula0:
beq @L3
@L2: clc
adc #1
@L3: jsr _gotoy
@L3: jsr gotoy
lda #0
jmp _gotox
jmp gotox
@L4:
cmp #$20 ; ' '
@ -168,7 +168,7 @@ umula0:
beq @L1
clc
adc #1
jmp _gotox
jmp gotox
.endproc

View File

@ -23,7 +23,7 @@
; definitely not allow direct access to the variables.
;
.export gotoxy, _gotoxy, _gotox, _gotoy, _wherex, _wherey
.export gotoxy, _gotoxy, gotox, gotoy
.export CURS_X, CURS_Y
.constructor init_cursor
.interruptor blink_cursor
@ -122,7 +122,7 @@ umula0:
; Enable cursor
; if showcursor cursorzone[1] = 30
;
.proc _gotoy
.proc gotoy
pha
lda CURS_Y
@ -147,7 +147,7 @@ umula0:
; You also need to set the hpos offset to the correct value on this line
; cursorzone[3] = 8 * CURS_X
;
.proc _gotox
.proc gotox
sta CURS_X
ldy #3
@ -165,9 +165,9 @@ umula0:
;
.proc _gotoxy
jsr _gotoy
jsr gotoy
jsr popa
jsr _gotox
jsr gotox
rts
.endproc
@ -175,23 +175,6 @@ umula0:
jsr popa
jmp _gotoxy
.endproc
;-----------------------------------------------------------------------------
; Get cursor X position
;
.proc _wherex
lda CURS_X
rts
.endproc
;-----------------------------------------------------------------------------
; Get cursor Y position
;
.proc _wherey
lda CURS_Y
rts
.endproc
;-----------------------------------------------------------------------------
; Initialize cursorzone at startup

View File

@ -12,6 +12,7 @@
;
.proc _wherex
ldx #0
lda CURS_X
rts
.endproc