Table of Contents

Information

Resources

Crowdfunding

Prerequisites

Dependencies

Visual Studio 2022

Required Components

"%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\setup.exe"

LLVM

Boost

CMake

windows-x86_64.msi

OpenSSL

Download Source

"%ProgramFiles%\Git\bin\git.exe" clone --branch "master" --depth "1" --recurse-submodules "https://github.com/TrinityCore/TrinityCore.git" "%UserProfile%\Projects\TC-master\src"

Databases

Settings

RMDIR /S /Q "%UserProfile%\Projects\TC-master\mariadb\database" & MKDIR "%UserProfile%\Projects\TC-master\mariadb\database" & "notepad.exe" "%UserProfile%\Projects\TC-master\mariadb\custom.cnf"
[client]
default-character-set = 'utf8mb4'

[mariadb-client]
default-character-set = 'utf8mb4'

[mariadbd]
character-set-client-handshake = 'FALSE'
character-set-server = 'utf8mb4'
collation-server = 'utf8mb4_unicode_ci'
init-connect='SET NAMES utf8mb4'
expire_logs_days = '7'
max_binlog_size = '100M'
skip-networking = 'On'
table_definition_cache = '1400'

# End

Initialize

"%ProgramFiles%\MariaDB 12.2\bin\mariadb-install-db.exe" --skip-networking --datadir="%UserProfile%\Projects\TC-master\mariadb\database" --config="%UserProfile%\Projects\TC-master\mariadb\custom.cnf"

Connect

"%ProgramFiles%\MariaDB 12.2\bin\mariadbd.exe" --defaults-file="%UserProfile%\Projects\TC-master\mariadb\database\my.ini" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock"
"%ProgramFiles%\MariaDB 12.2\bin\mariadb.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock"

Databases

CREATE DATABASE authserver;
CREATE DATABASE characters;
CREATE DATABASE worldserver;

Users

CREATE USER 'authserver'@'localhost' IDENTIFIED BY 'x';
CREATE USER 'characters'@'localhost' IDENTIFIED BY 'x';
CREATE USER 'worldserver'@'localhost' IDENTIFIED BY 'x';

Permissions

GRANT ALL PRIVILEGES ON authserver.* to 'authserver'@'localhost';
GRANT ALL PRIVILEGES ON characters.* to 'characters'@'localhost';
GRANT ALL PRIVILEGES ON worldserver.* to 'worldserver'@'localhost';
FLUSH PRIVILEGES;EXIT;

Initial Compile

CMake

DIR /B "%ProgramFiles%\LLVM\lib\clang"
SET "LLVMInstallDir=%ProgramFiles%\LLVM"
SET "LLVMToolsVersion=22"
"%ProgramFiles%\CMake\bin\cmake.exe" -S "%UserProfile%\Projects\TC-master\src" -B "%UserProfile%\Projects\TC-master\build" -G "Visual Studio 17 2022" --fresh -Wno-dev -DBOOST_ROOT="%SystemDrive%/local/boost_1_90_0" -DMYSQL_INCLUDE_DIR="%ProgramFiles%\MariaDB 12.2\include\mysql" -DMYSQL_LIBRARY="%ProgramFiles%\MariaDB 12.2\lib\libmariadb.lib" -DWITHOUT_METRICS="1" -DTOOLS="1" -T "ClangCL" -DBoost_COMPILER="-vc143" -DCMAKE_CXX_FLAGS="/EHs /arch:AVX2 /favor:INTEL64 /Gz /Oy /GS- /guard:cf- /W0 -Wno-everything"

MSVC

"%ProgramFiles%\CMake\bin\cmake.exe" -S "%UserProfile%\Projects\TC-master\src" -B "%UserProfile%\Projects\TC-master\build" -G "Visual Studio 17 2022" --fresh -Wno-dev -DBOOST_ROOT="%SystemDrive%/local/boost_1_90_0" -DMYSQL_INCLUDE_DIR="%ProgramFiles%\MariaDB 12.2\include\mysql" -DMYSQL_LIBRARY="%ProgramFiles%\MariaDB 12.2\lib\libmariadb.lib" -DWITHOUT_METRICS="1" -DTOOLS="1"

CXX_FLAGS Info

Compile

