don't be a snowflake
Author: Bitbreaker / Performers
Category: Christmas Challenge
System: C64
Language: 6502 assembler
Len source code: 1883 bytes
Len exe file: 52 bytes
Len code only: 48 bytes
Instructions:
Start with for e.g. x64 size.d64 with vice
Description:
Rasterises bits in data table (1 = *) over 19 lines, right side is mirrored in same go. Mirror on the x-axis is done by inverting the loop that runs over the table when 10th line is reached. Solid vertical line is done by a forced initial set when new line begins. The horizontal line is handled by cpx #$09, which forces a set over the whole line, and initiates the inversion as mentioned before.
start with y = 9, always print first point, do until y < 0
<--------|-------->
* | entry, a = 0, x = 0, start with print
* * * |
* * *** * * |
** * ** |
*** * * * *** |- inx
* *** * |
* * * |
* * * * * * * |
* * *** * * |
******************* <- cpx #$09, force print only and change inx to dex
* * *** * * |
* * * * * * * |
* * * |
* *** * |
*** * * * *** |- dex
** * ** |
* * *** * * |
* * * |
* |-> x < 0 -> end
Comments:
Load from .d64, autostart might fail due to wrong initialisation of regs/zp vals if injected into RAM