Files
kdm-re/docs/companion-inventory.md
T
ulw-execute a176c63736 docs: scope spec + RE to the official clean release only
Reference only the official KDM-2016021900 game: the 9 Konami modules in
contents/modules/ plus data/arkdata/prop. Remove community/PC-hardware glue
(deahook/DEALibacio, spice2x/spicetools, launcher.exe, gamestart.bat,
bemanitools, NVENC/CUDA stubs) and non-release modules (kmd/ksm/kuc/libinput/
libacio_mbr) as game evidence. Correct the "22-DLL" framing to the real
9-module set; reframe the boot chain on arkkdm.dll's own dll_entry_init/
dll_entry_main -> gameMain binding. Kinect10.dll referenced only as gamekdm's
external Microsoft NUI runtime dependency. Fix ea3-config.xml -> eamuse-config.xml.
Per-byte sizes/RVAs from the earlier contaminated install marked UNVERIFIED
pending re-check against the clean-release binary.
2026-11-28 20:37:18 -05:00

7.3 KiB

Module Inventory — KDM-2016021900 (clean release)

Inventory and classification of every module shipped in the clean KDM-2016021900 release, plus the cross-module dependency DAG and the reconstruction set and order. Scope is the official game only: the contents/ tree of the release. Community/PC-hardware tooling (spice2x, bemanitools, a Kinect shim, launcher/hook glue, NVENC/CUDA stubs) is not part of the game and is not inventoried here; where an earlier draft counted such files as "shipped DLLs," that was a contaminated install, not the clean release.

What the clean release contains

The clean release is contents/ with three asset/config trees — data/, arkdata/, prop/ — and exactly 9 modules under contents/modules/. There are no other DLLs: no launcher.exe, no deahook.dll, no Kinect10.dll, no stubs/64/, no src/ tarballs, and none of the non-release Konami modules (kmd.dll, ksm.dll, kuc.dll, libinput.dll, libacio_mbr.dll) a contaminated install may carry.

Per-module table (contents/modules/)

Module Size (clean release) Classification Role
libavs-win32.dll 505.14 KB IN-SCOPE AVS2 (Application/Audio-Visual System v2) core middleware: property-tree config store, virtual filesystem, threading. Root of the dependency graph.
libavs-win32-ea3.dll 364.14 KB IN-SCOPE e-amusement v3 ("ea3") AVS2 extension (network/identity/coin economy).
libafp-win32.dll 1.19 MB IN-SCOPE AFP asset/font/graphics (Flash) pipeline used by ARK.
libafputils-win32.dll 165.64 KB IN-SCOPE AFP utilities; sits directly above libafp-win32.dll.
ess.dll 376.14 KB IN-SCOPE ESS e-amusement shop/server middleware.
libacio.dll 224.64 KB IN-SCOPE ACIO (amusement cabinet I/O) protocol library.
arkkdm.dll 896.64 KB IN-SCOPE ARK cabinet game engine instantiated for KDM; also the AVS2 game-DLL entry (dll_entry_init/dll_entry_main) that loads and calls gamekdm.dll.
arkkdmtest.dll 389.14 KB IN-SCOPE ARK/KDM render+input test harness; exports gameMain; links OS D3D9/DINPUT8/DSOUND directly (no AVS layer).
gamekdm.dll 3.19 MB IN-SCOPE Main KDM game logic; single export gameMain. Primary reconstruction target.