SET "MSBUILDDISABLENODEREUSE=1" && "%ProgramFiles%\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\MSBuild.exe" "%UserProfile%\Projects\TC-master\build\ALL_BUILD.vcxproj" -target:"Rebuild" -property:"Configuration=Release" -maxCpuCount && SET "MSBUILDDISABLENODEREUSE="
SET "LLVMInstallDir="
SET "LLVMToolsVersion="
TASKKILL /IM "MSBuild.exe" /T /F

Test Compile

"%ProgramFiles%\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\MSBuild.exe" "%UserProfile%\Projects\TC-master\build\ALL_BUILD.vcxproj" -target:"Build" -property:"Configuration=Release" -maxCpuCount -nodeReuse:"False" -verbosity:"quiet" -noConsoleLogger -terminalLogger:"off" -binaryLogger:"output.binlog;ProjectImports=None"

DLLs

COPY /Y "%ProgramFiles%\MariaDB 12.2\lib\libmariadb.dll" "%UserProfile%\Projects\TC-master\build\bin\Release"
COPY /Y "%ProgramFiles%\OpenSSL-Win64\bin\legacy.dll" "%UserProfile%\Projects\TC-master\build\bin\Release"
COPY /Y "%ProgramFiles%\OpenSSL-Win64\bin\libssl-3-x64.dll" "%UserProfile%\Projects\TC-master\build\bin\Release"
COPY /Y "%ProgramFiles%\OpenSSL-Win64\bin\libcrypto-3-x64.dll" "%UserProfile%\Projects\TC-master\build\bin\Release"

Content

DIR "%ProgramFiles(x86)%\World of Warcraft\_retail_\Wow.exe"

DBCs, Maps, Gt, and Cameras

"%UserProfile%\Projects\TC-master\build\bin\Release\mapextractor.exe" -i "%ProgramFiles(x86)%\World of Warcraft\_retail_" -o "%UserProfile%\Projects\TC-master\build\bin\Release" -f "0" -p "wow"

VMaps

Extract

CD "%UserProfile%\Projects\TC-master\build\bin\Release" && "%UserProfile%\Projects\TC-master\build\bin\Release\vmap4extractor.exe" -d "%ProgramFiles(x86)%\World of Warcraft\_retail_" -p "wow" -l

Assemble

"%UserProfile%\Projects\TC-master\build\bin\Release\vmap4assembler.exe" --threads=%NUMBER_OF_PROCESSORS% "%UserProfile%\Projects\TC-master\build\bin\Release\Buildings" "%UserProfile%\Projects\TC-master\build\bin\Release\vmaps"

MMaps

"%UserProfile%\Projects\TC-master\build\bin\Release\mmaps_generator.exe" --silent --input "%UserProfile%\Projects\TC-master\build\bin\Release" --output "%UserProfile%\Projects\TC-master\build\bin\Release" --skipJunkMaps "true" --debugOutput "false" --bigBaseUnit "true" --threads %NUMBER_OF_PROCESSORS%

Move Files

MOVE /Y "%ProgramFiles(X86)%\World of Warcraft master\Cameras" "%UserProfile%\Projects\TC-master\build\bin\Release" && MOVE /Y "%ProgramFiles(X86)%\World of Warcraft master\dbc" "%UserProfile%\Projects\TC-master\build\bin\Release" && MOVE /Y "%ProgramFiles(X86)%\World of Warcraft master\maps" "%UserProfile%\Projects\TC-master\build\bin\Release" && MOVE /Y "%ProgramFiles(X86)%\World of Warcraft master\mmaps" "%UserProfile%\Projects\TC-master\build\bin\Release" && MOVE /Y "%ProgramFiles(X86)%\World of Warcraft master\vmaps" "%UserProfile%\Projects\TC-master\build\bin\Release"

Check Files

TREE "%UserProfile%\Projects\TC-master\build\bin\Release\dbc" && TREE "%UserProfile%\Projects\TC-master\build\bin\Release\maps" && TREE "%UserProfile%\Projects\TC-master\build\bin\Release\Cameras" && TREE "%UserProfile%\Projects\TC-master\build\bin\Release\vmaps" && TREE "%UserProfile%\Projects\TC-master\build\bin\Release\mmaps"
"explorer.exe" "%UserProfile%\Projects\TC-master\build\bin\Release"

Clean-up

