dos33fsprogs/mode7/checkerboard_lookup.s

22 lines
515 B
ArmAsm
Raw Normal View History

2017-12-12 20:39:32 +00:00
;====================
; lookup_map
;====================
; finds value in space_x.i,space_y.i
; returns color in A
; CLOBBERS: A,Y
lda SPACEX_I ; 3
sta spacex_label+1 ; self modifying code, LAST_SPACEX_I ; 4
lda SPACEY_I ; 3
sta spacey_label+1 ; self modifying code, LAST_SPACEY_I ; 4
2017-12-13 05:19:18 +00:00
lda SPACEY_I
eor SPACEX_I
and #$1
beq @black
@white:
lda #$ff
@black:
2017-12-12 20:39:32 +00:00
sta map_color_label+1 ; self-modifying