Skip to content

About

The documentation commons for StarLancer (2000): file formats, engine RE and the scene map. To play or contribute code, see OpenReliant.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

1 star

Watchers

0 watching

Forks

Starlancer Open-Source Project

CI Code: GPL-3.0-only Docs: CC BY 4.0 Python 3.8+ No game data Static only

The documentation commons for Starlancer (Digital Anvil / Microsoft, 2000; developed by Warthog), the space-combat sim: its file formats, its engine and the scene's shared research, written up so that any project may build on them.

⚖️ You must own a legal copy of Starlancer to use these tools with the game. This repository contains only original code and documentation — no game binaries, assets, or other copyrighted material, and none should ever be committed here (see .gitignore).

Where to go

The scene's centre is OpenReliant, an open-source, faithful reimplementation of the StarLancer engine in Zig on SDL3. It runs natively on Windows, Linux and macOS from your own retail discs, and its first campaign mission already plays from start to finish. That is where StarLancer is being rebuilt, and where this project sends its own new code.

You want to… Go to
Play StarLancer on a modern PC OpenReliant: latest release · installation · controllers
Contribute code: engine work, fixes, mod tools OpenReliant: contributing guide · issues · milestones
Make mods OpenReliant's Modding milestone, where mod archives, new ship types, textures and sounds are being designed. Until it lands, the format specs below are the map.
Understand a file format or the original engine This repository: the documentation and the wiki
Run your original CD copy on Windows 10/11 This repository: Starlancer Studio and the setup checklist
See every project in the scene, and what each may take from the others docs/modding-scene.md §4

What this repository is

Starlancer-OSS began as a toolkit for the original executable. Since September 2026 it is the scene's documentation commons:

  • Research stays here, under CC BY 4.0, so that every Starlancer project can use it whatever its own licence: OpenReliant, neoslancer and StarLancerEditor alike. The format specs, the engine map, the .DTE scripting reference and the reverse-engineering notes all live here, with their evidence.
  • New code goes upstream. Engine work and modding tools are contributed to OpenReliant rather than grown in parallel here. The first, a RefPack encoder, is openreliant#429.
  • The original-game kit is complete. Starlancer Studio, the patch pack, the controller shim and the editors are maintained for bug fixes, not extended.

Documentation

Formats & archives

Path Description
docs/hog-format.md .HOG archive format (Electronic Arts BIGF).
docs/stats-format.md SHIP/GUN/MISSILESTATS.BIN — 352-byte stat record layout.
docs/shp-format.md .SHP 3D-model format: RefPack container, tagged-chunk stream, parts / LODs / attachments / animations — independently derived, every field evidence-tagged.

Missions & campaign

Path Description
docs/dte-format.md .DTE mission format: RefPack container, trigger system, scripting VM.
docs/dte-scripting-reference.md Complete trigger / Executor-command / AI-code / opcode tables.
docs/campaign-flow.md Campaign mission flow: progression rule, in-game↔.dte numbering, the 24-mission map.

Engine & modern systems

Path Description
docs/engine-map.md Engine architecture: middleware stack + per-subsystem address map.
docs/modern-fixes.md Modern-Windows fix catalogue (boot-video skip, wrappers, native Hor+ widescreen, DRM, audio …) — RE-backed.
docs/running-on-modern-windows.md Setup checklist & folder layout — ordered, end-to-end guide to running your owned copy on Win10/11 (DRM, wrappers, our patches, controller, DirectPlay) + troubleshooting map.
docs/modding-scene.md Community modding tools, the widescreen gap, and DRM notes.
docs/external-re-credits.md Provenance record — whose external reverse-engineering we build on, what we verified ourselves, and what we deliberately did not copy.

Game content reference

Path Description
docs/game-reference/ Ships, fighters, characters, the full campaign, factions and weapons. Compiled from the Starlancer Fandom Wiki (CC BY-SA 3.0) and cross-checked against our RE.

See also the project wiki for the engine reference.

The original-game kit

For the original executable, from your own CD: the patches, editors and controller shim that get it running on Windows 10/11. The kit is complete and maintained for bug fixes only; to play StarLancer on a modern system, OpenReliant is the better road.