RMDIR /S /Q "%ProgramFiles(X86)%\World of Warcraft master\Buildings" && DEL /Q "%ProgramFiles(X86)%\World of Warcraft master\mapextractor.exe" "%ProgramFiles(X86)%\World of Warcraft master\mmaps_generator.exe" "%ProgramFiles(X86)%\World of Warcraft master\vmap4assembler.exe" "%ProgramFiles(X86)%\World of Warcraft master\vmap4extractor.exe"
"explorer.exe" "%ProgramFiles(X86)%\World of Warcraft master"

World Database

TDB

DEL /Q "%UserProfile%\Projects\TC-master\build\bin\Release\TDB_full_world_335."*".sql" & "%ProgramFiles%\7-Zip\7z.exe" x "%UserProfile%\Downloads\TDB_full_world_335."*".7z" -o"%UserProfile%\Projects\TC-master\build\bin\Release"
DEL /Q "%UserProfile%\Downloads\TDB_full_world_335."*".7z"

Settings

authserver

COPY /Y "%UserProfile%\Projects\TC-master\build\bin\Release\authserver.conf.dist" "%UserProfile%\Projects\TC-master\build\bin\Release\authserver.conf"
MKDIR "%UserProfile%\Projects\TC-master\conf\authserver" & "notepad.exe" "%UserProfile%\Projects\TC-master\conf\authserver\localhost.conf"
[authserver]

# Connection
BindIP = "127.0.0.1"
MySQLExecutable = "C:\Program Files\MariaDB 12.2\bin\mariadb.exe"
AllowLoggingIPAddressesInDatabase = 0

LoginDatabaseInfo = ".;3306;authserver;x;authserver"

# Etc
Updates.EnableDatabases = 1
Updates.CleanDeadRefMaxCount = -1

# End

worldserver

COPY /Y "%UserProfile%\Projects\TC-master\build\bin\Release\worldserver.conf.dist" "%UserProfile%\Projects\TC-master\build\bin\Release\worldserver.conf"
MKDIR "%UserProfile%\Projects\TC-master\conf\worldserver" & "notepad.exe" "%UserProfile%\Projects\TC-master\conf\worldserver\localhost.conf"
[worldserver]

# Connection
BindIP = "127.0.0.1"
MySQLExecutable = "C:\Program Files\MariaDB 12.2\bin\mariadb.exe"
AllowLoggingIPAddressesInDatabase = 0

LoginDatabaseInfo = ".;3306;authserver;x;authserver"
CharacterDatabaseInfo = ".;3306;characters;x;characters"
WorldDatabaseInfo = ".;3306;worldserver;x;worldserver"

# Server
Updates.CleanDeadRefMaxCount = -1
FlashAtStart = 0
Server.LoginInfo = 1
Motd = "Welcome to your localhost server!"
AllowTickets = 0
CharDelete.Method = 1
CharDelete.KeepDays = 0
WhoList.Update.Interval = 300
HotSwap.Enabled = 0
HotSwap.EnableReCompiler = 0

# Quests
Quests.LowLevelHideDiff = -1
Quests.HighLevelHideDiff = -1

# Character
GM.LoginState = 0

# Protections
MaxOverspeedPings = 0
PacketSpoof.Policy = 0
ChatFakeMessagePreventing = 0
ChatFlood.MessageCount = 0

# End

Firewall

Block

"netsh.exe" advfirewall firewall add rule name="TrinityCore master localhost (authserver)" dir="in" action="block" profile="any" program="%UserProfile%\Projects\TC-master\build\bin\Release\authserver.exe" & "netsh.exe" advfirewall firewall add rule name="TrinityCore master localhost (authserver)" dir="out" action="block" profile="any" program="%UserProfile%\Projects\TC-master\build\bin\Release\authserver.exe" & "netsh.exe" advfirewall firewall add rule name="TrinityCore master localhost (worldserver)" dir="in" action="block" profile="any" program="%UserProfile%\Projects\TC-master\build\bin\Release\worldserver.exe" & "netsh.exe" advfirewall firewall add rule name="TrinityCore master localhost (worldserver)" dir="out" action="block" profile="any" program="%UserProfile%\Projects\TC-master\build\bin\Release\worldserver.exe"

Delete Rules

"netsh.exe" advfirewall firewall delete rule name="TrinityCore master localhost (authserver)" & "netsh.exe" advfirewall firewall delete rule name="TrinityCore master localhost (worldserver)"

