<!-- Canonical page: https://reversedwithai.com/p/firefighter-dos-game-rust-port-chatgpt -->
Canonical page: https://reversedwithai.com/p/firefighter-dos-game-rust-port-chatgpt

# Decompiled the 1985 DOS game Firefighter to Pascal and ported it to Rust with ChatGPT

> A 1985 shareware game, decompiled to Pascal and rebuilt in Rust.

ChatGPT 5.5 decompiled the DOS binary of Firefighter to readable Borland Pascal and then translated it to Rust. Eric S. Raymond ships it as a terminal game with the original author's permission.

## Key facts

- Target: Firefighter (DOS shareware, 1985)
- Category: Games and mods
- Platform: MS-DOS to Unix terminal (Rust)
- Models: GPT-5.5
- Tools: ChatGPT, Rust
- Outcome: Works
- License: BSD
- Checks: Source available: yes; Repro steps: not reported; Real hardware: not reported; Verified by others: not reported
- Author: [Eric S. Raymond](https://gitlab.com/esr)
- Added: 2026-10-18
- Updated: 2026-10-18
- Sources reviewed: 2026-10-18 (editor)

## What was done

Eric S. Raymond recovered Firefighter, a 1985 DOS shareware game by Eben Sprinsock, from its binary alone. ChatGPT 5.5 decompiled the executable back to Borland Pascal, then translated that Pascal to Rust. The result runs in an ANSI terminal and is released as open source with the original author's permission.

The project's history file lists the steps. Raymond says the model could tell the source language from the way string literals were stored. In the post on X, Raymond adds that it gave back readable Pascal with sensibly chosen function and variable names. Raymond added an optional RNG seed on the command line, cursor movement with mouse clicks and other interface changes.

The gameplay logic is unchanged from the shareware version, while the interface is modernised. Raymond also fixed what looks like a bug in the original: the maximum scores per difficulty did not match the real score calculation. The port is part of Raymond's collection of heritage games, and Raymond applies a joint copyright with Sprinsock.

## Human work and limitations

Raymond made the interface changes and the scoring fix himself on top of the model's translation.

## Questions about Firefighter (DOS shareware, 1985)

### What is the Firefighter (DOS shareware, 1985) project?

ChatGPT 5.5 decompiled the DOS binary of Firefighter to readable Borland Pascal and then translated it to Rust. Eric S. Raymond ships it as a terminal game with the original author's permission. It is listed under Games and mods for MS-DOS to Unix terminal (Rust).

### Which AI model was used on Firefighter (DOS shareware, 1985)?

The entry names GPT-5.5. The tools named alongside are ChatGPT and Rust.

### Did the AI reverse engineering of Firefighter (DOS shareware, 1985) work?

Its author reports that it works. Checks recorded: source available yes.

### Is the source code for Firefighter (DOS shareware, 1985) available?

Yes. The code, patches or tooling are public: https://gitlab.com/esr/firefighter. Licence: BSD.

## Sources

- [Repository](https://gitlab.com/esr/firefighter)
- [Discussion](https://x.com/esrtweet/status/2106983467141509385)

Figures are reported by the author and not measured by this site, except the commit history. Entry drafted with AI from the linked sources and checked against them.

Cite as: Eric S. Raymond (2026). Decompiled the 1985 DOS game Firefighter to Pascal and ported it to Rust with ChatGPT. Reversed with AI. https://reversedwithai.com/p/firefighter-dos-game-rust-port-chatgpt
