Analysis model: gpt-5.5 xhigh

# Titswinkle Lost In Space by Shadow Productions - Technical Dissection

`Titswinkle Lost In Space` is a September 1992 MS-DOS 64K intro by Shadow
Productions, coded by White Shadow. Demozoo lists it as a September 1992
MS-DOS `64K Intro`, and Pouet lists the same release date, platform, and type.
The Hornet 1992 mirror stores it as `tls.zip`.

Release year: 1992

The short version: this is the more elaborate sibling to `Deadbeat BBS`. It is
a single PKLITE-family packed MZ executable that expands to a 209 KB raw image.
The recovered runtime is a screen hack built from a story/title layer, an
XOR-obfuscated text stream, hardware pan/start-address updates, stack-fed strip
blitters, PIT/IRQ stage chaining, DAC palette streaming, and 16-color planar
VGA copy loops.

The public Pouet screenshot shows the later playfield: top scrolling plane
field, central raster/copper band, lower checkerboard, bobbing objects, and
right-side text scroller. My local DOSBox-X capture reaches the title/story
screen cleanly but does not synthesize the keypress needed to advance into the
later playfield. The article uses both: local title frames for the opening
state, and the public screenshot for the later effect state.

No old private contact details are reproduced here.

## Sources

- Demozoo production page:
  https://demozoo.org/productions/100963/
- Pouet production page:
  https://www.pouet.net/prod.php?which=29969
- Hornet 1992 index:
  https://files.scene.org/get/mirrors/hornet/demos/1992/00_index.txt
- Hornet mirror archive:
  https://files.scene.org/get/mirrors/hornet/demos/1992/tls.zip
- Scene.org Lost Found mirror:
  https://archive.scene.org/pub/demos/compilations/lost_found_and_more/titswinkle.zip
- Scene.org flerp mirror:
  https://archive.scene.org/pub/mirrors/flerp/.s/NotInDir.%2792/_Intro/tls.zip

## Visual References

The first image is the public Pouet screenshot. It shows the later screen hack,
after the opening title/story screen.

![Titswinkle Lost In Space public Pouet screenshot](images/titswinkle-lost-in-space-pouet.png)

The next frames are local DOSBox-X 2026.01.02 captures at fixed `cycles=1000`.
Timestamps are capture-stream timestamps from the AVI start, not in-demo
wall-clock promises. These frames stay on the title/story screen because no
keypress was injected.

![Titswinkle Lost In Space runtime contact sheet](images/titswinkle-lost-in-space-runtime-contact.png)

![Titswinkle Lost In Space runtime frame at 00:01.500](images/titswinkle-lost-in-space-runtime-00-01-500.png)

![Titswinkle Lost In Space runtime frame at 00:06.000](images/titswinkle-lost-in-space-runtime-00-06-000.png)

![Titswinkle Lost In Space runtime frame at 00:17.000](images/titswinkle-lost-in-space-runtime-00-17-000.png)

The diagnostic maps below are generated from the Hornet executable and the
`depklite` raw output. They are not runtime screenshots.

![Titswinkle Lost In Space depacked raw image byte map](images/titswinkle-lost-in-space-byte-map.png)

![Titswinkle Lost In Space VGA kernel map](images/titswinkle-lost-in-space-vga-kernels.png)

## Archive And Variant Evidence

The examined primary archive is the Hornet mirror package:

```text
b378ad590c73a1bdb258241b3c7beda2e98497f387ba1066c16f46982a861379  tls-hornet.zip
```

Hornet's 1992 index line is:

```text
tls.zip           59817 **    Titswinkle, Lost in Space by Shadow Productions
```

Demozoo currently links two scene.org mirror variants. They are different ZIP
containers, but all three examined archives contain the same executable bytes:

```text
b378ad590c73a1bdb258241b3c7beda2e98497f387ba1066c16f46982a861379  Hornet tls.zip
e44f7faee4de477db86f06652199b45e489181ae859f209b2ef57e19e28620ae  lost_found titswinkle.zip
786397a4b8a4fbf16eaf0823d70211e9ecd13b3a2f920742ea664794d4002015  flerp tls.zip
```

