Codetapper's Amiga Site

Parasol Stars

Parasol Stars only uses a single sprite to create the score panel at the top of the screen! Firstly, take a look at the game with sprites enabled and disabled:

Parasol Stars Amiga with sprites enabled

Sprites enabled.

Parasol Stars Amiga with sprites enabled

Sprites disabled.

Firstly the game sets up the display:

Chip Addr Instructi DMA Slot     Comments
--------- --------- ------------ --------
0000229e: 0080 0000 [000 004]    ;COP1LCH := 0x0000
000022a2: 0082 19c2 [000 008]    ;COP1LCL := 0x19c2
000022a6: 0120 0004 [000 00c]    ;SPR0PTH := 0x0004    Setup all 8 sprites
000022aa: 0122 2ab2 [000 010]    ;SPR0PTL := 0x2ab2
000022ae: 0124 0004 [000 014]    ;SPR1PTH := 0x0004
000022b2: 0126 2afa [000 018]    ;SPR1PTL := 0x2afa
000022b6: 0128 0004 [000 01c]    ;SPR2PTH := 0x0004
000022ba: 012a 2d82 [000 020]    ;SPR2PTL := 0x2d82
000022be: 012c 0004 [000 024]    ;SPR3PTH := 0x0004
000022c2: 012e 2dca [000 028]    ;SPR3PTL := 0x2dca
000022c6: 0130 0004 [000 02c]    ;SPR4PTH := 0x0004
000022ca: 0132 3052 [000 030]    ;SPR4PTL := 0x3052
000022ce: 0134 0004 [000 034]    ;SPR5PTH := 0x0004
000022d2: 0136 309a [000 038]    ;SPR5PTL := 0x309a
000022d6: 0138 0000 [000 03c]    ;SPR6PTH := 0x0000
000022da: 013a 2ee6 [000 040]    ;SPR6PTL := 0x2ee6
000022de: 013c 0000 [000 044]    ;SPR7PTH := 0x0000
000022e2: 013e 2ef6 [000 048]    ;SPR7PTL := 0x2ef6
000022e6: 2001 ff00 [020 000]    ;Wait for vpos >= 0x20, ignore horizontal.
000022ea: 0096 8660 [020 006]    ;DMACON := 0x8660
000022ee: 0100 4000 [020 00c]    ;BPLCON0 := 0x4000    4 bitplane mode
000022f2: 0102 0000 [020 00e]    ;BPLCON1 := 0x0000
000022f6: 008e 4081 [020 012]    ;DIWSTRT := 0x4081
000022fa: 0090 10c1 [020 016]    ;DIWSTOP := 0x10c1
000022fe: 0092 0030 [020 01a]    ;DDFSTRT := 0x0030
00002302: 0094 00d0 [020 01e]    ;DDFSTOP := 0x00d0
00002306: 0180 0000 [020 024]    ;COLOR00 := 0x0000    Setup palette
0000230a: 0182 0e00 [020 028]    ;COLOR01 := 0x0e00
0000230e: 0184 0800 [020 02c]    ;COLOR02 := 0x0800
00002312: 0186 0e60 [020 030]    ;COLOR03 := 0x0e60
00002316: 0188 0ee0 [020 034]    ;COLOR04 := 0x0ee0
0000231a: 018a 0060 [020 038]    ;COLOR05 := 0x0060
0000231e: 018c 0040 [020 03c]    ;COLOR06 := 0x0040
00002322: 018e 00c0 [020 040]    ;COLOR07 := 0x00c0
00002326: 0190 0e0e [020 044]    ;COLOR08 := 0x0e0e
0000232a: 0192 006e [020 048]    ;COLOR09 := 0x006e
0000232e: 0194 0008 [020 04c]    ;COLOR10 := 0x0008
00002332: 0196 00ee [020 050]    ;COLOR11 := 0x00ee
00002336: 0198 0808 [020 054]    ;COLOR12 := 0x0808
0000233a: 019a 0e86 [020 058]    ;COLOR13 := 0x0e86
0000233e: 019c 0000 [020 05c]    ;COLOR14 := 0x0000
00002342: 019e 0ccc [020 060]    ;COLOR15 := 0x0ccc
00002346: 0108 00d0 [020 062]    ;BPL1MOD := 0x00d0
0000234a: 010a 00d0 [020 066]    ;BPL2MOD := 0x00d0
0000234e: 00e0 0001 [020 06a]    ;BPL1PTH := 0x0001    Bitplanes interleaved 50 bytes apart
00002352: 00e2 8930 [020 06e]    ;BPL1PTL := 0x8930
00002356: 00e4 0001 [020 072]    ;BPL2PTH := 0x0001
0000235a: 00e6 8962 [020 076]    ;BPL2PTL := 0x8962
0000235e: 00e8 0001 [020 07a]    ;BPL3PTH := 0x0001
00002362: 00ea 8994 [020 07e]    ;BPL3PTL := 0x8994
00002366: 00ec 0001 [020 082]    ;BPL4PTH := 0x0001
0000236a: 00ee 89c6 [020 086]    ;BPL4PTL := 0x89c6
0000236e: 00f0 0001 [020 08a]    ;BPL5PTH := 0x0001
00002372: 00f2 89f8 [020 08e]    ;BPL5PTL := 0x89f8
00002376: 01a0 0444 [020 094]    ;COLOR16 := 0x0444    Setup remaining palette
0000237a: 01a2 0e86 [020 098]    ;COLOR17 := 0x0e86
0000237e: 01a4 0000 [020 09c]    ;COLOR18 := 0x0000
00002382: 01a6 0eee [020 0a0]    ;COLOR19 := 0x0eee
00002386: 01a8 0ee0 [020 0a4]    ;COLOR20 := 0x0ee0
0000238a: 01aa 0e00 [020 0a8]    ;COLOR21 := 0x0e00
0000238e: 01ac 0800 [020 0ac]    ;COLOR22 := 0x0800
00002392: 01ae 0e60 [020 0b0]    ;COLOR23 := 0x0e60
00002396: 01b0 0e0e [020 0b4]    ;COLOR24 := 0x0e0e
0000239a: 01b2 006e [020 0b8]    ;COLOR25 := 0x006e
0000239e: 01b4 0008 [020 0bc]    ;COLOR26 := 0x0008
000023a2: 01b6 00ee [020 0c0]    ;COLOR27 := 0x00ee
000023a6: 01b8 0808 [020 0c4]    ;COLOR28 := 0x0808
000023aa: 01ba 00e0 [020 0c8]    ;COLOR29 := 0x00e0
000023ae: 01bc 0102 [020 0cc]    ;COLOR30 := 0x0102
000023b2: 01be 00e0 [020 0d0]    ;COLOR31 := 0x00e0

