MulNX is a modular observation and production platform for CS2. It runs as a DLL injection, implemented in modern C++, integrating technologies from reverse engineering, graphics, real‑time systems, network communication, and more. This document is intended for developers or advanced users and briefly describes its working principles, architecture, and build process.
- UI‑driven production: Fully visual operation interface
- Lightweight and portable: Small archive size, supports green installation and uninstallation
- Four‑level workflow: Workspace (match) → Project (map) → Solution (composition) → Element (track), with reusable resources
- Extended hotkeys: Supports Ctrl/Shift/Alt + letter / F‑key combinations, 1–255 consecutive presses, and free key binding
- Real‑time preview: Parameter and track effects are instantly visible
- Automation: Built‑in game state analysis, supporting event‑triggered automatic playback of solutions
- Intelligent disk I/O: Efficient resource management
- CFG management: Move, load, identify, and delete configuration files between the tool directory and the game directory
- Network remote control: WebSocket connection to localhost:55202, providing an API with JS/Python examples included
- Custom hook engine: Based on MulNXHook, with a built‑in disassembly engine, supports hooking at any instruction, access to all registers, lambda callbacks, and RAII management
- Reverse engineering
- Modern C++ (C++20/23)
- Graphics and 3D mathematics
- Win32 development
- Modern software architecture
- Real‑time systems
- Multithreading
- CMake build system and CI
- Automation systems
- UI development (ImGui)
- Network programming
- Assembly (x64)
- And more
- The launcher injects a helper DLL into the CS2 process via a remote thread.
- After injection, the helper DLL loads dependency DLLs and the main DLL, then performs system initialization, creating:
- A key detection thread
- A message bus thread
- A CS2 interaction thread
- At runtime, the framework drives the collaboration of various modules, with the message bus ensuring thread‑safe communication.
- When the game exits, the operating system automatically reclaims resources (no explicit shutdown procedure).
| File | Role |
|---|---|
CS2Injector.exe |
Launcher: starts the game (with -insecure and other parameters) and injects the DLL |
CS2InternalHelper |
Bootstrap loader: injected by the launcher; its initialization function is called by the remote thread to load dependency DLLs, and finally loads and initializes the main DLL |
CS2OBTool.dll |
Core module: contains the UI, camera system, game interaction, automation, etc. |
| Module | Responsibility |
|---|---|
| Core | Lightweight core |
| HookManager | Controls the lowest‑level module for Win32 and D3D11 interface hooks |
| CSController | Controls the lowest‑level module for interacting with CS2’s various DLLs |
| CameraSystem | Camera movement resource management and playback |
| MessageManager | Inter‑module message bus |
| VirtualUser | Event triggering and automation |
| InputSystem | Hotkey detection and movement assistance |
| Debugger | Debugging assistance |
| MiniMap | Real‑time minimap |
| GlobalVars | Global state and configuration |
| WebSocketManager | External API gateway and message forwarding |
- The user double‑clicks
CS2Injector.exeand waits for the "Launch CS2" button to be pressed. - If
cs2.exeis already running, the injector refuses to start again. - Otherwise, it starts CS2 with parameters like
-insecure(disabling VAC), then injects the DLL.
- Reference:
CS2OBTool/DllMain/DllMain.cpp:- The system uses a modular architecture; most components are equal‑level modules.
CreateSystemModules()is called immediately after(*Core->ModuleManager()).- Modules are registered via a fluent interface (inherit from the module base class, implement functionality, register with the manager).
- The core launcher performs initialization, creating necessary threads and hooks.
- Dependency injection: makes system services accessible to components.
- Each module starts and enters its running state.
- The framework drives all modules to run, and the message manager handles inter‑module communication, ensuring thread safety.
- The module manager calls the
Deinitfunctions of all modules in reverse order, then destructs the modules in reverse order.
- Minimum build difficulty
- Fully UTF‑8 encoded (CMake has been configured)
- Windows 11 (recommended)
- Network: If GitHub access is difficult, you can use Watt Toolkit (Microsoft Store) to accelerate GitHub
- Platform: x64, with UTF‑8 support enabled
- Build tool: Microsoft Visual Studio 2026 or later
- IDE choices:
- Beginners are strongly recommended to use Visual Studio 2026 (minimal configuration required)
- Advanced users can choose VS Code (requires manual configuration of CMake, C++ plugins, etc.)
⚠️ Beginners: please use Visual Studio 2026 directly!
- Workload: Desktop development with C++ (automatically includes CMake support)
- Optional: Python‑related workloads (only for auxiliary packaging/statistics, not required)
- Individual component: Windows SDK (latest)
Windows SDK already includes Direct3D 11, DirectXMath, etc.
- CMake
- C/C++ plugin
- Debugging tools
- Git integration
- Beautification plugins (optional: Background Cover, Better Comments, CodeSnap, Custom UI Style, VSCode Animations)
- Method 1: Download ZIP → extract, keeping the directory structure unchanged
- Method 2:
git clone
- Must maintain the exact same relative directory structure as the repository.
- Do not move/rename/delete necessary folders.
- Open the project root directory with Visual Studio 2026 (or right‑click → “Open with Visual Studio”).
- If using VS Code: File → Open Folder → select the root directory.
- CMake should be automatically detected. If prompted to select a compiler or the root CMakeLists.txt, follow the instructions.
- Select the build configuration (Debug / Release, etc.).
- Execute the build (Ctrl+Shift+B or the menu “Build”).
The build almost never fails.
- All Python scripts are optional and used only for auxiliary packaging.
- Generated files are located in the root
bin/directory:bin/MulNX/: direct output artifactsbin/output/: files merged and filtered after runningpack.pybin/MulNX.zip: the auto‑packaged archive after runningpack.py
calculatelines.pyis used only to count non‑third‑party lines of code; it is not required.
This document is only a brief introduction. For detailed implementation, please refer to the source code.