diff --git a/wip-hugo/routines/line/line.inc b/wip-hugo/routines/line/line.inc index fc2d0ca..1ecc5ab 100644 --- a/wip-hugo/routines/line/line.inc +++ b/wip-hugo/routines/line/line.inc @@ -10,9 +10,6 @@ dx_2 = $F3 ; 16-bit value (uses F4) V = $ED ; 16-bit value (uses EE) D = $EB ; 16-bit value (uses EC) - ;; These come from mem.inc + ;; These come from pixel.inc ;; Takes up FF - F5 - X_pos = $FC - Y_pos = $FB - byte_to_paint = $FE ; Byte with one 1 that corisponds to a pixel. - btp_mem_pos =$F9 ; 16-bit value (uses FA), byte to paint memory position + .include "../pixel/pixel.inc" diff --git a/wip-hugo/routines/memory/mem.inc b/wip-hugo/routines/memory/mem.inc index 2d1551a..0eb2250 100644 --- a/wip-hugo/routines/memory/mem.inc +++ b/wip-hugo/routines/memory/mem.inc @@ -4,10 +4,3 @@ A_start = $FA ; 16-bit value (uses FB) B_start = $FC ; 16-bit value (uses FD) B_end = $FE ; 16-bit value (uses FF) -;;In use of by pixel_draw - Y_pos = $FB - X_pos = $FC ; 16-bit value (uses FD) - byte_to_paint = $FE - btp_mem_pos = $F9 ; 16-bit value (uses FA), byte to paint memory position - C = $F7 ; 16-bit value (uses F8) - B = $F5 ; 16-bit value (uses F6) diff --git a/wip-hugo/routines/pixel/pixel.inc b/wip-hugo/routines/pixel/pixel.inc new file mode 100644 index 0000000..8f68222 --- /dev/null +++ b/wip-hugo/routines/pixel/pixel.inc @@ -0,0 +1,6 @@ + Y_pos = $FB + X_pos = $FC ; 16-bit value (uses FD) + byte_to_paint = $FE + btp_mem_pos = $F9 ; 16-bit value (uses FA), byte to paint memory position + C = $F7 ; 16-bit value (uses F8) + B = $F5 ; 16-bit value (uses F6) diff --git a/wip-hugo/routines/memory/pixel_draw.s b/wip-hugo/routines/pixel/pixel_draw.s similarity index 93% rename from wip-hugo/routines/memory/pixel_draw.s rename to wip-hugo/routines/pixel/pixel_draw.s index ac80794..e53ca0d 100755 --- a/wip-hugo/routines/memory/pixel_draw.s +++ b/wip-hugo/routines/pixel/pixel_draw.s @@ -3,7 +3,7 @@ ;;Screen print. Draws a pixel at a specified position. .proc pixel_draw; user-procedure :clobbers (A X Y) :clobbers-arguments 0 ;; Draws a pixel at Y_pos, X_pos se mem.inc - .include "mem.inc" + .include "pixel.inc" Bitmap = $4000 Bitmap_end = $5F3F ;; X = X_pos (mod 8)