Starlancer Studio — the all-in-one app

⬇ Download StarlancerStudio.exe · Windows, no install · verify with the release's SHA256SUMS.txt

tools/slstudio_app.py is a single desktop app (and a one-file .exe) that fronts the whole toolchain in a dark "Alliance Naval Command" cockpit — eight sections:

  • Dashboard — at-a-glance status of your install (the three EXE fixes, controller shim, boot logos), a one-click Apply Recommended Fixes, and a backup / restore manager.
  • Patcher — widescreen Hor+ and the RE'd crash fixes, per-fix verify / revert.
  • Ship Switcher, Stats Editor, HOG Tools — the editors, in a GUI.
  • Controller Shim — install the XInput → DirectInput proxy for modern pads.
  • Boot Videos — blank the startup branding logos.
  • Ready-to-Play — a wizard that stages a complete, patched, ready-to-run copy into an output folder.

Like every tool here it is static — it reads and patches local copies only and never launches the game. The only third-party runtime dependency (customtkinter) is bundled. As a one-file PyInstaller build, some antivirus heuristics may flag it — a common false positive; the full source is in this repo, and the release ships a SHA256SUMS.txt to verify your download.

Tools

Python 3 (plus one PowerShell + Ghidra-script pair). The command-line tools are standard-library only; Starlancer Studio and the icon/build tooling have optional dependencies listed in requirements-optional.txt. The tools operate on files from your own copy of the game; none contain or redistribute game data, and none ever launch the game.

Archive, formats & missions

Path Description
tools/hog_extract.py List / extract .HOG archives; --decompress expands RefPack payloads (98% of resource.hog).
tools/refpack.py EA RefPack / "QFS" decompressor — the codec wrapping almost every resource.hog member. Standalone CLI + self-test.
tools/hog_pack.py Write / repack .HOG (BIGF) archives (byte-identical round-trip).
tools/dte_parse.py .DTE mission decoder (RefPack + 27-section directory + script disasm) + reference tables.
tools/shp_parse.py .SHP model decoder — chunk walk, typed dumps, structure tree, Wavefront OBJ export, validation sweep.

Editors

Path Description
tools/slstats.py Ship / weapon stat editor (the stat .BIN tables).
tools/slswitch.py Coalition ship-switcher (data-layer .shp swap in the HOG).
tools/slstudio_app.py Starlancer Studio — the all-in-one GUI (see above); fronts every tool.
tools/slstudio_core.py Studio's headless core — install scan, exe classification (stock / patched / SafeDisc loader, each with its evidence), patch state, shim and logo probes. Standard library only, no GUI toolkit, so it runs and is tested on every platform. scan <folder> [--json].
tools/slstudio.py Legacy 2-tab Tkinter GUI (stdlib-only fallback).

Modern-systems fixes (patch a local copy of your own exe / .HOG — never the original, never run)