The trick begins by waiting for horizontal position 30, setting colour 31, setting the sprite control word and position, then stuffing data into the sprite and moving it horizontally across the screen:

000023b6: 4031 fffe [040 02e]    ;Wait for vpos >= 0x40 and hpos >= 0x30.
000023ba: 01be 04f4 [040 036]    ;COLOR31 := 0x04f4     Green BUBBY text
000023be: 0172 6d60 [040 038]    ;SPR6CTL := 0x6d60
000023c2: 0170 0040 [040 03c]    ;SPR6POS := 0x0040
000023c6: 0174 0000 [040 040]    ;SPR6DATA := 0x0000    '  '
000023ca: 0170 0048 [040 044]    ;SPR6POS := 0x0048
000023ce: 0174 0000 [040 048]    ;SPR6DATA := 0x0000    '  '
000023d2: 0170 0050 [040 04c]    ;SPR6POS := 0x0050
000023d6: 0174 0000 [040 050]    ;SPR6DATA := 0x0000    '  '
000023da: 0170 0058 [040 054]    ;SPR6POS := 0x0058
000023de: 0174 0000 [040 058]    ;SPR6DATA := 0x0000    '  '
000023e2: 0170 0060 [040 05c]    ;SPR6POS := 0x0060
000023e6: 0174 00fc [040 060]    ;SPR6DATA := 0x00fc    ' B'
000023ea: 0170 0068 [040 064]    ;SPR6POS := 0x0068
000023ee: 0174 c6fc [040 068]    ;SPR6DATA := 0xc6fc    'UB'
000023f2: 0170 0070 [040 06c]    ;SPR6POS := 0x0070
000023f6: 0174 fccc [040 070]    ;SPR6DATA := 0xfccc    'BY'
000023fa: 0170 0078 [040 074]    ;SPR6POS := 0x0078
000023fe: 0174 0000 [040 078]    ;SPR6DATA := 0x0000    '  '
00002402: 0170 0080 [040 07c]    ;SPR6POS := 0x0080
00002406: 0174 0000 [040 080]    ;SPR6DATA := 0x0000    '  '
0000240a: 01fe 0000 [040 086]    ;NO-OP(NULL) := 0x0000
0000240e: 01fe 0000 [040 08a]    ;NO-OP(NULL) := 0x0000
00002412: 01fe 0000 [040 08e]    ;NO-OP(NULL) := 0x0000
00002416: 01be 04ff [040 092]    ;COLOR31 := 0x04ff     Blue PRESS FIRE text
0000241a: 0170 0098 [040 094]    ;SPR6POS := 0x0098
0000241e: 0174 0000 [040 098]    ;SPR6DATA := 0x0000    '  '
00002422: 0170 00a0 [040 09c]    ;SPR6POS := 0x00a0
00002426: 0174 0000 [040 0a0]    ;SPR6DATA := 0x0000    '  '
0000242a: 0170 00a8 [040 0a4]    ;SPR6POS := 0x00a8
0000242e: 0174 00fc [040 0a8]    ;SPR6DATA := 0x00fc    ' P'
00002432: 0170 00b0 [040 0ac]    ;SPR6POS := 0x00b0
00002436: 0174 fcfe [040 0b0]    ;SPR6DATA := 0xfcfe    'RE'
0000243a: 0170 00b8 [040 0b4]    ;SPR6POS := 0x00b8
0000243e: 0174 7878 [040 0b8]    ;SPR6DATA := 0x7878    'SS'
00002442: 0170 00c0 [040 0bc]    ;SPR6POS := 0x00c0
00002446: 0174 00fe [040 0c0]    ;SPR6DATA := 0x00fe    ' F'
0000244a: 0170 00c8 [040 0c4]    ;SPR6POS := 0x00c8
0000244e: 0174 fcfc [040 0c8]    ;SPR6DATA := 0xfcfc    'IR'
00002452: 0170 00d0 [040 0cc]    ;SPR6POS := 0x00d0
00002456: 0174 fe00 [040 0d0]    ;SPR6DATA := 0xfe00    'E '
0000245a: 0170 00d8 [040 0d4]    ;SPR6POS := 0x00d8
0000245e: 0174 0000 [040 0d8]    ;SPR6DATA := 0x0000    '  '