Each extracts to one 63,727-byte executable:

```text
TLS.EXE / tls.exe  63727 bytes  1992-09-14
```

Executable hash:

```text
a64387dd49ed1a52452232eaa425243417b0a789f842390fbb4a8fb919abd479  TLS.EXE
```

The flerp ZIP carries an ASCII-art ZIP comment and some mirrors use uppercase
`TLS.EXE`, but the executable is identical.

## Packed MZ Header

The visible MZ header is a packed real-mode wrapper:

```text
file size       63727 bytes
MZ image size   63727 bytes
e_cblp          239
e_cp            125
e_crlc          0
e_cparhdr       9 paragraphs = 144 bytes
load image      63583 bytes
e_minalloc      2403h paragraphs
e_maxalloc      FFFFh paragraphs
entry           CS:IP FFF0:0100
stack           SS:SP 0F8F:0400
reloc table     offset 0050h, zero entries
```

Again, `CS:IP = FFF0:0100` is the wrapper signature. Execution wraps into the
carrier at the start of the loaded image. The final code is reached only after
decompression, segment normalization, and state restoration.

The packed executable has high entropy across almost the whole file:

```text
00000-01000  entropy 7.52
01000-02000  entropy 7.53
02000-03000  entropy 7.60
...
0E000-0F000  entropy 7.65
0F000-0F8EF  entropy 7.67
```

That is consistent with a packed payload rather than a conventional linked
MZ program.

## Depacked Raw Image

The same scratch `depklite` helper used on the Shadow Productions BBStros
recovers a raw image:

```text
480b709e11927f89acd5f21f6bb5404a542539f80d942c9b6a54f80f824dbdc7  TLS.dep.EXE
209343 bytes
```

This is not a repaired MZ file. It is the expanded load-image material. Its
first bytes are not `MZ`.

The 8 KiB entropy profile is:

```text
00000-02000  entropy 5.77  code/tables
02000-04000  entropy 5.09  code/tables
04000-06000  entropy 4.27  structured data
06000-08000  entropy 4.24  structured data
08000-0A000  entropy 4.37  structured data
0A000-0C000  entropy 4.49  setup/render code and tables
0C000-0E000  entropy 1.58  mostly zero
0E000-14000  entropy 0.00  zero workspace
14000-16000  entropy 3.72  tables/workspace resumes
16000-18000  entropy 2.42  mostly zero/structured
18000-1A000  entropy 7.63  high-entropy art/table data
1A000-1C000  entropy 6.14  dense data
1C000-20000  entropy 2.26-4.21  low-entropy mask/table material
20000-24000  entropy 7.50  high-entropy art/table data
24000-30000  entropy 4.04-6.29  mixed tables/resources
30000-331BF  entropy 4.06-5.78  late code/text/tables
```

The interesting high-level split is:

```text
00000-0C000  code, tables, VGA/PIT/IRQ kernels
0C000-16000  long zero/workspace span
18000-24000  high-entropy art or packed visual tables
32480-32C90  XOR 49h story/title text block
```

Static pattern scan of the raw image:

```text
VGA A000h immediate                 1
sequencer 03C4h setup sites         2
CRTC 03D4h setup sites              3
attribute controller 03C0h sites    8
retrace 03DAh sites                 4
REP MOVSB sites                   261
REP MOVSW sites                    71
INT 08h / INT 09h vector handling   visible
INT 16h keyboard calls              2
INT 21h DOS vector/exit calls       10
```

The huge `REP MOVSB` count is not noise. The renderer deliberately uses many
short, unrolled strip copies.

## Opening Story Text

The long story text is not stored as plain ASCII. In the depacked image, spaces
appear as byte `69h` and many letters are shifted into punctuation-looking
bytes. XORing with `49h` reveals the text.

The tiny decoder model is:

```c
for each byte in story_text:
    decoded = encoded ^ 0x49;
```

Short decoded examples:

```text
Help me
I'm lost
Whitney
In SPACE
Tap any key to continue.
```

The longer story is the opening Titswinkle/Whitney setup that scrolls along
the top of the title screen. I am not reproducing it in full because the visual
purpose is enough for this technical pass.

