# The Tekken browser core

The hosted stable and nightly EmulatorJS MAME 2003-Plus cores tested on 23 October 2026 predate the Namco System 11/12 backport. They report “Game driver not found” for these sets. This project therefore builds a small, single-threaded Namco System 12 core from current upstream source. It runs the original arcade games, rather than substituting a PS1 edition.

Sources used:

- MAME 2003-Plus: https://github.com/libretro/mame2003-plus-libretro/tree/db6bffdae0bf1cfdcfe4593594a79fb0c4377a7b
- EmulatorJS RetroArch frontend: https://github.com/EmulatorJS/RetroArch/tree/97f2cfa65d01d57406e4ce9459242c8ada7c7e3b
- Emscripten SDK 3.1.74 from https://github.com/emscripten-core/emsdk
- Browser frontend from the official EmulatorJS CDN. The custom compiled core is served by this site.

The corresponding source ZIP contains the complete tracked sources for both emulator repositories, with the actual modifications applied, all upstream license files, this explanation, and the rebuild scripts. It excludes game data, build products, `.git`, SDK binaries and private paths. The original MAME non-commercial license and the RetroArch GPLv3 license remain applicable to their respective components; the MIT license for the custom web page/launcher does not replace them.

The target includes the PSX CPU, H8 CPU and C352/SPU support required by Namco System 12, and the Tekken 3 / Tekken Tag parents and the two selected clones. Other arcade drivers, CPU models and game-specific hardware are removed from this target. `SPLIT_CORE` excludes unrelated BIOS resources. The unused Neo Geo memory-card menu is disabled; MAME state saving is separate. No ROM bytes or game logic have been rewritten.

To rebuild, extract `namco-browser-source.zip`, install Git, Python 3, a C/C++ build environment and Make, then run inside its `namco-browser-source/` directory:

```sh
bash build_namco_core.sh "$PWD" "$PWD/output"
```

The script installs the official Emscripten SDK inside that extracted source folder and builds a single-threaded WebAssembly runtime. It does not require browser cross-origin isolation or an installed MAME application. A 64-bit desktop development machine is recommended for compilation. The build was performed on Apple Silicon; play runs as WebAssembly in the visitor’s browser across supported operating systems. Performance and memory limits depend on the browser and device.

Copy `output/namco-v1.data` and `output/namco-v1.json`, the corresponding source ZIP, and `SOURCE-AND-LICENSES.md` into this repository’s ignored `browser-runtime/` folder before running `tools/build_campaigns.py`. Private local game inputs are supplied separately; `campaigns/browser-arcade-map.json` maps source file CRCs to the names expected by this core.