The next line is almost identical, and the trick is repeated for the 2nd line of the score display:

00002462: 4131 fffe [041 02e]    ;Wait for vpos >= 0x41 and hpos >= 0x30.
00002466: 01be 04f4 [041 036]    ;COLOR31 := 0x04f4     Green BUBBY text
0000246a: 0172 6d60 [041 038]    ;SPR6CTL := 0x6d60     2nd line of graphics
0000246e: 0170 0040 [041 03c]    ;SPR6POS := 0x0040
00002472: 0174 0000 [041 040]    ;SPR6DATA := 0x0000    '  '
00002476: 0170 0048 [041 044]    ;SPR6POS := 0x0048
0000247a: 0174 0000 [041 048]    ;SPR6DATA := 0x0000    '  '
0000247e: 0170 0050 [041 04c]    ;SPR6POS := 0x0050
00002482: 0174 0000 [041 050]    ;SPR6DATA := 0x0000    '  '
00002486: 0170 0058 [041 054]    ;SPR6POS := 0x0058
0000248a: 0174 0000 [041 058]    ;SPR6DATA := 0x0000    '  '
0000248e: 0170 0060 [041 05c]    ;SPR6POS := 0x0060
00002492: 0174 00c6 [041 060]    ;SPR6DATA := 0x00c6    ' B'
00002496: 0170 0068 [041 064]    ;SPR6POS := 0x0068
0000249a: 0174 c6c6 [041 068]    ;SPR6DATA := 0xc6c6    'UB'
0000249e: 0170 0070 [041 06c]    ;SPR6POS := 0x0070
000024a2: 0174 c6cc [041 070]    ;SPR6DATA := 0xc6cc    'BY'
000024a6: 0170 0078 [041 074]    ;SPR6POS := 0x0078
000024aa: 0174 0000 [041 078]    ;SPR6DATA := 0x0000    '  '
000024ae: 0170 0080 [041 07c]    ;SPR6POS := 0x0080
000024b2: 0174 0000 [041 080]    ;SPR6DATA := 0x0000    '  '
000024b6: 01fe 0000 [041 086]    ;NO-OP(NULL) := 0x0000
000024ba: 01fe 0000 [041 08a]    ;NO-OP(NULL) := 0x0000
000024be: 01fe 0000 [041 08e]    ;NO-OP(NULL) := 0x0000
000024c2: 01be 04ff [041 092]    ;COLOR31 := 0x04ff     Blue PRESS FIRE text
000024c6: 0170 0098 [041 094]    ;SPR6POS := 0x0098
000024ca: 0174 0000 [041 098]    ;SPR6DATA := 0x0000    '  '
000024ce: 0170 00a0 [041 09c]    ;SPR6POS := 0x00a0
000024d2: 0174 0000 [041 0a0]    ;SPR6DATA := 0x0000    '  '
000024d6: 0170 00a8 [041 0a4]    ;SPR6POS := 0x00a8
000024da: 0174 00c6 [041 0a8]    ;SPR6DATA := 0x00c6    ' P'
000024de: 0170 00b0 [041 0ac]    ;SPR6POS := 0x00b0
000024e2: 0174 c6c0 [041 0b0]    ;SPR6DATA := 0xc6c0    'RE'
000024e6: 0170 00b8 [041 0b4]    ;SPR6POS := 0x00b8
000024ea: 0174 cccc [041 0b8]    ;SPR6DATA := 0xcccc    'SS'
000024ee: 0170 00c0 [041 0bc]    ;SPR6POS := 0x00c0
000024f2: 0174 00c0 [041 0c0]    ;SPR6DATA := 0x00c0    ' F'
000024f6: 0170 00c8 [041 0c4]    ;SPR6POS := 0x00c8
000024fa: 0174 30c6 [041 0c8]    ;SPR6DATA := 0x30c6    'IR'
000024fe: 0170 00d0 [041 0cc]    ;SPR6POS := 0x00d0
00002502: 0174 c000 [041 0d0]    ;SPR6DATA := 0xc000    'E '
00002506: 0170 00d8 [041 0d4]    ;SPR6POS := 0x00d8
0000250a: 0174 0000 [041 0d8]    ;SPR6DATA := 0x0000    '  '

The third line is almost identical again:

0000250e: 4231 fffe [042 02e]    ;Wait for vpos >= 0x42 and hpos >= 0x30.
00002512: 01be 04f4 [042 036]    ;COLOR31 := 0x04f4     Green BUBBY text
00002516: 0172 6d60 [042 038]    ;SPR6CTL := 0x6d60     3rd line of graphics
0000251a: 0170 0040 [042 03c]    ;SPR6POS := 0x0040
0000251e: 0174 0000 [042 040]    ;SPR6DATA := 0x0000    '  '
00002522: 0170 0048 [042 044]    ;SPR6POS := 0x0048
00002526: 0174 0000 [042 048]    ;SPR6DATA := 0x0000    '  '
0000252a: 0170 0050 [042 04c]    ;SPR6POS := 0x0050
0000252e: 0174 0000 [042 050]    ;SPR6DATA := 0x0000    '  '
00002532: 0170 0058 [042 054]    ;SPR6POS := 0x0058
00002536: 0174 0000 [042 058]    ;SPR6DATA := 0x0000    '  '
0000253a: 0170 0060 [042 05c]    ;SPR6POS := 0x0060
0000253e: 0174 00c6 [042 060]    ;SPR6DATA := 0x00c6    ' P'
00002542: 0170 0068 [042 064]    ;SPR6POS := 0x0068
00002546: 0174 c6c6 [042 068]    ;SPR6DATA := 0xc6c6    'RE'
0000254a: 0170 0070 [042 06c]    ;SPR6POS := 0x0070
0000254e: 0174 c6cc [042 070]    ;SPR6DATA := 0xc6cc    'SS'
00002552: 0170 0078 [042 074]    ;SPR6POS := 0x0078
00002556: 0174 0000 [042 078]    ;SPR6DATA := 0x0000    '  '
0000255a: 0170 0080 [042 07c]    ;SPR6POS := 0x0080
0000255e: 0174 0000 [042 080]    ;SPR6DATA := 0x0000    '  '
00002562: 01fe 0000 [042 086]    ;NO-OP(NULL) := 0x0000
00002566: 01fe 0000 [042 08a]    ;NO-OP(NULL) := 0x0000
0000256a: 01fe 0000 [042 08e]    ;NO-OP(NULL) := 0x0000
0000256e: 01be 04ff [042 092]    ;COLOR31 := 0x04ff     Blue PRESS FIRE text
00002572: 0170 0098 [042 094]    ;SPR6POS := 0x0098
00002576: 0174 0000 [042 098]    ;SPR6DATA := 0x0000    '  '
0000257a: 0170 00a0 [042 09c]    ;SPR6POS := 0x00a0
0000257e: 0174 0000 [042 0a0]    ;SPR6DATA := 0x0000    '  '
00002582: 0170 00a8 [042 0a4]    ;SPR6POS := 0x00a8
00002586: 0174 00c6 [042 0a8]    ;SPR6DATA := 0x00c6    ' P'
0000258a: 0170 00b0 [042 0ac]    ;SPR6POS := 0x00b0
0000258e: 0174 c6c0 [042 0b0]    ;SPR6DATA := 0xc6c0    'RE'
00002592: 0170 00b8 [042 0b4]    ;SPR6POS := 0x00b8
00002596: 0174 c0c0 [042 0b8]    ;SPR6DATA := 0xc0c0    'SS'
0000259a: 0170 00c0 [042 0bc]    ;SPR6POS := 0x00c0
0000259e: 0174 00c0 [042 0c0]    ;SPR6DATA := 0x00c0    ' F'
000025a2: 0170 00c8 [042 0c4]    ;SPR6POS := 0x00c8
000025a6: 0174 30c6 [042 0c8]    ;SPR6DATA := 0x30c6    'IR'
000025aa: 0170 00d0 [042 0cc]    ;SPR6POS := 0x00d0
000025ae: 0174 c000 [042 0d0]    ;SPR6DATA := 0xc000    'E '
000025b2: 0170 00d8 [042 0d4]    ;SPR6POS := 0x00d8
000025b6: 0174 0000 [042 0d8]    ;SPR6DATA := 0x0000    '  '

