Created
March 11, 2018 15:44
-
-
Save daftspaniel/239469fbcd7a0844bfb5dfe7716bd3c5 to your computer and use it in GitHub Desktop.
Screen border WIP
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* Draw boxes across the screen. | |
* | |
ORG $4E21 | |
LDX #$600 ; Screen base address | |
LDB #$00 ; | |
BOXROW LDA #$FF ; | |
STA ,X ; | |
LDA #$81 ; | |
STA 32,X ; | |
STA 64,X ; | |
STA 96,X ; | |
STA 128,X ; | |
STA 160,X ; | |
STA 192,X ; | |
LDA #$FF ; | |
STA 224,X ; | |
ADDB #$01 ; | |
LEAX 1,X ; | |
CMPB #$1F ; | |
BLE BOXROW ; | |
LDB #$00 ; Reset counter. | |
LDX #$700 ; Screen base address | |
BOXCOL LDA #$FF ; | |
STA ,X ; | |
LDA #$81 ; | |
STA 32,X ; | |
STA 64,X ; | |
STA 128,X ; | |
STA 160,X ; | |
STA 192,X ; | |
STA 96,X ; huh? | |
LDA #$FF ; | |
STA 224,X ; | |
ADDB #$01 ; | |
LEAX 256,X ; Add row. | |
CMPB #$16 ; | |
BLE BOXCOL ; | |
RTS |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment