Skip to navigation

Elite on the BBC Micro

Workspaces: K% [6502SP version]

Name: K% [Show more] Type: Workspace Address: &8200 to &85FF (&8500 to &88FF in the Executive version) Category: Workspaces Summary: Ship data blocks Deep dive: Ship data blocks The local bubble of universe
Context: See this workspace in context in the source code Variations: See code variations for this workspace in the different versions References: This workspace is used as follows: * ANGRY calls K% * DCS1 calls K% * DEMON calls K% * DOEXP calls K% * MAS2 calls K% * MAS3 calls K% * Main flight loop (Part 1 of 16) calls K% * Main flight loop (Part 14 of 16) calls K% * Main flight loop (Part 9 of 16) calls K% * Main game loop (Part 4 of 6) calls K% * SPS3 calls K% * SPS4 calls K% * TAS4 calls K% * UNIV calls K% * VCSU1 calls K% * WARP calls K%

Contains ship data for all the ships, planets, suns and space stations in our local bubble of universe. The blocks are pointed to by the lookup table at location UNIV. The first 720 bytes of the K% workspace hold ship data on up to 20 ships, with 37 (NI%) bytes per ship. See the deep dive on "Ship data blocks" for details on ship data blocks, and the deep dive on "The local bubble of universe" for details of how Elite stores the local universe in K%, FRIN and UNIV.
IF _SNG45 OR _SOURCE_DISC ORG &8200 ELIF _EXECUTIVE ORG &8500 ENDIF .K% SKIP 0 \ Ship data blocks and ship line heap