After 7 lines (the font is 7 pixels high) the game continues to display sprites, but they are completely blank for the one pixel gap between the 2 lines of text:

0000286a: 4731 fffe [047 02e]    ;Wait for vpos >= 0x47 and hpos >= 0x30.
0000286e: 01be 04f4 [047 036]    ;COLOR31 := 0x04f4
00002872: 0172 6d60 [047 038]    ;SPR6CTL := 0x6d60
00002876: 0170 0040 [047 03c]    ;SPR6POS := 0x0040
0000287a: 0174 0000 [047 040]    ;SPR6DATA := 0x0000    '  '
0000287e: 0170 0048 [047 044]    ;SPR6POS := 0x0048
00002882: 0174 0000 [047 048]    ;SPR6DATA := 0x0000    '  '
00002886: 0170 0050 [047 04c]    ;SPR6POS := 0x0050
0000288a: 0174 0000 [047 050]    ;SPR6DATA := 0x0000    '  '
0000288e: 0170 0058 [047 054]    ;SPR6POS := 0x0058
00002892: 0174 0000 [047 058]    ;SPR6DATA := 0x0000    '  '
00002896: 0170 0060 [047 05c]    ;SPR6POS := 0x0060
0000289a: 0174 0000 [047 060]    ;SPR6DATA := 0x0000    '  '
0000289e: 0170 0068 [047 064]    ;SPR6POS := 0x0068
000028a2: 0174 0000 [047 068]    ;SPR6DATA := 0x0000    '  '
000028a6: 0170 0070 [047 06c]    ;SPR6POS := 0x0070
000028aa: 0174 0000 [047 070]    ;SPR6DATA := 0x0000    '  '
000028ae: 0170 0078 [047 074]    ;SPR6POS := 0x0078
000028b2: 0174 0000 [047 078]    ;SPR6DATA := 0x0000    '  '
000028b6: 0170 0080 [047 07c]    ;SPR6POS := 0x0080
000028ba: 0174 0000 [047 080]    ;SPR6DATA := 0x0000    '  '
000028be: 01fe 0000 [047 086]    ;NO-OP(NULL) := 0x0000
000028c2: 01fe 0000 [047 08a]    ;NO-OP(NULL) := 0x0000
000028c6: 01fe 0000 [047 08e]    ;NO-OP(NULL) := 0x0000
000028ca: 01be 04ff [047 092]    ;COLOR31 := 0x04ff
000028ce: 0170 0098 [047 094]    ;SPR6POS := 0x0098
000028d2: 0174 0000 [047 098]    ;SPR6DATA := 0x0000    '  '
000028d6: 0170 00a0 [047 09c]    ;SPR6POS := 0x00a0
000028da: 0174 0000 [047 0a0]    ;SPR6DATA := 0x0000    '  '
000028de: 0170 00a8 [047 0a4]    ;SPR6POS := 0x00a8
000028e2: 0174 0000 [047 0a8]    ;SPR6DATA := 0x0000    '  '
000028e6: 0170 00b0 [047 0ac]    ;SPR6POS := 0x00b0
000028ea: 0174 0000 [047 0b0]    ;SPR6DATA := 0x0000    '  '
000028ee: 0170 00b8 [047 0b4]    ;SPR6POS := 0x00b8
000028f2: 0174 0000 [047 0b8]    ;SPR6DATA := 0x0000    '  '
000028f6: 0170 00c0 [047 0bc]    ;SPR6POS := 0x00c0
000028fa: 0174 0000 [047 0c0]    ;SPR6DATA := 0x0000    '  '
000028fe: 0170 00c8 [047 0c4]    ;SPR6POS := 0x00c8
00002902: 0174 0000 [047 0c8]    ;SPR6DATA := 0x0000    '  '
00002906: 0170 00d0 [047 0cc]    ;SPR6POS := 0x00d0
0000290a: 0174 0000 [047 0d0]    ;SPR6DATA := 0x0000    '  '
0000290e: 0170 00d8 [047 0d4]    ;SPR6POS := 0x00d8
00002912: 0174 0000 [047 0d8]    ;SPR6DATA := 0x0000    '  '

