Commando
Routines
Address
Description
6400
Block of redirects
6456
Trigger sound effect A into free slot at $6433 (unconfirmed)
6469
Clear 7 bytes at $6433
6474
Sound-effect dispatcher, 7 channels (unconfirmed)
6495
Decay sound-effect counters at $6433 (unconfirmed)
64C7
Play beep tone (pitch $6437, duration loop) (unconfirmed)
64E9
Sound param calc -> $6575 (uses $6438) (unconfirmed)
64F9
Sound param calc -> $6575 (uses $6439) (unconfirmed)
6505
Sound param calc -> $6575 (uses $6436) (unconfirmed)
6533
Routine at 6533
6575
Routine at 6575
6593
Scan $6648 table, call $65A5 for active entries
65A5
Routine at 65A5
65F6
Menu key check, set carry/B=$12 (unconfirmed)
6600
Find free slot in $6648 table
6626
Prepare records and variables at $6648
6751
Set up scrolling string
676B
Shift scroll pattern into left border column (unconfirmed)
679D
Advance scroll-message pointer, copy next char's font row to $681E
6825
Update Score
6896
Convert (H,L) screen coords to attribute address
68A6
Zero screen rows using SP as pointer (B rows)
68CA
Routine at 68CA
6950
Compute row attribute address, call $69B4 (unconfirmed)
6975
Fill status-bar columns down, calling $699A per column (unconfirmed)
699A
Routine at 699A
69B4
Compute attribute address for tile (D,E)
69D2
Routine at 69D2
69F3
Top Score and Main Menu??
6A1E
Redefine Keys
6A8C
Routine at 6A8C
6AE1
Prepare status bar screen: fill, set scroll handler
6B14
Wait key unpress, wait key press
6B21
Clear playfield and status screen/attribute areas
6B4C
Zero rectangle at HL (C rows x B bytes)
6B87
Draw menu box border/frame (unconfirmed)
6BAC
Routine at 6BAC
6BBB
Start Game
6C7A
We've got A more grenades
6C80
Update grenades number on the screen
6C96
Print Area number
6C99
Print 2-digit number A
6CAE
Game Over
6E11
Print table row using $6E34 (unconfirmed)
6E34
Print char with derived attribute (unconfirmed)
6E7B
Routine at 6E7B
6ECD
Routine at 6ECD
6F1D
Routine at 6F1D
6F46
Prepare records at $6FE5
6F52
Look up record in $6FE5 table, mask low bits (unconfirmed)
6F79
Find free record in table at $6FD9
6FC7
Prepare records at $6FD9
6FF5
Look up record entry for door/scroll trigger (unconfirmed)
706E
Unpack $66D1 record, scale coordinate x4 (unconfirmed)
70BD
XOR attribute pattern onto screen, explosion effect (unconfirmed)
70EC
Copy 64 bytes $66D1 to $6711
70F8
Find a place in Top Score table
7143
Select joystick type
71A8
Print string HL
71B6
Routine at 71B6
7251
Check menu keys
725D
Print immediate string checking menu keys
7274
Print Score Table
7357
Game main loop / frame handler
73B7
Read Keyboard
7405
Compute code checksum
7511
XOR AF and AF' with every byte in $F900-F9FF
7547
Read input: joystick or keyboard
75A8
Read keyboard in game mode
75BE
Fill screen rectangle with byte
75D2
Print key entered on Redefine Keys
7615
Print immediate string
7621
Print HL as 4-digit hex/BCD (unconfirmed)
7637
Print Char
7767
Char $02: set spacing/mode ($FDB1) from arg, range 0-3
777A
Char $00: clear screen (attributes + bitmap)
7795
Fill all screen attributes with D
77A4
Char $04: advance format counter by 2, store fill char (unconfirmed)
77AC
Char $0A: increment format counter, abort if it reaches $31
77B8
Char $0B: decrement format counter, abort on underflow
77C2
Char $08: decrement format counter, abort if negative
77CB
Char $09: increment format counter, store fill char once $20 reached
77D5
Char $12: set/clear bit 6 of $FDA0 from arg (0/1)
77EB
Char $19: set/clear flag bit 0 ($FDAF) from arg
77FD
Char $10: set field bits 0-2 of $FDA0 from arg
7811
Char $11: set field bits 3-5 of $FDA0 from arg
7828
Char $16: set print position, 2 bounds-checked args
783E
Char $03: repeat character H, L times
784A
Char $13: set fill char ($FD9F) from arg
7852
Char $14: set tab stop, advance format counter
7866
Char $1A: set Font address ($FDA3) from arg word
786E
Char $0C: print padded field using $FDB0 width
787F
Char $18: set width/column counter ($FDB0) from arg
7887
Char $15: set/clear flag bit 1 ($FDAF) from arg
7896
Char $01: reset print format state
78BF
-> $7A10
78C4
Routine at 78C4
78C7
Routine at 78C7
792C
Prepare at new Area
796A
Prepare New Game
79CA
Routine at 79CA
79E1
Init $FF00 buffer entries (32 slots, unconfirmed)
79FB
Calculate checksums??
7A10
Abort: restore stack and interrupts, return to frame loop
7A1E
Set up interrupt vector table at $FB00 (unconfirmed)
7A42
Game main loop / frame handler (redirect)
7A45
Prepare $FE00 table - addresses for every even screen line
7A5C
Delay by BC HALTs
8003
Advance level scroll: walk $FF00 buffer, process sequence record (redirect)
8006
Reset R register (random seed), inside $9193 (redirect)
800C
Multiply HL by 10, add DE (redirect)
800F
Mark map cells for object IX, direction-aware (redirect)
806B
Mark map cells for object IX, direction-aware
80E4
Mark 3 cells in $1600 map, B=1 (entry to $80ED)
80EA
Mark 3 cells in $1600 map, B=C (entry to $80ED)
80FB
Mark cells in $1600 map, B=1 (entry to $8104)
8101
Mark cells in $1600 map, B=C (entry to $8104)
8122
Set/test flag in $1600 map at tile (D,E)
822B
Update vehicle position/state, drift toward player (unconfirmed)
82C1
Set object state flags, call $806B (unconfirmed)
82E1
Advance/rotate object buffer pointer (unconfirmed)
834B
Draw sprite HL
83B8
?? Smth about Jeep
8458
Update Motorbike/Jeep type state (unconfirmed)
8471
?? Smth about Motorbike
8497
Get pseudo-random value / update counter at (HL) (unconfirmed)
8500
?? Smth with Motorbike sprite
854A
Sprite draw dispatch: clip and compute screen address
85AB
?? Smth about Truck
8618
Draw two-part sprite from record at HL (unconfirmed)
867C
Clip sprite rectangle against screen edge (vertical)
86B8
Get Truck sprite to $6300 buffer and shift it if needed
86F5
Routine at 86F5
872F
Fill attribute cells below sprite via SP push (unconfirmed)
876E
Draw walls??
87F1
Routine at 87F1
8914
Draw sprite at ($C006), then fill $1600 map tiles it covers
896D
Get attributes address for the screen line
899E
Compute screen draw address for sprite, save state to buffer
89F3
Set attribute color for B cells at HL
8A03
Routine at 8A03
8A14
Sprite draw dispatch variant, C=4 (unconfirmed)
8A7B
Sprite draw dispatch: clip and compute screen address, C=$08
8AC3
Sprite draw dispatch: clip and compute screen address, C=$0C
8CC9
Clip sprite, then AND/OR-mask blit rows via SP into screen
8E83
Routine at 8E83
8E92
Multiply HL by 10, add DE (unconfirmed)
8EB5
Routine at 8EB5
8EE3
Grenade-crate pickup: draw, on collect award grenades/score/sound
8F17
Draw scenery sprite ($C016) if row on-screen (unconfirmed)
8F26
Draw scenery sprite ($C018) if row on-screen (unconfirmed)
8F35
Draw scenery sprite ($C01A) if row on-screen (unconfirmed)
9014
Routine at 9014
903E
Routine at 903E
904D
Routine at 904D
90A1
Adjust and clip sprite draw, calls $8A14 (unconfirmed)
90AC
Routine at 90AC
9132
Decrement Land space or process next record in the sequence
917C
Walk $FF00 buffer chain (offset $FD88), increment field at +4
9193
Advance level scroll: walk $FF00 buffer, process sequence record
91E3
Routine at 91E3
9204
Process record codes $01-28, not $22
921F
Insert entry into $FF00 buffer chain (unconfirmed)
98D0
Update object IX position, clip to screen, dispatch sprite draw (redirect)
98D3
HL = HL + A (redirect)
98D6
(HL) -> HL (redirect)
98D9
Convert row number to screen line address (redirect)
98DC
DOWN HL (redirect)
98DF
UP HL (redirect)
98EA
HL = HL + A
98F0
(HL) -> HL
98F5
Convert row number to screen line address (via $FE00 table)
9904
DOWN HL - move HL to the next screen line
9913
UP HL
9922
Update object IX position, clip to screen, dispatch sprite draw
9A46
Routine at 9A46
9A6E
Clip sprite edge, dispatch to masked blit
9AE6
Routine at 9AE6
9B05
Masked-OR blit variant, draws sprite row across screen thirds
9B61
Routine at 9B61
9B97
Routine at 9B97
9BCB
Routine at 9BCB
9BF5
Routine at 9BF5
9C23
Compute screen address for sprite row via IX object (unconfirmed)
9C6B
Erase sprite: AND-mask bytes off screen, SP walks data as pointer
9CB1
Erase sprite: AND-mask bytes off screen, SP walks data as pointer
9CED
Erase sprite variant: AND-mask 2 bytes per column via SP
9D1F
Erase sprite: AND-mask bytes off screen, SP walks data as pointer
9D5B
Erase sprite variant: AND-mask row bytes via SP
9D8D
Unmasked-OR blit variant, draws opaque sprite row across screen thirds
9DCC
Unmasked-OR blit variant: 2 bytes per column via SP
9E03
Unmasked-OR blit variant: 2 bytes per column via SP
9E32
Unmasked-OR blit variant: 2 bytes per column via SP
9E69
Unmasked-OR blit variant: alternating columns via SP
9E98
Masked-OR blit variant, draws sprite row across screen thirds
9EDF
Unmasked-OR blit, draws opaque sprite row across screen thirds
9F1D
Off-screen sprite draw: clip, compute address, dispatch blit
9FDE
Routine at 9FDE
9FF5
Routine at 9FF5
DC83
Get random byte?? (redirect)
DC86
Entry E=0, dispatch bullet/collision handler via $DF39 (redirect)
DC89
Initialization and go to game main loop (redirect)
DC8C
Check IX flag and column bound, dispatch (redirect)
DC8F
Check screen brightness threshold, inside $DD8D (redirect)
DC92
Entry E=2, dispatch bullet/collision handler via $DF39 (redirect)
DC95
Routine at DC95
DCAF
Routine at DCAF
DCDF
Initialization and go to game main loop
DD71
Process object records at $5B11
DD89
Process Player's object record
DD8D
Process object IX??
DE91
Game's main loop, Part 1
DEEF
Game's main loop, Part 2
DF16
Get random byte??
DF33
Entry E=2, dispatch bullet/collision handler via $DF39
DF37
Entry E=0, dispatch bullet/collision handler via $DF39
DF67
Routine at DF67
DF6D
Routine at DF6D
DF71
Routine at DF71
DF7B
Bullet collision check, carry set on hit
E01B
Check IX flag and column bound, dispatch (unconfirmed)
E100
Set up player object pointers (IX=$5BDA) (redirect)
E103
Check fire button and joystick input (redirect)
E106
Update boss/enemy state via IX=$5B11 (redirect)
E109
Rebuild active-object list at $F900 from $FF00 buffer (redirect)
E10C
Decrement Enemy delay ($FDDD), spawn enemy by Area ($FDE5) when due (redirect)
E10F
Find free enemy slot in $5B11 table, inside $E01B (redirect)
E112
Common enemy-object init helper (redirect)
E1AC
Common enemy-object init helper (unconfirmed)
E1B5
Routine at E1B5
E1D1
Check pickup/collision near object, award score
E224
Routine at E224
E2DD
Init enemy object (BC=$0806, type $07) (unconfirmed)
E2EA
Decrement Enemy delay ($FDDD), spawn enemy by Area ($FDE5) when due
E4FC
Set up player object pointers (IX=$5BDA)
E5B8
Convert direction code (masked 0-15) to E delta (unconfirmed)
E5DB
Move enemy toward target, clamp to bounds (unconfirmed)
E628
Routine at E628
E648
Move right: check keys/state, advance E and wrap
E679
Move left: check keys/state, advance E and wrap
E6A8
Routine at E6A8
E6DB
Move up/down: check states, adjust row (unconfirmed)
E6FE
Update boss/enemy state via IX=$5B11 (unconfirmed)
E77C
Scan object table for entry near position (unconfirmed)
E794
Routine at E794
E86B
Routine at E86B
E881
Routine at E881
E8A0
Routine at E8A0
E90A
Routine at E90A
E972
Dispatch enemy AI by state (IX+$12)
EB13
Set enemy AI delay/direction by Area number ($FDE5)
EB68
Routine at EB68
EB7B
Routine at EB7B
EB96
Routine at EB96
EBE1
Compute direction bits toward player position (unconfirmed)
EC1B
Check enemy position on-screen, trigger action (unconfirmed)
EC58
Set enemy sub-state (IX+$0C) by threshold, reset delay/target
ECC1
Check fire button and joystick input
ED31
Look up entry in table at $EC81 (unconfirmed)
ED52
Rebuild active-object list at $F900 from $FF00 buffer
EDC8
Routine at EDC8
EDD6
Init object timer field via $EDC8 (unconfirmed)
EE11
Routine at EE11
EE15
Routine at EE15
EF37
Init object record via $EDC8, entry size $0E
EF7C
Init two-part record via $EDC8, check record type (unconfirmed)
EFDD
Check active count vs limit, reset counter/state (unconfirmed)
F076
Routine at F076
F114
Shift object table entry, mark boundary $81 (unconfirmed)
F126
Shift object table entry, mark boundary bytes $81 (unconfirmed)
F14C
Spawn enemy from record, check readiness timer (unconfirmed)
F180
Update enemy state timer, check row threshold (unconfirmed)
F1BB
Check position bounds, set flags (unconfirmed)
F200
Scan object table (IX,$0E stride), compute and store motion vector (redirect)
F203
Set up primary projectile/vehicle table $F73C, process motion (redirect)
F206
Scan explosion-effect table $F856, entry stride $14 (redirect)
F209
Scan player-bullet table at $F82D, init $F8ED marker (redirect)
F20C
Scan player-bullet table at $F82D, entry stride 5 (redirect)
F20F
Select secondary projectile/vehicle table $F7C9 (spawn entry, redirect)
F212
Set up grenade table $F81E, dispatch (redirect)
F21B
Select grenade table $F81E (spawn entry, redirect)
F21E
Clamp/check coordinate H (redirect)
F221
Routine at F221
F237
Clear/init table records (entry size $0E)
F23B
Routine at F23B
F24A
Scan player-bullet table at $F82D, entry stride 5
F26E
Scan player-bullet table at $F82D, init $F8ED marker
F34F
Clamp/check coordinate H (unconfirmed)
F36D
Set up grenade table $F81E, dispatch
F37B
Set up secondary projectile/vehicle table $F7C9, dispatch (unconfirmed)
F381
Set up primary projectile/vehicle table $F73C, process motion (unconfirmed)
F4E3
Select grenade table $F81E (spawn entry)
F4E9
Select secondary projectile/vehicle table $F7C9 (spawn entry)
F4F6
Scan object table (IX,$0E stride), compute and store motion vector
F582
Generate rotated bit-mask pattern A (unconfirmed)
F5A0
Generate rotated bit-mask pattern A, variant (unconfirmed)
F5BF
Routine at F5BF
F5C6
Routine at F5C6
F5CD
Check row/column bounds (used by $F582/$F5A0)
F5DD
Set explosion/effect buffer values from object IX (unconfirmed)
F68A
Decompose position into sub-pixel fields ($F8CF-$F8D1) (unconfirmed)
F6C2
Scan explosion-effect table $F856, find/init free entry (unconfirmed)
F707
Scan explosion-effect table $F856, entry stride $14 (unconfirmed)
FCFC
Game main loop / frame handler (redirect)
FD91
Delay by BC-1 HALTs (redirect)