// Display  MEDUSA PETSCII by Buzz_clik
// https://csdb.dk/release/?id=178673

import "c64"
import "string"

byte[1000] MEDUSA_SCREEN = kickasm(resource "medusas.prg" ) {{
    .var fileScreen = LoadBinary("medusas.prg", BF_C64FILE)
    .fill fileScreen.getSize(), fileScreen.get(i)
}};


byte[] MEDUSA_COLORS = kickasm(resource "medusac.prg" ) {{
    .var fileCols = LoadBinary("medusac.prg", BF_C64FILE)
    .fill fileCols.getSize(), fileCols.get(i)
}};

byte* SCREEN = 0x0400;

void main() {
    *BGCOL = BLACK;
    memcpy(SCREEN, MEDUSA_SCREEN, 1000);
    memcpy(COLS, MEDUSA_COLORS, 1000);
    while(true) {
        (*(SCREEN+999)) ^= 0x0e;
    }
}