Now the 2nd line of text is displayed, exactly the same as all the previous lines.

The final line of the 2nd row of text (the score of 0 and the CREDIT 1 text) is again blank, but makes a small change at the end, setting SPR6DATA and SPR6DATB:

00002dca: 4f31 fffe [04f 02e]    ;Wait for vpos >= 0x4f and hpos >= 0x30.
00002dce: 01be 04f4 [04f 036]    ;COLOR31 := 0x04f4
00002dd2: 0172 6d60 [04f 038]    ;SPR6CTL := 0x6d60
00002dd6: 0170 0040 [04f 03c]    ;SPR6POS := 0x0040
00002dda: 0174 0000 [04f 040]    ;SPR6DATA := 0x0000    '  '
00002dde: 0170 0048 [04f 044]    ;SPR6POS := 0x0048
00002de2: 0174 0000 [04f 048]    ;SPR6DATA := 0x0000    '  '
00002de6: 0170 0050 [04f 04c]    ;SPR6POS := 0x0050
00002dea: 0174 0000 [04f 050]    ;SPR6DATA := 0x0000    '  '
00002dee: 0170 0058 [04f 054]    ;SPR6POS := 0x0058
00002df2: 0174 0000 [04f 058]    ;SPR6DATA := 0x0000    '  '
00002df6: 0170 0060 [04f 05c]    ;SPR6POS := 0x0060
00002dfa: 0174 0000 [04f 060]    ;SPR6DATA := 0x0000    '  '
00002dfe: 0170 0068 [04f 064]    ;SPR6POS := 0x0068
00002e02: 0174 0000 [04f 068]    ;SPR6DATA := 0x0000    '  '
00002e06: 0170 0070 [04f 06c]    ;SPR6POS := 0x0070
00002e0a: 0174 0000 [04f 070]    ;SPR6DATA := 0x0000    '  '
00002e0e: 0170 0078 [04f 074]    ;SPR6POS := 0x0078
00002e12: 0174 0000 [04f 078]    ;SPR6DATA := 0x0000    '  '
00002e16: 0170 0080 [04f 07c]    ;SPR6POS := 0x0080
00002e1a: 0174 0000 [04f 080]    ;SPR6DATA := 0x0000    '  '
00002e1e: 01fe 0000 [04f 086]    ;NO-OP(NULL) := 0x0000
00002e22: 01fe 0000 [04f 08a]    ;NO-OP(NULL) := 0x0000
00002e26: 01fe 0000 [04f 08e]    ;NO-OP(NULL) := 0x0000
00002e2a: 01be 04ff [04f 092]    ;COLOR31 := 0x04ff
00002e2e: 0170 0098 [04f 094]    ;SPR6POS := 0x0098
00002e32: 0174 0000 [04f 098]    ;SPR6DATA := 0x0000    '  '
00002e36: 0170 00a0 [04f 09c]    ;SPR6POS := 0x00a0
00002e3a: 0174 0000 [04f 0a0]    ;SPR6DATA := 0x0000    '  '
00002e3e: 0170 00a8 [04f 0a4]    ;SPR6POS := 0x00a8
00002e42: 0174 0000 [04f 0a8]    ;SPR6DATA := 0x0000    '  '
00002e46: 0170 00b0 [04f 0ac]    ;SPR6POS := 0x00b0
00002e4a: 0174 0000 [04f 0b0]    ;SPR6DATA := 0x0000    '  '
00002e4e: 0170 00b8 [04f 0b4]    ;SPR6POS := 0x00b8
00002e52: 0174 0000 [04f 0b8]    ;SPR6DATA := 0x0000    '  '
00002e56: 0170 00c0 [04f 0bc]    ;SPR6POS := 0x00c0
00002e5a: 0174 0000 [04f 0c0]    ;SPR6DATA := 0x0000    '  '
00002e5e: 0170 00c8 [04f 0c4]    ;SPR6POS := 0x00c8
00002e62: 0174 0000 [04f 0c8]    ;SPR6DATA := 0x0000    '  '
00002e66: 0170 00d0 [04f 0cc]    ;SPR6POS := 0x00d0
00002e6a: 0174 0000 [04f 0d0]    ;SPR6DATA := 0x0000    '  '
00002e6e: 0170 00d8 [04f 0d4]    ;SPR6POS := 0x00d8
00002e72: 0174 0000 [04f 0d8]    ;SPR6DATA := 0x0000    '  '
00002e76: 0174 0000 [04f 0dc]    ;SPR6DATA := 0x0000    '  ' Slight change from previous
00002e7a: 0176 0000 [04f 0e0]    ;SPR6DATB := 0x0000    '  ' lines

Now the game switches into 32 colour mode (5 bitplanes):

00002e7e: 5001 ff00 [050 004]    ;Wait for vpos >= 0x50, ignore horizontal.
00002e82: 0100 5000 [050 00c]    ;BPLCON0 := 0x5000    5 bitplane mode
00002e86: 00f0 0001 [050 00e]    ;BPL5PTH := 0x0001
00002e8a: 00f2 9998 [050 012]    ;BPL5PTL := 0x9998
00002e8e: 01a0 0102 [050 018]    ;COLOR16 := 0x0102
00002e92: 01a2 0103 [050 01c]    ;COLOR17 := 0x0103
00002e96: 01a4 0104 [050 020]    ;COLOR18 := 0x0104
00002e9a: 01a6 0105 [050 024]    ;COLOR19 := 0x0105
00002e9e: 01a8 0216 [050 028]    ;COLOR20 := 0x0216
00002ea2: 01aa 0217 [050 02c]    ;COLOR21 := 0x0217
00002ea6: 01ac 0363 [050 030]    ;COLOR22 := 0x0363
00002eaa: 01ae 0043 [050 034]    ;COLOR23 := 0x0043
00002eae: 01b0 0113 [050 038]    ;COLOR24 := 0x0113
00002eb2: 01b2 0101 [050 03e]    ;COLOR25 := 0x0101
00002eb6: 01b4 0000 [050 044]    ;COLOR26 := 0x0000
00002eba: 01b6 0000 [050 048]    ;COLOR27 := 0x0000
00002ebe: 01b8 0000 [050 04e]    ;COLOR28 := 0x0000
00002ec2: 01ba 0000 [050 054]    ;COLOR29 := 0x0000
00002ec6: 01bc 0000 [050 058]    ;COLOR30 := 0x0000
00002eca: 01be 0000 [050 05e]    ;COLOR31 := 0x0000
00002ece: ffdf fffe [0ff 0dc]    ;Wait for vpos >= 0xff and hpos >= 0xde.
00002ed2: 1001 ff00 [110 000]    ;Wait for vpos >= 0x10, ignore horizontal.
00002ed6: 0080 0000 [110 006]    ;COP1LCH := 0x0000
00002eda: 0082 229e [110 00a]    ;COP1LCL := 0x229e
00002ede: 009c 8010 [110 010]    ;INTREQ := 0x8010
00002ee2: ffff fffe              ;Wait for vpos >= 0xff and hpos >= 0xfe.
                                 ;End of Copperlist

