Build Guide
From OuroDev
Prerequisites
Make sure to download VS 2010 Professional as well as VS 2019. We'll be switching all projects over to 2019 at some point.
You'll also need a working Microsoft SQL Server and SQL Server Management Studio.
If you downloaded VS 2010 Express then you need to change any instance of `"afxres.h"` to `<Windows.h>`, as well as define IDC_STATIC as -1 where necessary.
If you don't download VS 2019 then you need to open MasterSolution.sln as a text file and change `12.00` at the top of the file to `11.00`.
- Download the Issue 24 client and data files - this is not the SCORE client/data. - Download CoHDev_Source_Files_Current(Updated).zip. - Download ServerData.7z. - Clone the Cox/Source repository.
Building
- Open "Visual Studio Command Prompt (2010)" or "Developer Command Prompt for VS 2019". - Change the directory to Source/MasterSolution. - Run "powershell .\build.ps1". - Wait for all projects to successfully compile. Expect to wait between 10-20 minutes on a complete build with no previously generated files. - Decide now if you want to run an AuthServer. If so, build Source\AuthServer\src\AuthServer\AuthServer.sln.
Preparing Your Build
- Create a directory in Source\bin called data. - Open ServerData.7z and extract all files into Source\bin\data (the newly created directory). - Open CoHDev_Source_Files_Current(Updated).zip. - Extract "i24 Server and Client Piggs (extracted with CoHTools)" into Source\bin\data. - Copy maps.db from "map.db (modified, working on current VS2010 build)" and place it in Source\bin\data\server\db, overwriting the old maps.db - Copy the piggs folder from your i24 client directory and place them in Source\bin\. You should end up with Source\bin\piggs\ populated. - Create a directory in your C: drive called "CoH_Data" and another directory inside that, called "attributes" (C:\CoH_Data\attributes). - Run Source/bin/mapserver.exe -productionmode -templates in a command prompt. - Copy all files from C:\CoH_Data\attributes and place them into Source\bin\data\server\db\templates. - Open Source\DBSchemas and execute all the .sql files in the directory. You may need to change the file path -- anywhere works. Drop old database references before if there are any.
Server Configuration
Follow I25_Server_Setup#i25_Configuration_Files until we come up with an i24-optimized guide.
- Adjust the configuration files in Source\bin\data\server\db to utilize the correct database connections.
Running Your Build
- Start Source\1-start-servers.bat -- if you are using "UseFakeAuth 1" in your servers.cfg, remove or comment out the line for AuthServer. Vice versa.
Connecting to Your Server
- Run Source\bin\cityofheroes.exe -project coh -console - If using UseFakeAuth, append -db 127.0.0.1 - If using AuthServer, append -auth 127.0.0.1 - Click here if you are using an AuthServer and don't know how to make an account.