M2O Scripting APIScripting reference
MafiaHub scripting

M2O Scripting API

Build multiplayer game modes for Mafia II with the M2O JavaScript runtime.

Generated from runtime bindingsJavaScript API2 environments
01 / SERVER

Server API

Authoritative Node.js APIs for game modes, players, vehicles, world state, and replicated entities.

Browse reference  →
02 / CLIENT

Client API

Sandboxed V8 APIs for local presentation, controls, camera queries, and entity transforms.

Browse reference  →
AuthoritativeDocumentation is captured where the native runtime installs each binding.
Environment-awareClient and server contracts stay separate so availability is always explicit.
Editor-readyThe generated declarations can also power autocomplete and type checking.