Size caveat. These sizes are from the clean-release file listing. An earlier inventory, built from a contaminated install, recorded different byte counts for arkkdm.dll, libacio.dll, and gamekdm.dll (e.g. libacio.dll at 65,536 B — a community replacement, not Konami's 224.64 KB original). Any per-byte size, export count, or RVA in this spec that was derived from that install and cannot yet be re-verified against the clean-release binary is marked UNVERIFIED (pending re-check against clean-release binary).

External (non-shipped) dependencies — referenced only, never part of the game

  • Kinect10.dll — Microsoft Kinect-for-Windows NUI v1 runtime. gamekdm.dll's own import table references it, so it is a real external dependency of the game binary, but it is not a shipped game module; on a cabinet it is satisfied by the installed Kinect runtime. Treat it as an external import target only.
  • OS / DirectX runtime — d3d9.dll, d3dx9_43.dll, KERNEL32.dll, USER32.dll, GDI32.dll, ADVAPI32.dll, SHELL32.dll, OLE32.dll, OLEAUT32.dll, WS2_32.dll, WINMM.dll, IMM32.dll, DINPUT8.dll, DSOUND.dll, IPHLPAPI.DLL, PSAPI.DLL, HID.DLL, SETUPAPI.dll, DBGHELP.dll, msvcrt.dll/MSVCR80.dll. Not shipped as game files; appear only as import targets, satisfied by the Win32/DirectX runtime.

Cross-module dependency DAG (9 nodes, verified acyclic)

Derived from each module's PE import table, restricted to edges where the imported DLL is another shipped module. The external Kinect10/OS imports are excluded from the graph.

graph TD
  libavs_win32_dll["libavs-win32.dll"]
  libavs_win32_ea3_dll["libavs-win32-ea3.dll"]
  libafp_win32_dll["libafp-win32.dll"]
  libafputils_win32_dll["libafputils-win32.dll"]
  ess_dll["ess.dll"]
  libacio_dll["libacio.dll"]
  arkkdm_dll["arkkdm.dll"]
  arkkdmtest_dll["arkkdmtest.dll"]
  gamekdm_dll["gamekdm.dll"]
  kinect(("Kinect10.dll (external MS NUI runtime)"))
  libavs_win32_ea3_dll --> libavs_win32_dll
  libafp_win32_dll --> libavs_win32_dll
  libafputils_win32_dll --> libavs_win32_dll
  libafputils_win32_dll --> libafp_win32_dll
  ess_dll --> libavs_win32_dll
  ess_dll --> libavs_win32_ea3_dll
  arkkdm_dll --> libavs_win32_dll
  arkkdm_dll --> libavs_win32_ea3_dll
  arkkdm_dll --> ess_dll
  arkkdm_dll --> libacio_dll
  arkkdm_dll --> libafp_win32_dll
  gamekdm_dll --> libavs_win32_dll
  gamekdm_dll --> libafp_win32_dll
  gamekdm_dll --> libafputils_win32_dll
  gamekdm_dll -.external.-> kinect

Text form (child → shipped dependency):

libavs-win32.dll        (root)
libacio.dll             (root; imports USER32/KERNEL32 only)
arkkdmtest.dll          (root; imports OS D3D9/DINPUT8/DSOUND/GDI32/SHELL32/USER32 only)
libavs-win32-ea3.dll  -> libavs-win32.dll
libafp-win32.dll      -> libavs-win32.dll
libafputils-win32.dll -> libavs-win32.dll, libafp-win32.dll
ess.dll               -> libavs-win32.dll, libavs-win32-ea3.dll
arkkdm.dll            -> libavs-win32.dll, libavs-win32-ea3.dll, ess.dll, libacio.dll, libafp-win32.dll
gamekdm.dll           -> libavs-win32.dll, libafp-win32.dll, libafputils-win32.dll
                         (+ external Kinect10.dll, d3d9/d3dx9)

libavs-win32.dll is the base of the graph (zero shipped dependencies, transitive ancestor of every other module). gamekdm.dll is the terminal game-logic node. All byte-exact export counts and edges beyond this shipped-module topology are UNVERIFIED (pending re-check against clean-release binary) until re-derived from the clean contents/modules/ files.

Boot/entry into the game (official, from arkkdm.dll)

On the cabinet the AVS2 runtime enters the game DLL (arkkdm.dll) through its standard AVS2 entry exports dll_entry_init / dll_entry_main (by-name exports at the tail of arkkdm.dll's export directory, ordinals 253/254, RVAs 0x767c0 / 0x767b0). arkkdm.dll's dll_entry_main internally LoadLibraryA("gamekdm.dll") — with an "arkkdmtest.dll" test-build fallback — then GetProcAddress("gameMain"), and calls gameMain(hInstance) (cdecl). The hInstance is arkkdm.dll's own HINSTANCE, captured once in its DllMain on DLL_PROCESS_ATTACH and relayed through its internal g_MainDllInfo.dllHMODULE struct (see docs/re/gamemain-binding.md). No launcher, hook DLL, or emulator is part of this path.

IN-SCOPE reconstruct set (9 modules)

All 9 shipped modules are Konami-authored and in scope:

libavs-win32.dll, libavs-win32-ea3.dll, libafp-win32.dll, libafputils-win32.dll, ess.dll, libacio.dll, arkkdm.dll, arkkdmtest.dll, gamekdm.dll.

Reconstruction order (topological, acyclic)

  1. libavs-win32.dll — AVS2 base (no shipped dependencies)
  2. libavs-win32-ea3.dll — AVS2 ea3 extension
  3. ess.dll — depends on AVS2 + ea3
  4. libacio.dll — root (OS imports only)
  5. libafp-win32.dll — depends on AVS2
  6. libafputils-win32.dll — depends on AVS2 + libafp
  7. arkkdm.dll — depends on AVS2/ea3/ess/libacio/libafp
  8. arkkdmtest.dll — root (OS imports only)
  9. gamekdm.dll — primary target; depends on AVS2/libafp/libafputils (+ external Kinect10.dll)