Scripts

MKDIR "%UserProfile%\Projects\TC-master\scripts"
"explorer.exe" "%UserProfile%\Projects\TC-master\scripts"

Server Start

"notepad.exe" "%UserProfile%\Projects\TC-master\scripts\localhost-server-start.bat"
@echo off

TITLE TrinityCore 335 Launcher
CD "%Temp%"

START "MariaDB Server" /MIN "%ProgramFiles%\MariaDB 12.2\bin\mariadbd.exe" --defaults-file="%UserProfile%\Projects\TC-master\mariadb\database\my.ini"
TIMEOUT /T "2" /NOBREAK

CD "%UserProfile%\Projects\TC-master\build\bin\Release"
START "WoW master [auth]" /MIN "%UserProfile%\Projects\TC-master\build\bin\Release\authserver.exe" --config-dir "%UserProfile%\Projects\TC-master\conf\authserver"
START "WoW master [world]" /MIN "%UserProfile%\Projects\TC-master\build\bin\Release\worldserver.exe" --config-dir "%UserProfile%\Projects\TC-master\conf\worldserver"

:: End
"%UserProfile%\Projects\TC-master\scripts\localhost-server-start.bat"

Server Update

"notepad.exe" "%UserProfile%\Projects\TC-master\scripts\localhost-server-update.bat"
@echo off

TITLE TrinityCore 335 Updater
CD "%Temp%"

"%ProgramFiles%\Git\bin\git.exe" -C "%UserProfile%\Projects\TC-master\src" reset --hard "origin/master"
"%ProgramFiles%\Git\bin\git.exe" -C "%UserProfile%\Projects\TC-master\src" pull origin "master" --rebase

"%ProgramFiles(x86)%\Microsoft Visual Studio\Installer\setup.exe" update --channelId "VisualStudio.17.Release" --channelURI "https://aka.ms/vs/17/release/channel" --productId "Microsoft.VisualStudio.Product.Community" --nocache --norestart --quiet

SET "LLVMInstallDir=%ProgramFiles%\LLVM"
SET "LLVMToolsVersion=22"

"%ProgramFiles%\CMake\bin\cmake.exe" -S "%UserProfile%\Projects\TC-master\src" -B "%UserProfile%\Projects\TC-master\build" -G "Visual Studio 17 2022" --fresh -Wno-dev -DBOOST_ROOT="%SystemDrive%/local/boost_1_90_0" -DMYSQL_INCLUDE_DIR="%ProgramFiles%\MariaDB 12.2\include\mysql" -DMYSQL_LIBRARY="%ProgramFiles%\MariaDB 12.2\lib\libmariadb.lib" -DWITHOUT_METRICS="1" -DTOOLS="0" -T "ClangCL" -DBoost_COMPILER="-vc143" -DCMAKE_CXX_FLAGS="/EHs /arch:AVX2 /favor:INTEL64 /Gz /Oy /GS- /guard:cf- /W0 -Wno-everything"

SET "MSBUILDDISABLENODEREUSE=1"

"%ProgramFiles%\Microsoft Visual Studio\2022\Community\MSBuild\Current\Bin\amd64\MSBuild.exe" "%UserProfile%\Projects\TC-master\build\ALL_BUILD.vcxproj" -target:"Build" -property:"Configuration=Release" -maxCpuCount

SET "LLVMInstallDir="
SET "LLVMToolsVersion="
SET "MSBUILDDISABLENODEREUSE="

MSG %USERNAME% /TIME:"2" "WoW master localhost server update complete"

:: End
"%UserProfile%\Projects\TC-master\scripts\localhost-server-update.bat"

Database Back-up

"notepad.exe" "%UserProfile%\Projects\TC-master\scripts\localhost-database-backup.bat"
@echo off

TITLE WoW master Database Back-up
CD "%Temp%"

START "MariaDB Server" /MIN "%ProgramFiles%\MariaDB 12.2\bin\mariadbd.exe" --defaults-file="%UserProfile%\Projects\TC-master\mariadb\database\my.ini" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock"
TIMEOUT /T "2" /NOBREAK

