File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ # OpenSHC project specific:
2+ build /
3+ _build /
4+
15# Prerequisites
26* .d
37
Original file line number Diff line number Diff line change 1+ {
2+ "version" : 3 ,
3+ "configurePresets" : [
4+ {
5+ "name" : " windows-base" ,
6+ "hidden" : true ,
7+ "generator" : " Ninja" ,
8+ "binaryDir" : " ${sourceDir}/out/build/${presetName}" ,
9+ "installDir" : " ${sourceDir}/out/install/${presetName}" ,
10+ "cacheVariables" : {
11+ "CMAKE_C_COMPILER" : " cl.exe" ,
12+ "CMAKE_CXX_COMPILER" : " cl.exe"
13+ },
14+ "condition" : {
15+ "type" : " equals" ,
16+ "lhs" : " ${hostSystemName}" ,
17+ "rhs" : " Windows"
18+ }
19+ },
20+ {
21+ "name" : " x86-debug" ,
22+ "displayName" : " x86 Debug" ,
23+ "inherits" : " windows-base" ,
24+ "architecture" : {
25+ "value" : " x86" ,
26+ "strategy" : " external"
27+ },
28+ "cacheVariables" : {
29+ "CMAKE_BUILD_TYPE" : " Debug"
30+ }
31+ },
32+ {
33+ "name" : " x86-release" ,
34+ "displayName" : " x86 Release" ,
35+ "inherits" : " x86-debug" ,
36+ "cacheVariables" : {
37+ "CMAKE_BUILD_TYPE" : " Release"
38+ }
39+ },
40+ {
41+ "name" : " x86-release-debuginfo" ,
42+ "displayName" : " x86 Release (D)" ,
43+ "inherits" : " x86-release" ,
44+ "cacheVariables" : {
45+ "CMAKE_BUILD_TYPE" : " RelWithDebInfo"
46+ }
47+ }
48+ ]
49+ }
Original file line number Diff line number Diff line change 1+
2+ #include < iostream>
3+
4+ // We turn optimization off to make sure functions mentioned here aren't inlined
5+ #pragma optimize("", off)
6+
7+ int main (int argc, char ** argv)
8+ {
9+ std::cout << " Welcome to OpenSHC!" << std::endl;
10+
11+ // Here we refer to pieces of code that we don't want to have optimized away
12+ return 0 ;
13+ }
Original file line number Diff line number Diff line change @@ -5,10 +5,11 @@ Ready to dive in? Here's how you can start contributing to OpenSHC.
55
661. **Clone the Repository **
77
8- ```bash
8+ .. code-block :: bash
9+
910 git clone https://github.com/sourcehold/OpenSHC.git
1011 cd OpenSHC
11- ` ``
12+
1213
1314 2. **Install Dependencies **
1415
@@ -20,16 +21,18 @@ Ready to dive in? Here's how you can start contributing to OpenSHC.
20213. **Build the Project **
2122
2223 Open a prompt and load the MSVC 1400 environment (.bat file)
23-
24- ```bash
24+
25+ .. code-block :: bash
26+
2527 mkdir build && cd build
26- cmake .. -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=%1
28+ cmake .. -G " NMake Makefiles" -DCMAKE_BUILD_TYPE=RelWithDebInfo
2729 nmake
28- ` ``
2930
3031 4. **Run reccmp **
31- This compares
32- ```bash
33- reccmp-reccmp --paths "path\to\Stronghold Crusader.exe" build\OpenSHC.dll build\OpenSHC.pdb . %2 %3
34- ` ``
32+ This compares the functions in the dll to those in the original game.
33+
34+ .. code-block :: bash
35+
36+ reccmp-reccmp --paths " path\to\Stronghold Crusader.exe" " build\OpenSHC.dll" " build\OpenSHC.pdb" .
37+
3538
You can’t perform that action at this time.
0 commit comments