Programming the copperlist manually would be a bit of a nightmare, so programmers use macros with repeat loops to ease the workload. Thanks to Mick West for sending the KernalPS.s file, you can see how the original file looks. I have removed some of the extraneous stuff to show mainly the sprite trick:

        dc.w    $2001,$ff00             ; dont do anything for few lines so we
                                        ; can change the copper in the VBL time        

        dc.w    dmaconw,%1000011001100000 ; Blitter nasty on

; for first 16 lines there are just 4 bpl
        dc.w    bplcon0,%0100000000000000 ; 4 BP, Low res
        ...
        dc.w    bplcon1
cop_scroll_register
        dc.w    0                       ; scroll for top part of screen

diwstrt_poke
        dc.w    diwstrt,the_diwstrt     ; display start
        dc.w    diwstop,(display_start+208)<<8&$ff00+$c1
        dc.w    ddfstrt,$0030           ; usually 38
        dc.w    ddfstop,$00d0
        
; This is a one bitplane playfield, formed by reusing the sprite 0
; dma slot, repeatedly writing to it with the copper
; - this is used so we can have sprites overlaying it
; without worrying about scrolling etc

panel_start equ *+18                    ; addr of first word in bpl
.wait   set     (display_start<<8)+$31  ; first line of sprite playfield
.spr    set     $0000
        rept    16

        dc.w    .wait,$fffe             ; wait for a bit
        dc.w    colour31,$4f4           ; first half colour
        dc.w    spr6ctl,$6d60
.pos    set     $0040                   ; $40 for screen x start

        rept    9                       ; 20 words per screen
        dc.w    spr6pos,.pos
        dc.w    spr6data,0              ; actual bpl data
.pos    set     .pos+8
        endr

        dc.w    copnop,0                ; dummy        
        dc.w    copnop,0                ; dummy
.pos    set     .pos+8
        dc.w    copnop,0                ; dummy
        dc.w    colour31,$4ff           ; second half colour
.pos    set     .pos+8

        rept    9                       ; 20 words per screen
        dc.w    spr6pos,.pos
        dc.w    spr6data,0              ; the actual bpl data
.pos    set     .pos+8
        endr

.wait   set     .wait+$0100
.spr    set     .spr+1
        endr
        dc.w    spr6data,0
        dc.w    spr6datb,0

panel_loff equ  20*8+12        

; after first 16 lines then turn fifth bitplane back on
        dc.w    (display_start+16)<<8+$01,$ff00
        dc.w    bplcon0,%0101000000000000 ; 5 BP, Low res

Post your comment

Comments

  • Gravatar for Scoose

    Are the other sprites used ?

    Scoose 24/03/2018 8:57pm (6 years ago)

  • Gravatar for DJ Metune

    Very interesting indeed! :-)

    Though I wonder what the purpose was as the background where the text is visible always is only in one solid colour. Maybe they gained some speed because bobs could fly over it without any extra redraws of the text/numbers.

    DJ Metune 04/04/2015 5:58pm (9 years ago)

RSS feed for comments on this page | RSS feed for all comments

Popular Sprite Tricks

Parasol Stars

Jim Power

2 sprites are displayed then repositioned horizontally right across the screen to create the colourful static background. The remaining sprites are used for the main character, the status bar and player bullets.

Parasol Stars

Risky Woods

The 16-colour background layer was created by using all 8 hardware sprites and repositioning them across the screen. The same 64 pixel wide graphics are repeated across the entire play area.

Parasol Stars

Shadow of the Beast

One of the first jaw-droppingly beautiful Amiga games that still looks great today. Sprites were heavily re-used on the screen, along with priority changes to make them appear between the playfields.

Parasol Stars

Stardust

The amazing tunnel sequence was created with a 6 frame animation sequence made with only 4 colours and mirrored vertically. The asteroid layer sits on top of this, with a status panel and player ship made of sprites sitting on top.