Files
Aidem-Media-DLL-Analysis/docs/world-analysis.md
T
Patryk GenschandClaude Opus 5.5 e03037647e data: extract 33 scene modules and the Wojna Trojańska engine (68 builds)
The DLL collection gains every WORLD/KOLOROWANKA variant, MATRIX, QMAN
(TEST), INERTIA and BOARD, plus the later PIKLIB72 build from Wojna
Trojańska, taken from the game discs. All 68 builds re-extracted; engine
snapshots are unchanged except the Piklib 6.1 switch dispatch. Roadmap,
batch results and docs follow.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-28 21:38:11 +01:00

4.2 KiB

WORLD: static script API registration

Analyzed /Users/genszu/Reksio/Reksio i Czarodzieje/World.dll with REA/Ghidra 12.1.2. SHA-256: 1f6649e93ddbd12be1865a06f15fbae5c62685dab0efb9072bdd2af1ccaca78f. Image base: 0x10000000. This report establishes static registration, not emulator functional equivalence.

Factory chain

  • Exported getModuleInterface at 0x1000f300 returns the module singleton stored at 0x1001d014.
  • CWorld::CWorld at 0x1000edf0 constructs a null-terminated implemented-types array containing WORLD; getImplementedTypes at 0x1000ef30 returns that array.
  • Exported CWorld::resolve at 0x1000f030 compares the element's TYPE to WORLD, allocates 0x110 bytes and calls object constructor 0x10001000.
  • The object constructor invokes CMC_Object with type number 0x2713, sets vtable 0x10011750, and creates an ISekai instance. Diagnostic string CMC_World::CMC_World( CMS_Scene ) supports the CMC_World label; the constructor itself is unnamed in Ghidra.

Evidence: ev_99c2269105b1ae67882e312fdaa8883edd2786feb40799d4ce33078482d42365, ev_501163338c92037a1f7d3cad8aa4d527cace6cdcdbe4b31040cf93bce51dc095, ev_c91a5c5303b818c464ee2728ff883d2d81e3d701148ba99fae16aa6817809295, ev_83d9284ab7ce107eb718d1e7c69518ce0f9f6e664a08a579bbb537b762b006d1.

Registration

FUN_10007710 contains 67 registration entries representing 66 distinct method names. Each recovered entry joins an immediate passed to CInteger::CInteger (0x1000f984), an ASCII method string constructed as CStringHashCode (0x1000f97e), and CHashtable::put (0x1000f978). The routine first calls imported CMC_Runner::prepareMthHashSet (0x1000f4b6), so inherited/global methods exist outside this DLL's own registration routine.

Every method's ID, string address, ID push address and registration call address are retained in ../snapshots/world.snapshot.json. Full decompilation and assembly are retained in ../snapshots/world.evidence.json, especially record ev_aacb5eb769bd5855ae079efed1447e911ec5d2b83f3e6b4086fa1776bf041d1b. REA's live response exceeded the transport budget; the complete retained record was exported and read locally instead of repeating analysis.

The binary really registers SETPOSITION twice: ID 24 at 0x1000834c, then ID 43 at 0x10009d4f, both referencing string 0x100125a0. RESUMELINK also receives ID 43 (0x10009c4f, string 0x1001246c). The snapshot preserves both SETPOSITION entries. The effective duplicate-key behavior of the imported hashtable, and the dispatcher meaning of ID 43, are unresolved; do not silently deduplicate this into a single verified method ID.

Emulator comparison

All 66 distinct names occur in WorldVariable.java's 72-entry method map. Six emulator names are not directly registered in this DLL: ADDGRAVITYEX, GETROTATIONX, GETROTATIONY, JOIN2, JOINTSPEED, JOINTSTEER. They may belong to other versions; this bounded comparison does not establish that they are incorrect or globally absent from the original engines.

Registration coverage says nothing about functional correctness, argument validation, units, side effects, or partial implementations. No behavioral review records were added.

Remaining work

  • Recover other World DLL variants and compare registration IDs and names.
  • Resolve SETPOSITION duplicate insertion and dispatcher targets.
  • Extract inherited/global methods from the matching engine; extract events and fields separately.
  • Review functional equivalence per method against dispatcher and Sekai implementations.

Default Ghidra string inventory initially omitted WORLD and script LOAD, although the bytes and code references were present. This demonstrates why empty search_strings results cannot prove absence. Factory exports and raw PE-backed strings resolved the gap. Session resources were closed successfully after evidence export.

Automatic extraction (2026-10-28)

The batch (ams.acquire.batch, the scene-module path of extract_engine_surface.py) now extracts every variant of this module. On this binary it yields the same 67 name/ID pairs as the REA analysis above, plus dispatch with signatures and per-type events and fields. In the tracker the batch result takes precedence over this snapshot.