"%ProgramFiles%\MariaDB 12.2\bin\mariadb-dump.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" --opt -r "%UserProfile%\Downloads\%RANDOM%-localhost-authserver.sql" "authserver"
"%ProgramFiles%\MariaDB 12.2\bin\mariadb-dump.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" --opt -r "%UserProfile%\Downloads\%RANDOM%-localhost-characters.sql" "characters"

"%ProgramFiles%\MariaDB 12.2\bin\mariadb-admin.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" "shutdown"

MSG %USERNAME% /TIME:"2" "WoW master Databases Backed-up Successfully to Downloads"

:: End
"%UserProfile%\Projects\TC-master\scripts\localhost-database-backup.bat"

Launcher Shortcuts

Desktop

Server Start

"%UserProfile%\Projects\TC-master\scripts\localhost-server-start.bat"
WoW master Server

Start Menu

MKDIR "%AppData%\Microsoft\Windows\Start Menu\Programs\World of Warcraft master" & "explorer.exe" "%AppData%\Microsoft\Windows\Start Menu\Programs\World of Warcraft master"

Server Start

"%UserProfile%\Projects\TC-master\scripts\localhost-server-start.bat"
Server Start

Update

"%UserProfile%\Projects\TC-master\scripts\localhost-server-update.bat"
Server Updater

Database Backup

"%UserProfile%\Projects\TC-master\scripts\localhost-database-backup.bat"
Database Back-up

Install Notes

"https://wiki.realmofespionage.xyz/servers;windows;games;trinitycore_master_localhost"
Install Notes (Server)

Realm

authserver

"%ProgramFiles%\MariaDB 12.2\bin\mariadbd.exe" --defaults-file="%UserProfile%\Projects\TC-master\mariadb\database\my.ini"
CD "%UserProfile%\Projects\TC-master\build\bin\Release" && "authserver.exe" --config-dir "%UserProfile%\Projects\TC-master\conf\authserver"

Create GM Account

CD "%UserProfile%\Projects\TC-master\build\bin\Release" && "worldserver.exe" --config-dir "%UserProfile%\Projects\TC-master\conf\worldserver"
account create Espionage724 x
account set password Espionage724 x x
account set gmlevel Espionage724 3 -1
server shutdown 1

Extras

Items

Northshire Gift Voucher

.additem 14646

Tyrael's Hilt

.additem 39656

Character Data

Backup

"%ProgramFiles%\MariaDB 12.2\bin\mariadbd.exe" --defaults-file="%UserProfile%\Projects\TC-master\mariadb\database\my.ini" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock"
CD "%UserProfile%\Downloads" && "%ProgramFiles%\MariaDB 12.2\bin\mariadb-dump.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" --opt -r "localhost-authserver.sql" "authserver"
CD "%UserProfile%\Downloads" && "%ProgramFiles%\MariaDB 12.2\bin\mariadb-dump.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" --opt -r "localhost-characters.sql" "characters"

Restore

"%ProgramFiles%\MariaDB 12.2\bin\mariadbd.exe" --defaults-file="%UserProfile%\Projects\TC-master\mariadb\database\my.ini" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock"

authserver

"%ProgramFiles%\MariaDB 12.2\bin\mariadb.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" --execute="CREATE DATABASE authserver"
"%ProgramFiles%\MariaDB 12.2\bin\mariadb.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" "authserver" < x

characters

"%ProgramFiles%\MariaDB 12.2\bin\mariadb.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" --execute="CREATE DATABASE characters"
"%ProgramFiles%\MariaDB 12.2\bin\mariadb.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" "characters" < x

TODOs

"%ProgramFiles%\MariaDB 12.2\bin\mariadb-admin.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" variables
"%ProgramFiles%\MariaDB 12.2\bin\mariadb-admin.exe" -u "root" --socket="MySQL" variables
"%ProgramFiles%\MariaDB 12.2\bin\mariadb-admin.exe" -u "root" --socket="MySQL" variables  | FIND "socket"
"%ProgramFiles%\MariaDB 12.2\bin\mariadb-check.exe" -u "root" --socket="%UserProfile%\Projects\TC-master\mariadb\mariadb.sock" -o -A -f -e --auto-repair
3)
2025/12/12: 00:04:43.25
4)
for d3cn; compiled fine after disabling utf8; failed both MSVC/LLVM with utf8 enabled; needs re-tested with LLVM
5)
2025/12/13: 28 Minutes 26 Seconds at --threads 8