# How to Set Up the Wand Enhancer Development Environment: Complete Windows Guide

> Set up the Wand Enhancer development environment on Windows with VS 2022, CMake, Node.js, and pnpm. Follow our guide to build the TypeScript web panel, C++ helper, and C# WPF app.

- Repository: [k1tbyte/Wand-Enhancer](https://github.com/k1tbyte/Wand-Enhancer)
- Tags: how-to-guide
- Published: 2026-07-13

---

**Setting up the Wand Enhancer development environment requires Windows with Visual Studio 2022, CMake, .NET Framework 4.8, Node.js 18+, and pnpm, followed by running the orchestrated build script that compiles the TypeScript web-panel, native C++ helper, and C# WPF application in the correct order.**

Wand Enhancer is a Windows-only WPF application that patches the Wand client by injecting a thin Electron-based remote panel. The project spans three distinct codebases—a TypeScript web-panel, a native C++ helper, and C# WPF logic—requiring a specific tool chain and build order to compile successfully. This guide walks you through the complete setup process using the official repository at `k1tbyte/Wand-Enhancer`.

## Prerequisites

Before cloning the repository, ensure your Windows workstation meets the following requirements.

### System Requirements

- **Operating System**: Windows 10 or 11 (64-bit)
- **Memory**: Minimum 4GB RAM recommended for parallel compilation
- **Disk Space**: Approximately 2GB for Visual Studio, Node modules, and build artifacts

### Development Tools

Install these tools in the following order:

1. **Visual Studio 2022** with the "Desktop development with C++" workload
2. **CMake** (download from https://cmake.org or install via Visual Studio Installer)
3. **.NET Framework 4.8 SDK** (included with Visual Studio 2022)
4. **Node.js** version 18 or higher
5. **pnpm** (preferred over npm): `npm install -g pnpm`

## Quick Start with Automated Build

The fastest way to configure your Wand Enhancer development environment is using the provided build script.

First, clone the repository:

```bash
git clone https://github.com/k1tbyte/Wand-Enhancer.git
cd Wand-Enhancer

```

Then execute the orchestrated build:

```bash
./build.cmd

```

Or via PowerShell:

```powershell
powershell -ExecutionPolicy Bypass -File build.ps1

```

The `build.cmd` script handles the critical build sequence automatically:
- Installs Node dependencies for the web-panel
- Compiles the TypeScript bridge and renderer scripts
- Builds the native C++ DLL using CMake
- Restores NuGet packages for the C# solution

- Compiles the WPF application with MSBuild

After completion, find the executable at `WandEnhancer/bin/Debug/net48/WandEnhancer.exe`.

## Manual Build Process

For granular control over the Wand Enhancer development environment, build each component separately following this strict order: **Web-Panel → Native Helper → C# Solution**.

### Build the Web Panel

The web-panel contains the Electron-based remote UI served at `http://127.0.0.1:3223` (configurable in [`web-panel/bridge/src/constants.ts`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/web-panel/bridge/src/constants.ts)).

```bash
cd web-panel
pnpm install
pnpm run build:bridge
pnpm run build

```

This produces `bridge.cjs`, renderer scripts, and bundles everything into `web-panel/dist/`. **Note**: This step must complete before compiling the C# solution because these assets are embedded into the final binary.

### Build the Native Helper

Compile the native fuse-bypass DLL located in `tools/asar-fuses-bypass/`:

```bash
cd ../tools/asar-fuses-bypass
mkdir build && cd build
cmake .. -G "Visual Studio 17 2022" -A x64
cmake --build . --config Release

```

This generates the native library used by [`AsarSharp/AsarExtractor.cs`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/AsarSharp/AsarExtractor.cs) to manipulate Wand's `app.asar` archives.

### Build the C# Solution

Finally, compile the WPF application and patching logic:

```bash
cd ../../WandEnhancer
dotnet restore
msbuild Wand-Enhancer.sln /p:Configuration=Debug

```

The [`WandEnhancer/Program.cs`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/WandEnhancer/Program.cs) entry point initializes the core UI, patch orchestration, and loads the Electron web panel from the previously built `app.asar` modifications.

## Project Architecture Overview

Understanding the three-tier architecture helps troubleshoot build issues in your Wand Enhancer development environment.

### WandEnhancer (C#)

Located in [`WandEnhancer/Program.cs`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/WandEnhancer/Program.cs), this component provides the core WPF UI, patch orchestration, user settings persistence, and the bridge that loads the Electron web panel into `app.asar`.

### AsarSharp (C#)

The [`AsarSharp/AsarExtractor.cs`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/AsarSharp/AsarExtractor.cs) library handles extraction, modification, and repacking of WeMod's `app.asar` archives. This utility is essential for the injection mechanism.

### Web-Panel (TypeScript)

Found in [`web-panel/bridge/src/constants.ts`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/web-panel/bridge/src/constants.ts), this small Electron bridge serves the remote UI, synchronizes installed games, tracks trainer status, and accepts remote commands. All runtime assets compile into `web-panel/dist/`.

## Configuration and Verification

Once built, verify your Wand Enhancer development environment by running the executable:

```bash
./WandEnhancer/bin/Debug/net48/WandEnhancer.exe

```

The remote panel should initialize on `http://127.0.0.1:3223` (or your configured host/port defined in [`web-panel/bridge/src/constants.ts`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/web-panel/bridge/src/constants.ts)). Check that the application can successfully patch the Wand client by monitoring the `AsarSharp` extraction logs in the debug console.

## Summary

Setting up the Wand Enhancer development environment involves coordinating three distinct build systems:

- Install **Visual Studio 2022**, **CMake**, **.NET Framework 4.8**, **Node.js 18+**, and **pnpm** on Windows
- Clone the `k1tbyte/Wand-Enhancer` repository
- Run `./build.cmd` for automated pipeline execution, or build manually in the order: Web-Panel → Native Helper → C# Solution

- Ensure the web-panel builds before the C# solution because TypeScript assets are bundled into the final executable

- Locate the output at `WandEnhancer/bin/Debug/net48/WandEnhancer.exe`

## Frequently Asked Questions

### What is the correct build order for Wand Enhancer components?

You must build the **web-panel first**, then the **native helper**, and finally the **C# solution**. The TypeScript bridge (`bridge.cjs`) and renderer scripts must be compiled into `web-panel/dist/` before running `MSBuild` on the WPF solution, as these assets are embedded into the final binary during the C# compilation phase.

### Can I use npm instead of pnpm for the web-panel?

While the documentation specifies **pnpm** as the preferred package manager, npm will work if you adjust the commands accordingly. However, the `build.cmd` script expects pnpm, so manual builds are required if you substitute npm. Ensure you use Node.js version 18 or higher regardless of the package manager.

### Where is the native helper DLL used in the application?

The native helper, built from [`tools/asar-fuses-bypass/CMakeLists.txt`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/tools/asar-fuses-bypass/CMakeLists.txt), produces a DLL consumed by [`AsarSharp/AsarExtractor.cs`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/AsarSharp/AsarExtractor.cs). This library handles low-level file system operations required to bypass Electron fuses and modify the Wand client's `app.asar` archive without corruption.

### How do I change the remote panel's host or port?

Modify the configuration in [`web-panel/bridge/src/constants.ts`](https://github.com/k1tbyte/Wand-Enhancer/blob/main/web-panel/bridge/src/constants.ts), which defines IPC channels, WebSocket opcodes, and the default host (`127.0.0.1`) and port (`3223`). After editing, rebuild the web-panel and the C# solution to embed the new defaults into the executable.