Skip to main content
This page tracks the current parity state of the Python + raylib rewrite against the original Windows build (Crimsonland v1.9.93). Last reviewed: 2026-02-24

What Works Today

Full gameplay — All modes playable (Survival, Rush, Quests, Tutorial, Typ-o-Shooter)
Complete content — All weapons, perks, creatures, and quests
Deterministic simulation — Seeded runs and replay verification
Multiplayer — Local 2-4 players + online rollback netcode
Bug fixes — 17+ original bugs fixed (re-enable with --preserve-bugs)

Parity Verification Methods

The project uses multiple strategies to verify behavioral parity:

1. Static Analysis

Source of truth for structure and behavior:
  • Name/type maps in analysis/ghidra/maps/
  • Raw decompiles in analysis/ghidra/raw/
  • Function signatures and struct layouts
High-level IL for complex expressions:
  • Float precision detection (fconvert.t, fconvert.s)
  • Control flow patterns
  • Cross-references

2. Runtime Evidence

Live instrumentation of original exe:
  • State snapshots at specific ticks
  • RNG traces
  • Function call traces
  • Memory dumps
Evidence: analysis/frida/
Interactive debugging:
  • Breakpoint analysis
  • Memory inspection
  • Register state
Logs: analysis/windbg/

3. Differential Testing

Field-by-field state comparison:
# Capture original
uv run scripts/frida/gameplay_diff_capture_host.py

# Record rewrite
uv run crimson dbg record replay.crd --impl python

# Compare
uv run crimson dbg diff original.cdt rewrite.cdt
Format: .cdt (Crimson Differential Trace)
Snapshot-based verification:
uv run crimson replay verify-checkpoints replay.crd
Compares:
  • Command hash (presentation)
  • State hash (simulation)
  • Per-field details

4. Fixture Tests

Known-good outputs from original:
def test_ground_renderer_parity():
    # Compare terrain output pixel-by-pixel
    expected = load_fixture("terrain_0_0_0.bin")
    actual = render_terrain(terrain_id=0, scroll_u=0, scroll_v=0)
    assert actual == expected
See: tests/test_ground_dump_fixtures.py

Coverage Status

Front-End (Menus)

FeatureStatusNotes
Main menu✅ CompleteLayout, animations, terrain
Play Game panel✅ CompleteMode select, player count
Quest select✅ CompleteAll tiers, hardcore toggle
Options panel⚠️ PartialSliders + controls; no display mode editing
Statistics hub✅ CompleteHigh scores, databases, credits
Demo/attract✅ CompleteVariant sequencing, upsell
Mods menu🚫 Out of scopeUI only, no DLL loading

Gameplay Modes

ModeStatusNotes
Survival✅ CompleteEndless waves, XP/perks
Rush✅ CompleteTimed scoring
Quests (1-5)✅ CompleteAll tiers, spawn scripts
Tutorial✅ CompleteStage progression, hints
Typ-o-Shooter✅ CompleteTyping mechanics

Core Systems

SystemStatusParity Validation
Player movement✅ CompleteDifferential captures
Weapon firing✅ CompleteShot counts match
Reload system✅ CompleteTimer precision verified
Creature AI⚠️ HighEdge cases in progress
Projectiles✅ CompleteHit detection matches
Collision✅ CompleteRadius checks verified
Bonus system✅ CompleteDrop rates match
Perk system✅ CompleteEffects verified
Progression✅ CompleteXP/level thresholds
Terrain✅ CompletePixel-perfect fixtures

Multiplayer

FeatureStatusNotes
Local 2-4 player✅ CompleteInput frame normalization
Rollback netcode✅ CompleteProtocol v5 with resync
Lockstep fallback✅ CompleteLAN compatibility
Relay server✅ CompleteRoom codes, NAT traversal

Assets & Rendering

FeatureStatusNotes
PAQ loading✅ CompleteArchive reader
JAZ decoder✅ CompleteTexture format
Terrain render✅ CompleteFixture-verified
Sprite render✅ CompleteAtlas-based
Decal baking✅ CompleteFX queues
HUD overlay✅ CompleteLayout matches

Audio

FeatureStatusNotes
Music playback✅ CompleteTheme + 5 game tunes
SFX system✅ CompleteVariant selection
Audio routing✅ CompleteEvent-based
Volume control✅ CompleteFrom crimson.cfg
Reflex Boost pitch✅ CompleteTime-scaled SFX

Persistence

FeatureStatusNotes
crimson.cfg✅ CompleteConfig persistence
game.cfg⚠️ HighCore fields verified
High scores✅ CompletePer-mode tables
Replays (.crd)✅ CompleteRecording + verification

Known Gaps

1. Options Panel Display Settings

In-game options do not currently edit:
  • screen_width / screen_height
  • windowed_flag
  • screen_bpp
  • texture_scale
These are managed via crimson.cfg and CLI, not the state-2 panel.

2. Deep Creature AI Edge Cases

Most creature behaviors match. Remaining gaps are specific edge cases being validated via differential captures.

3. Rollback Stress Testing

Rollback is primary netcode, but extreme packet impairment scenarios need broader coverage:
  • Loss/reorder/jitter extremes
  • Long session stability
  • Reconnect/resync under stress

Out of Scope

These features are intentionally not implemented:
The Python rewrite does not support loading/executing original DLL mods.Rationale: Not practical in Python architecture.
Shareware ad flows are not part of the parity target.Rationale: Out of scope for game preservation.
Local high scores are supported, but not original online submission.Direction: Use headless verification for score legitimacy instead.

Differential Session Tracking

Active parity probes and per-capture outcomes are tracked in:
  • docs/frida/differential-sessions.md — Session index
  • docs/frida/differential-sessions/session-*.md — Per-session details
Recent sessions focus on:
  • Float32 spill points in creature movement
  • Tau-boundary angle handling
  • Per-weapon projectile behavior

Verification Commands

# Run test suite (200+ tests)
uv run pytest

# Verify replay
uv run crimson replay verify replay.crd

# Check replay with checkpoints
uv run crimson replay verify-checkpoints replay.crd

# Differential trace comparison
uv run crimson dbg diff expected.cdt actual.cdt

# Bisect divergence point
uv run crimson dbg bisect expected.cdt actual.cdt

Next Steps

Float32 Policy

Why float precision matters

Original Bugs

Bugs fixed in rewrite

Deterministic Pipeline

How parity is enforced

Replay Module

Verification tools

Build docs developers (and LLMs) love