Stronghold Crusader (OpenSHC)
Stronghold Crusader
About the project
Stronghold: Crusader es el sucesor del juego de Firefly Studios Stronghold (2001). Crusader tiene mucho en común con el Stronghold original, pero se diferencia de su predecesor en el hecho de que el juego ya no se encuentra en una pseudo-Europa, sino que está ambientado en el Oriente medio, durante las Cruzadas. El juego cuenta con varias nuevas unidades de Arabia que se pueden comprar en un edificio nuevo, "The mercenary post". Aunque las tropas árabes no requieren recursos para producir, éstas son bastante caras. El juego también fue lanzado como "Stronghold Warchest".
2 versions of Stronghold Crusader
You're viewing: Stronghold Crusader (OpenSHC)
Official project information
OpenSHC 
An open source re-implementation of Stronghold Crusader 1. The beloved Castle Building, Real Time Strategy, and Simulation game reimplemented.
For running and developing this re-implementation, you need to own Stronghold Crusader 1.41 (Latin version), preferably from Steam or GOG.
Motivation
The original game is a masterpiece, seeing new reignited popularity since the release of the Definitive Edition. However, the Definitive Edition does not address various shortcomings in the original game. Furthermore, the new Definitive Edition requires modern hardware to run, which isn't something all fans can afford.
This reimplementation seeks to cater to the wishes of the dedicated community by providing an open source reimplementation that benefits modding to those that own the original Stronghold Crusader (available from Steam and GOG).
Usage
OpenSHC builds as a DLL that is loaded at game start. Functions that have a functionally identical reimplementation are hooked, such that the reimplemented versions are run instead of the original. This enables easy modding, although modding itself is currently beyond the scope of the OpenSHC project. Instead, the project currently focuses on reimplementing functionality.
Contribute
The development of this reimplementation is a stepwise process in which we aim to achieve a functionally identical reimplementation. We track progress using various tools.
All developers are welcome to contribute.
Get an overview here or dive straight in here!
Note, that you can use the commands /label-add <label>, <label>, ... and /label-remove <label>, <label>, ... in a PR comment(!) to add or remove the labels declaration/type change, in progress, documentation, help wanted and halted to inform the maintainers about the progress of the PR.
The commands need to be alone on a single line.
Requirements
Before you begin, install the following:
-
Stronghold Crusader 1.41 (Latin version)
The Steam release is the easiest version to obtain. Make sure the game installation uses a Latin-language version such as English or German.
-
CMake 3.24 or later
You can install it from:
If you already installed the Microsoft Visual C++ Development Tools, you can also install CMake through Visual Studio.
-
Python 3
-
clang-format 22 or later
Install it with:
python -m pip install clang-format -
An IDE with CMake support (recommended)
The repository is optimized for Visual Studio Code with the Microsoft C/C++ Extension Pack.
To automatically format and style new C++ files, install the clang-format Extension Pack.
Setup
1. Clone the repository
Clone the repository with submodules included:
git clone --recursive https://github.com/sourcehold/OpenSHC.git
Then enter the project directory:
cd OpenSHC
The
--recursiveflag is required because the repository depends on submodules, including the compiler.
2. Create a symbolic link to the original game
Run the following batch file:
softlink.bat
The script will ask for the full path to your Stronghold Crusader installation directory.
After the link is created, a folder named _original will appear in the repository root.
This script may require administrator privileges to be able to create the symbolic link
3. Set up the Python environment for binary comparison
To set up the binary comparison tools, run:
reccmp\dll\setup.bat
In the future, if you want to setup comparison of the reimplemented executable instead of the DLL, use:
reccmp\exe\setup.bat
Verifying the Setup
If both commands complete successfully, your development environment is ready and you can start working on OpenSHC.
1. Build the project
From the OpenSHC directory, run:
build.bat RelWithDebInfo OpenSHC.dll
2. Run binary comparison
This verifies byte-level accuracy between the reimplementation and the original binary:
reccmp/dll/run reccmp-reccmp --target STRONGHOLDCRUSADER
Tip: use
reccmp/dll/run reccmp-reccmp --target STRONGHOLDCRUSADER --verbose <hex address of function>to investigate code byte mismatches.
Tutorials
When you are set up, follow any of the tutorials such as this one to get you started!
Help
Raise an issue here on GitHub to receive support. Or visit the Discord server.
Additional Contributors
Also thanks to all the people who have contributed code and solutions through other means than direct commits!
Special Thanks
- to Firefly Studios for creating Stronghold Crusader.
- to the Ghidra project
- to the people behind reccmp
- to the whole UCP team