Path Description
tools/sl_patch.py Modern-systems patch pack — one declarative code-cave engine applying any subset of the static EXE fixes (--widescreen WxH Hor+, --fix-medal, --fix-multicore) with a sidecar manifest and per-fix --verify / --revert / --revert-only. (--fps explains the cap; it's a vsync/wrapper matter, not an exe patch.)
tools/ws_patch.py Deprecated alias for sl_patch.py --widescreen — keeps the old --width/--height CLI working (byte-identical output).
tools/sl_emu.py Function-level emulator — executes ONE routine out of a local image copy inside a sandboxed CPU emulator and reports what it computes and every store it makes. Used to verify the widescreen fix by measurement. Never launches the game: no process, no window, no audio. Needs unicorn (optional). See docs/emulation-harness.md.
tools/blank_boot_videos.py Skip the startup logo movies: blanks the three loose logo .bik files in the game folder (WARTY_, NEW_DALOGO_FS_UNCMPR, NEW_NMS), keeping .orig backups; restore puts them back.
tools/xinput_shim/ XInput controller shim — a proxy dinput.dll (C, 32-bit) that forwards keyboard/mouse to real DirectInput and synthesizes the joystick from XInput (no-rumble v1). Its separate-trigger axes are inert: the game never reads them. Source + build.bat + test host.

Reverse-engineering & analysis

Path Description
tools/pe_inspect.py Read-only PE header / section / entropy / imports inspector.
tools/pe_icon.py Read-only PE app-icon extractor (rebuilds a .ico from RT_GROUP_ICON/RT_ICON; never executes the target).
tools/make_icon.py Generator for Starlancer Studio's original app icon (PIL primitives — no game art).
tools/bin_explore.py · tools/bin_diff.py Generic binary explore / diff helpers.
tools/map_engine.py Cluster decompiled functions into subsystems (builds the engine map).
tools/ghidra_headless.ps1 + tools/ghidra_scripts/ExportAll.java Headless Ghidra import / analyze / export automation.

Tests & guard

Path Description
tools/check_no_game_data.py Game-data guard (run by the pre-commit hook and CI).
tests/run_all.py Pre-PR / CI gate — hog + sl_patch self-tests + guard (no game files needed).
tests/hog_selftest.py Extractor self-test.
tests/sl_patch_selftest.py Patch-engine self-test (synthetic PE; apply / verify / revert / manifest / ordering).

Quick start

python tools/hog_extract.py path/to/resource.hog            # list contents
python tools/hog_extract.py path/to/resource.hog -o out/    # extract everything
python tools/slstats.py --help                              # ship/weapon stat editor
python tools/dte_parse.py ref exec                          # print the Executor command table
python tools/dte_parse.py decode mission1.dte               # decompress (RefPack) + decode a mission
python tools/sl_patch.py --fov-table                        # preview the Hor+ widescreen FOV per aspect
python tools/sl_patch.py --widescreen 1920x1080 in.exe out.exe      # patch a local exe copy
python tools/sl_emu.py compare stock.exe patched.exe        # MEASURE the fix (emulated, never launched)
python tools/slstudio_core.py scan "D:\Games\Starlancer"   # what state is this install in?
python tests/run_all.py                                     # run the full self-test gate

Status

The research continues; the kit is complete. New findings land in docs/ and the wiki. New code goes to OpenReliant (see Where to go). The original-game kit below is finished and receives bug fixes only.

Documented & tooled: the .HOG/BIGF archive format (extractor + packer), the ship/weapon stat tables (editor + GUI), the Coalition ship-switcher, and the .DTE mission format — the RefPack container is decoded end-to-end (dte_parse.py decodes all 44 missions: directory, ships, triggers, and the script bytecode) plus the full scripting opcode/command reference. A modern-Windows fix catalogue (docs/modern-fixes.md), fusing community fixes with our RE, ships with a boot-video-skip tool, native Hor+ widescreen, and the RE'd crash fixes (medal-case, multi-core) — all via the tools/sl_patch.py declarative patch-pack (per-fix verify / revert), and all wrapped together with the editors and the controller shim in the Starlancer Studio app. The .SHP ship-model format is now specified in docs/shp-format.md (independent static RE; decoder + OBJ export in tools/shp_parse.py); its remaining gaps are listed in that document's §9. The 100-FPS cap is settled rather than open — static RE showed it is the simulation timebase plus renderer vsync, not an exe limiter, so the uncap is a wrapper setting and this project ships no FPS patch by design.

Contributing

Engine work, fixes to the game and new modding tools belong in OpenReliant, under its own contributing guide. Here we welcome research: corrections, new format findings, and documentation, plus bug fixes to the original-game kit.

See CONTRIBUTING.md (dev setup, commit style, and how to submit) and our CODE_OF_CONDUCT.md. The one hard rule: never commit game data (binaries, assets, or decrypted/derivative game files); a .gitignore, a pre-commit guard, and a CI check (tools/check_no_game_data.py) enforce it. Run python tests/run_all.py before a PR. To report a guard bypass or other issue privately, see SECURITY.md.

AI transparency

This project is, by design, AI-assisted reverse engineering — essentially all of its code and documentation were written by Anthropic's Claude under human direction. See AI-TRANSPARENCY.md for the full implementation disclosure.

Credits

This project stands on the work of the Starlancer modding community. The file formats here were reverse-engineered independently (clean-room, statically); these are the people whose earlier tools and research we build on, with thanks:

  • DraconPern & KingLord — the .HOG / EA BIGF archive format (the SLExtract tool, with source released). Basis for hog_extract.py / hog_pack.py.
  • Captain Foster / Starlancer ME — .DTE mission opcode / trigger / ship-ID tables and observed in-game semantics — https://starlancerme.blogspot.com/ · @CaptainFoster. Fused into dte_parse.py and the .DTE docs.
  • "Userunfriendly" — the hexcheat known-delta stat pack that revealed the SHIP/GUN/MISSILESTATS.BIN field offsets — basis for slstats.py.
  • Dustin — SLEdit, whose data-layer Coalition ship-switch mechanic is reimplemented by slswitch.py.
  • Mario "HCl" Brito — SL Tool, LWO2SL, and the MilkShape .SHP import/export plugins — the prior art for the .SHP 3D-model format. Our own spec (docs/shp-format.md) was derived independently from the executable and the game files, without reference to those tools.
  • Raidersoft (StarLancEdit) and Twister / Twisted Media (Saved Game Editor) — the MYGAME*.IFF save and profile.bin formats (RE planned).
  • DMJC — StarLanceDecomp (independent RE notes on the same binary) and neoslancer (a C++/SDL2 Linux port). Their work prompted our RefPack archive-layer audit and corrected our identification of the mission gameplay loop; their .SPR, .FNT and DirectPlay coverage goes well beyond ours. No code from either repository is used here — see docs/external-re-credits.md for exactly what crossed over, what we verified, and why.
  • vdmkenny — OpenReliant, the engine reimplementation this project now contributes to. Its engine code corrected several of our .DTE readings (docs/dte-format.md §9b), and its source-file reconstruction places the executable's functions into the original source tree. See docs/external-re-credits.md §6.
  • esc0rtd3w — the blank-intro-videos project, whose black blank.bik the Studio build bundles as its boot-video placeholder when a copy is placed in tools/assets/ (the clip is not part of this repo; without it the Studio gives the logos a silent black frame of their own with blank_boot_videos.py). https://github.com/esc0rtd3w/blank-intro-videos/
  • The game content reference (docs/game-reference/) is compiled from the community Starlancer Wiki on Fandom under CC BY-SA 3.0 (those pages are offered under the same terms; the rest of docs/ is CC BY 4.0 and the code GPL-3.0-only — see License). With thanks to the Starlancer Wiki editors.

Many of these tools are preserved in the Starlancer-mod-tools mirror; each remains under its original author's terms (typically freeware).

License

Copyright (C) 2026 LordBlacksun.

Two licences, split by kind — because copyleft defends against enclosure, and enclosure is a real risk for tools but not for published file-format knowledge:

  • Code and tools — tools/, tests/, the build scripts, and everything else that is not documentation — are free software under the GNU General Public License v3.0 only, see LICENSE. You may use, modify and redistribute them under those terms; derivative works must also be released under the GPL, so improvements come back to the community.
  • Documentation under docs/ — the format specs, the engine map, the scripting reference, the fix recipes — is licensed CC BY 4.0 (Creative Commons Attribution 4.0 International). Any other project, whatever its own licence — MPL, MIT, CC BY-SA, proprietary, or none yet — may quote, adapt, translate and build on this research, with attribution. This is deliberate, and it is for the scene: the other Starlancer efforts could not legally reuse GPL-licensed prose, and share-alike on documentation bought no defence (a published fact cannot be enclosed) while blocking interoperability, so as of 2026-09-22 the documentation is share-alike-free. Attribute as "Starlancer-OSS documentation (LordBlacksun and contributors), CC BY 4.0" with a link to the repository or to the file you used.
  • One exception inside docs/: the game-content pages under docs/game-reference/ are compiled from the community Starlancer Wiki on Fandom and remain CC BY-SA 3.0, the same terms as their source — share-alike binds us there. With thanks to the Starlancer Wiki editors.

The game itself, its assets, and the names, strings and tables the documentation transcribes from its executable belong to their owners and are covered by neither licence.

About

The documentation commons for StarLancer (2000): file formats, engine RE and the scene map. To play or contribute code, see OpenReliant.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages