scene.org File Archive

File download

<root>­/­parties­/­2022­/­vccc22­/­christmas_star_challenge/reddie_zx_spectrum_assembler_vc3-2022.zip

File size:
58 242 bytes (56.88K)
File date:
2022-12-30 11:32:13
Download count:
all-time: 0

Preview

  • file_id.diz 1.28K
  • STAR_V13.C 34B
  • STAR_ZX_v13_34_bytes_source.txt 378B
  • VCCC2022_ZX_compilation_screenshot.png 18.48K
  • VCCC2022_ZX_result_on_screen.png 20.28K
  • VCCC2022_ZX_source_screenshot.png 25.37K

file_id.diz

Name of Release: STAR_V13 (as file into TRD-image, huh)
Author: reddie
Category: Christmas Challenge 2022
System: ZX Spectrum
Language: Assembler (ALASM 4.2, included into TRD-image)
Len source code: 543 bytes (including description), file "STAR_V13.H"
Len exe file:    34 bytes (STAR_V13.C, included into archive)
Len code only:   34 bytes
Instructions: (on real hardware) run TR-DOS (RANDOMIZE USR 15616), then run "STAR_V13" BASIC-file, it will load&start the code;
(in emulator) run any emulator with TR-DOS support, the actions are similar to those described above for real hardware.
ALASM assembler included, you may run it and load&view source file (keys W, Enter - select file, then E - view loaded file)
Description(how the code works): the program builds a star from four triangles, in two passes, two triangles in each. In turn, the triangles are drawn by the "lines", using the ROM program to print the characters. Before the second pass, the code is patched to change the direction of rendering. the compilation address is selected in such a way that the HL register pointing to the patch address is also the data for the patch.
Comments:
I'm not sure if this is the best algorithm in size, but I hope to get closer to the best result =)
reddie, 2022-dec-26, 4 hours till deadline.