Skip to content
N0zoM1z0Public

Repository files navigation

東方花映塚 ~ Phantasmagoria of Flower View

Original Japanese TH09 1.50a title screen

TH09 reconstruction progress

This project reconstructs the original Japanese TH09 version 1.50a executable. It starts from an independently versioned, hash-attested target and tracks boundary, origin, source presence, codegen exactness, native-product closure, runtime semantics, and portability as separate facts.

Exact target

Place your own legal copy at the ignored canonical path resources/th09.exe. Repository tools use that path by default. An explicit path or TH09_TARGET_PATH is supported only for deliberate local overrides; normal Factory work must use the canonical path.

Property Required value
Version original Japanese 1.50a
Size 685,056 bytes
SHA-256 10350095bcf95edb59e03bee9849a2dc8a7714b4927ad5909c569c550fce6822
MD5 cf634df46e05552e104fa97a971aaac0
Image base 0x00400000
Entry point 0x0047D45F

The pinned thcrap version database classifies this exact SHA-256 and size as th09, v1.50a, (original) and lists the English-patched executable under a different digest. The official 1.50a release post is dated 2005-10-08 JST, consistent with the target's PE timestamp.

python3 scripts/verify-target.py
python3 scripts/validate-tracking.py --require-target
python3 scripts/report-reconstruction-status.py

IDA attestation is environment-specific: local Codex calls get_metadata with {} through the direct provider and runs scripts/check-ida-mcp.py for mapped-byte attestation, while Factory/Web must call get_metadata with {} through the attested th09-ida provider. See AGENTS.md and docs/TOOLS.md before analysis.

Original executables, game data, IDA databases, decompiler output, and downloaded tools are private and never committed.

Current status

The current operator targets 95% exact reviewed-authored code bytes, with both large functions (especially RunEcl, Enemy/Etama, TitleScreen and ExAttack) and small leaves in scope. Factory/Web and local Codex use their respective attested IDA routes and the pinned VC7.1 compiler Oracles. The ledger-derived counts are in docs/PROGRESS.md; the replace-in-place docs/RE_HANDOFF.md is the live routing and restart guide. Historical experiments in the knowledge base are not current codegen status. This measures confirmed authored bytes, not whole-image or runnable-product coverage.

Every new session must attest the target and live IDA database. Current exact/non-exact state comes from config/functions.csv, config/matches.csv, config/match-units.toml, and a fresh status report. docs/KNOWLEDGE_BASE.md indexes durable evidence and bounded investigation notes; historical measurements do not replace the live ledgers.

The PE and Rich header identify Microsoft Visual C++ .NET 2003 build 3077. Some runtime-library contributions and compiler-generated helpers are proven, but the complete translation-unit graph, resources, data owners, compiler profiles, and link order remain open. config/build.toml records that state instead of pretending the project is buildable.

Run python3 scripts/progress.py to regenerate the status card, python3 scripts/validate-docs.py to catch stale handoff totals, percentage, 95% gap, non-exact routing and accepted-owner manifest/receipt entries, and python3 scripts/ci.py for the target-independent validation set. The ignored build/ directory is deliberately cleared before handoff; replay a function by running python3 scripts/build-match-unit.py --unit NAME before its corresponding comparison or non-crediting inspector. Preview disposable-cache cleanup with python3 scripts/clean-generated-artifacts.py and explicitly apply it using --apply; original game data and historical probe source are not cleanup targets.

Required phase order

  1. Preserve the reviewed boundary/origin inventory and recover remaining exact VC7.1 authored units.
  2. Close and exercise the faithful Windows i386 product, including static data ownership, initializers, resources, libraries, and runtime scenarios.
  3. Perform semantic reconstruction with two independent runtime Oracles: the original target and the reconstructed native i386 product.
  4. Start a portability branch only after the native semantic baseline is trustworthy.

Exact functions do not imply a complete or runnable product. A modern port can hide missing original data owners, ABI behavior, and initialization, so it is not an acceptable shortcut around the native-product stage.

Project map

License

Repository-authored code and documentation are provided under the MIT License. This does not grant rights to the original game or its assets.

Releases

Packages

Contributors

Languages