The local DOSBox-X frames confirm the relationship between the decoded story
and the title screen:

```text
00:01.500  title card, Whitney/Titswinkle labels, prompt visible
00:06.000  top scroller begins with the story setup
00:17.000  top scroller has advanced far into the first paragraph
```

The existing public screenshot, runtime frames, contact sheet, byte map, and
kernel map were not regenerated, cropped, padded, resized, or touched in this
concordance pass.

## Runtime-To-Code Concordance

This concordance is deliberately split into two evidence classes. The local
runtime frames prove the opening title/story state at exact capture timestamps.
The public Pouet screenshot proves the later playfield's broad visual layout,
but not exact timing, because the local run did not inject the keypress needed
to advance past the title prompt.

```text
visual evidence                         code evidence
00:01.500 title card and prompt          XOR 49h story/title text block
00:06.000 top story scroller begins      decoded story stream plus title screen state
00:17.000 story text has advanced        opening text/scroller progression
public later playfield screenshot        planar VGA panning, palette, and strip kernels
top horizontal plane field               0x0A5C/0x0CCD fine pan and CRTC start
central raster/copper band               0x15DF DAC palette streamer
moving strips/bobs                       0x0B5C erase/copy and 0x11F2 dispatcher
wave/scroller staging                    0x132D stack-built wave blitter
small glyph/object chunks                0x1930 two-word row sprite/glyph copy
timer/keyboard stage behavior            0x1420 PIT, INT 08h, and INT 09h scheduler
later stable playfield scrolling         0x3B7A retrace-gated pan/start loop
```

The local title frames tie directly to the obfuscated story block. The raw image
contains the opening story encoded with XOR `49h`; decoding yields the same
Titswinkle/Whitney prompt and story phrases visible in the title captures. That
makes the opening state a concrete runtime-to-data match, not just a screenshot
label.

The public later playfield lines up with the hardware scroll code. Routines
`0x0A5C` and `0x0CCD` write Attribute Controller index `13h` through `03C0h`
for fine horizontal pan, then write CRTC start-address registers `0Ch/0Dh`
through `03D4h` for coarse movement. The later loop at `0x3B7A` repeats the
same idea under `03DAh` retrace gating. That is the code shape expected for the
top plane-field motion in the public screenshot.

The copper/raster color behavior is backed by the DAC streamer at `0x15DF`.
It derives a palette-table pointer from motion state and sends `0x2D` bytes,
or 15 RGB entries, to `03C9h`. That is a compact palette-band update, not a
full framebuffer redraw, and it explains how the central band can animate while
the CPU spends most of its frame budget on narrow strip work.

The moving-object layer is made from stacked narrow blitters. `0x0B5C` clears
and redraws `0x22`-byte strips over 40 rows. `0x11F2` is an unrolled dispatcher
that pops source/destination pairs and blasts each pair with `REP MOVSB`.
`0x132D` constructs stack-resident wave/row descriptors, and `0x1930` copies
two-word row chunks with a fixed stride. Together those routines match the
public screenshot's bobbing objects, right-side scroller material, and
checkerboard/playfield details much better than a full-screen chunky renderer
would.

The PIT/IRQ setup explains why the intro can be sensitive to held keys and
screen skipping. `0x1420` saves and replaces INT `08h` and INT `09h`, programs
PIT channel 0, and later stages use multiple reload counts before restoring the
vectors on exit. The title prompt and playfield transition are therefore part
of a custom timed/keyed scheduler rather than a plain BIOS `INT 16h` wait loop.

The boundary remains important: the opening screen has local timestamped
runtime proof, while the later playfield has public visual proof plus exact
code-mechanism support. A future capture with a controlled short keypress would
turn the later half from architectural concordance into frame-timed runtime
concordance.

## PKLITE-Family Carrier

The packed wrapper is the same broad family as `Deadbeat BBS`:

```text
late MZ entry at FFF0:0100
memory check and stack switch
bit-reservoir LZ stream
literal path through MOVSB
match path through backward ES-window REP MOVSB
segment normalization when source/output windows cross
far return into the restored application image
```

The visible packed-file string `Not enough memory` belongs to this carrier.
The Shadow Productions marker visible near the packed front is a wrapper or
data marker, not the public release date. The release metadata comes from
Demozoo/Pouet and the 1992 Hornet entry.

The practical consequence is important: most useful analysis must happen after
the depack step. The packed file mostly tells us "this is a compact 64K intro
carrier"; the raw 209 KB image tells us how the screen hack works.

## Runtime Mode Model

The recovered code does not look like a full-screen chunky mode-13h loop. It
uses planar VGA machinery:

```text
A000h segment reference
03C4h sequencer setup
03C0h attribute-controller horizontal panning
03D4h CRTC start-address writes
03C7h/03C8h/03C9h DAC palette streaming
03DAh retrace polling
PIT channel 0 reprogramming
INT 08h and INT 09h hooks
many narrow REP MOVSB/MOVSW strip copies
```

This matches the public screenshot and Pouet technical observations: a top
plane field scrolls independently, the middle band behaves like an
Amiga-copper-style color/raster effect, and the bottom playfield has small
moving objects over a checkerboard-like area.

## Kernel 0x0A5C / 0x0CCD - Fine Pan And CRTC Start

Two nearly identical blocks around `0x0A5C` and `0x0CCD` update VGA pan and
start-address state.

Key sequence:

```text
MOV DX,03C0h
MOV AL,33h
OUT DX,AL
MOV AX,BP
AND AL,07h
OUT DX,AL

MOV DX,03D4h
MOV AL,0Dh
...
MOV AX,BP
SHR AX,3
ADD AX,[6186h]
OUT DX,AL
...
MOV AL,0Ch
...
MOV AL,AH
OUT DX,AL
```

`33h` on the attribute controller is index `13h` with the palette-address bit
set. Attribute register `13h` is horizontal pixel panning. The low three bits
of `BP` therefore supply fine scroll within a character/byte boundary.

The CRTC register pair `0Ch`/`0Dh` is the display start address. The code takes
the coarse part of the same motion value by shifting right by three and adding
a base offset. Fine pan and coarse start address together produce smooth
horizontal movement.

High-level model:

```c
fine = motion & 7;
coarse = motion >> 3;

attr_write(0x13, fine);
crtc_write(0x0d, (base + coarse) & 0xff);
crtc_write(0x0c, (base + coarse) >> 8);
```

This is the top-screen hardware-scroll personality described on Pouet. It is
far cheaper than moving every byte of the top playfield each frame.

## Kernel 0x0B5C - Erase/Copy Strip Loop

The region around `0x0AE0` through `0x0C65` is a stack-fed strip renderer. It
first pushes many table-derived offsets:

```text
STD
LODSW
ADD AX,BP
PUSH AX
... repeated dozens of times ...
```

Then it clears a run of narrow strips:

```text
MOV DX,0022h
...
LODSW
ADD AX,BP
SHR AX,3
MOV BX,AX
ADD DI,AX
XOR AX,AX
MOV CX,DX
CLD
REP STOSB
SUB DI,BX
ADD DI,8
```

`DX = 0x22` gives a 34-byte strip width. The loop takes a motion-table word,
adds the subpixel phase in `BP`, converts to a byte offset with `>> 3`, clears
the strip, rewinds by the coarse offset, then advances to the next row or
sub-strip.

After that, it enables a graphics-controller path through `03CFh` and copies
source material:

```text
MOV DX,03CFh
IN  AL,DX
OR  AL,01h
OUT DX,AL

MOV BP,0028h
...
copy_row:
    compute source from BX/CX
    compute destination from DI + (AX >> 3)
    MOV CX,DX
    REP MOVSB
    adjust DI
    DEC BP
    JNE copy_row
```

`BP = 0x28` means 40 rows. This is a tall strip copy/erase path, useful for
the top plane field or moving vertical-ish objects.

High-level model:

```c
for each saved strip_position:
    dst = base + ((position + phase) >> 3);
    clear_bytes(dst, 0x22);

enable_graphics_controller_copy_bit();

for (int row = 0; row < 40; row++) {
    src = source_base + row_source_offset(row);
    dst = destination_base + ((position + phase) >> 3);
    copy_bytes(dst, src, 0x22);
}
```

The code is tuned for narrow updates. That is why the intro can combine
hardware pan with redrawn animated logo/bob material.

## Kernel 0x11F2 - Unrolled Strip Dispatcher

At `0x11F2`, the code becomes intentionally repetitive:

```text
POP SI
POP DI
MOV CX,AX
REP MOVSB
POP SI
POP DI
MOV CX,AX
REP MOVSB
... repeated many times ...
```

There are dozens of consecutive `REP MOVSB` sites. This is not compiler-style
loop output. It is an unrolled strip dispatcher: earlier code builds a stack of
source/destination pairs, and this hot path blasts each pair with the same byte
count in `AX`.

High-level model:

```c
for each prebuilt_pair_in_unrolled_order:
    si = pop();
    di = pop();
    cx = strip_width;
    rep_movsb(si, di, cx);
```

The advantage is predictable timing. A loop around a list would have branch and
index overhead for every small strip. Here, the branch overhead is mostly paid
before or after the unrolled block.

## Kernel 0x132D - Stack-Built Wave Blitter

The routine around `0x132D` uses the stack as a temporary output structure:

```text
MOV SI,6316h
MOV AX,SS
MOV ES,AX
CLI
MOV DI,SP
SUB DI,2
STD
```

Then it copies many `0x14`-word slices and interleaves one table word after
each slice:

```text
MOV CL,14h
REP MOVSW
SUB BX,2
MOV AX,[BX]
STOSW

MOV CL,14h
REP MOVSW
SUB BX,2
MOV AX,[BX]
STOSW
... repeated ...
```

At the end it restores `SP` from `DI`, re-enables interrupts, and returns to
normal direction:

```text
MOV SI,[BX]
ADD DI,2
MOV SP,DI
STI
CLD
```

That is a clever staging method. It constructs a stack-resident sequence of
addresses or row descriptors that a following unrolled blitter can pop rapidly.
The repeated `20`-word slices match the idea of a horizontal wave or story/text
strip split into many small sections.

## Kernel 0x1930 - Two-Word Row Sprite/Glyph Copy

The routine around `0x1951` is smaller and very regular:

```text
MOV BX,0002h
MOV BP,0026h

row:
    MOV CX,BX
    REP MOVSW
    ADD DI,BP
    ... repeated about 20 rows ...
```

Each row copies two words, then advances `DI` by `0x26`. A two-word copy is
four bytes, which is 32 planar pixels in a single plane-selection context or a
narrow part of a multi-plane object. The skip makes the total row pitch
approximately `0x2A` bytes after the four bytes copied.

High-level model:

```c
for (int row = 0; row < about_20; row++) {
    copy_words(dst, src, 2);
    dst += 0x26;
}
```

This is suitable for small bobs, star shapes, title glyph chunks, or the
right-side scaled scroller. In the public playfield, there are several small
objects and scroller strips that need exactly this kind of narrow row copy.

## Kernel 0x1420 - IRQ And PIT Scheduler

The code around `0x1420` installs timer and keyboard handlers:

```text
MOV AX,3508h
INT 21h
store old INT 08h ES:BX

MOV AX,3509h
INT 21h
store old INT 09h ES:BX

MOV AX,2508h
DS = CS
DX = handler_08
INT 21h

MOV AX,2509h
DS = CS
DX = handler_09
INT 21h
```

It also programs PIT channel 0:

```text
MOV AL,34h
OUT 43h,AL
MOV AX,1799h
OUT 40h,AL
MOV AL,AH
OUT 40h,AL
```

Later interrupt stages use other reload counts such as `0248h`, `0240h`,
`0B28h`, `015Fh`, and `015Eh`. That strongly suggests a chained timing system
where one interrupt stage reprograms the next time slice. The handlers write
to the PIC with `OUT 20h,20h` before returning with `IRET`.

Exit cleanup restores the vectors and PIC mask, clears DAC state, switches
back to text mode with `INT 10h, AX=0003h`, and exits through DOS.

