]> git.sur5r.net Git - cc65/blob - libsrc/creativision/gotoxy.s
6c0cf932f30945664c8749dec3febfdfd063813d
[cc65] / libsrc / creativision / gotoxy.s
1 ;
2 ; Ullrich von Bassewitz, 06.08.1998
3 ;
4 ; void gotoxy (unsigned char x, unsigned char y);
5 ;
6
7         .export         _gotoxy
8         .import         setcursor
9         .import         popa
10
11         .include        "creativision.inc"
12
13 .proc   _gotoxy
14
15         sta     CURSOR_Y          ; Set Y
16         jsr     popa              ; Get X
17         sta     CURSOR_X          ; Set X
18         tay
19         ldx     CURSOR_Y
20         jmp     setcursor       ; Set the cursor position
21
22 .endproc