The user-visible quirk from Pouet, where held keys can skip a screen, matches
this code style: keyboard handling is custom and tightly coupled to the timer
stages, not a slow DOS key-read loop.

## Kernel 0x15DF - Palette Streamer

The routine at `0x15DF` updates a slice of DAC palette data:

```text
MOV SI,849Eh
MOV AX,[6174h]
SUB AX,795Ah
SHR AX,5
ADD SI,AX
LODSW
MOV SI,AX

MOV DX,03C7h
MOV AL,01h
OUT DX,AL
INC DX
OUT DX,AL
INC DX
MOV CX,002Dh
REP OUTSB
```

The code selects a palette table from motion state, then writes `0x2D` bytes
to the DAC data port. Since each DAC color is three bytes, `0x2D` bytes is 15
RGB entries.

High-level model:

```c
palette_src = palette_table[(motion - base) >> 5];

out(0x03c7, 1);      // read-index side effect / state setup
out(0x03c8, 1);      // write index
rep_outsb(0x03c9, palette_src, 45);
```

This is the clearest static evidence for the copper/raster color behavior. The
handler does not rewrite all 256 DAC entries; it streams a compact active band.

## Late Screen Loop 0x3B7A - Retrace And Start Address

Another later loop around `0x3B7A` waits on `03DAh`, updates a counter, and
changes panning/start address:

```text
MOV DX,03DAh
wait/retrace state
...
ADD [BDF3h],2
CMP [BDF3h],4204h
...
MOV BP,[BDF3h]
SHR BP,3
AND AX,7

OUT 03C0h,33h
OUT 03C0h,low3
OUT 03D4h,0Dh / start low
OUT 03D4h,0Ch / start high
JMP loop
```

This is the same fine-pan/coarse-start method in a later context, but now it
is wrapped in retrace polling. That makes it a good candidate for the public
playfield state, where the top field and lower layers have to stay stable while
the start address and palette timing move.

## Why The Effect Feels Larger Than 64K

The intro is small on disk because it combines compression and hardware
specialization:

```text
PKLITE-family carrier       63 KB executable -> 209 KB raw image
XOR story text              cheap text obfuscation, no separate resource file
hardware fine pan           03C0h attribute register 13h
hardware coarse pan         03D4h start-address registers 0Ch/0Dh
palette/raster motion       45-byte DAC bursts from IRQ stages
moving strips               stack-fed REP MOVSB dispatch
small glyph/bob chunks      two-word row copies with fixed stride
title/story persistence     scroller text over static title art
```

This is an economical design. The CPU does not redraw the whole picture each
frame. It scrolls what the VGA card can scroll, changes colors where timed
palette changes are cheaper than bitmap redraw, and spends CPU time on narrow
moving strips.

## Relationship To Deadbeat BBS

`Deadbeat BBS` and `Titswinkle Lost In Space` are adjacent Shadow Productions
pieces from 1992, and the similarity is visible in both code and style:

```text
both are single packed MZ files
both use a PKLITE-family late-entry carrier
both expand to much larger raw images
both lean on planar VGA and narrow strip updates
both use hardware scroll/palette tricks rather than full-frame chunky redraw
```

`Titswinkle` is the more ambitious one. It keeps an opening narrative/title
screen, then moves into a denser multi-band screen hack with independent
scrolling, palette/raster timing, bobs, and a checkerboard lower field.

## Limits And Next Steps

This pass proves:

```text
archive and executable identity
mirror ZIP variants with identical executable payload
packed MZ header and PKLITE-family wrapper shape
raw depacked size and byte layout
XOR 49h story text block
local title/story runtime frames at exact capture timestamps
VGA attribute/CRTC panning loops
PIT/IRQ vector setup and cleanup
DAC palette-streaming loop
stack-fed strip-copy blitter structure
```

It does not prove exact animation timing for the later playfield, because the
local capture intentionally did not inject keypresses and therefore did not
advance past the title screen. A future timed pass should run the demo with a
controlled short keypress after the title prompt and capture the public-screen
playfield at several timestamps.
