Skip to content

Commit 00417f4

Browse files
authored
Merge pull request #27 from GeneralsOnlineDevelopmentTeam/main
main -> 60hz
2 parents 78b42a0 + 5921a5d commit 00417f4

1,202 files changed

Lines changed: 15454 additions & 20314 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

CMakePresets.json

Lines changed: 0 additions & 83 deletions
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,6 @@
3434
"RTS_BUILD_OPTION_PROFILE": "ON"
3535
}
3636
},
37-
{
38-
"name": "vc6-internal",
39-
"displayName": "Windows 32bit VC6 Internal",
40-
"inherits": "vc6",
41-
"cacheVariables": {
42-
"RTS_BUILD_OPTION_INTERNAL": "ON"
43-
}
44-
},
4537
{
4638
"name": "vc6-debug",
4739
"displayName": "Windows 32bit VC6 Debug",
@@ -103,14 +95,6 @@
10395
"RTS_BUILD_OPTION_PROFILE": "ON"
10496
}
10597
},
106-
{
107-
"name": "win32-internal",
108-
"inherits": "win32",
109-
"displayName": "Windows 32bit Internal",
110-
"cacheVariables": {
111-
"RTS_BUILD_OPTION_INTERNAL": "ON"
112-
}
113-
},
11498
{
11599
"name": "win32-debug",
116100
"inherits": "win32",
@@ -145,14 +129,6 @@
145129
"RTS_BUILD_OPTION_PROFILE": "ON"
146130
}
147131
},
148-
{
149-
"name": "win32-vcpkg-internal",
150-
"inherits": "win32-vcpkg",
151-
"displayName": "Windows 32bit VCPKG Internal",
152-
"cacheVariables": {
153-
"RTS_BUILD_OPTION_INTERNAL": "ON"
154-
}
155-
},
156132
{
157133
"name": "win32-vcpkg-debug",
158134
"inherits": "win32-vcpkg",
@@ -175,12 +151,6 @@
175151
"displayName": "Build Windows 32bit VC6 Release",
176152
"description": "Build Windows 32bit VC6 Release"
177153
},
178-
{
179-
"name": "vc6-internal",
180-
"configurePreset": "vc6-internal",
181-
"displayName": "Build Windows 32bit VC6 Internal",
182-
"description": "Build Windows 32bit VC6 Internal"
183-
},
184154
{
185155
"name": "vc6-profile",
186156
"configurePreset": "vc6-profile",
@@ -200,13 +170,6 @@
200170
"description": "Build Windows 32bit Release",
201171
"configuration": "Release"
202172
},
203-
{
204-
"name": "win32-internal",
205-
"configurePreset": "win32-internal",
206-
"displayName": "Build Windows 32bit Internal",
207-
"description": "Build Windows 32bit Internal",
208-
"configuration": "Release"
209-
},
210173
{
211174
"name": "win32-profile",
212175
"configurePreset": "win32-profile",
@@ -228,13 +191,6 @@
228191
"description": "Build Windows 32bit VCPKG Release",
229192
"configuration": "Release"
230193
},
231-
{
232-
"name": "win32-vcpkg-internal",
233-
"configurePreset": "win32-vcpkg-internal",
234-
"displayName": "Build Windows 32bit VCPKG Internal",
235-
"description": "Build Windows 32bit VCPKG Internal",
236-
"configuration": "Release"
237-
},
238194
{
239195
"name": "win32-vcpkg-profile",
240196
"configurePreset": "win32-vcpkg-profile",
@@ -284,19 +240,6 @@
284240
}
285241
]
286242
},
287-
{
288-
"name": "vc6-internal",
289-
"steps": [
290-
{
291-
"type": "configure",
292-
"name": "vc6-internal"
293-
},
294-
{
295-
"type": "build",
296-
"name": "vc6-internal"
297-
}
298-
]
299-
},
300243
{
301244
"name": "vc6-profile",
302245
"steps": [
@@ -323,19 +266,6 @@
323266
}
324267
]
325268
},
326-
{
327-
"name": "win32-internal",
328-
"steps": [
329-
{
330-
"type": "configure",
331-
"name": "win32-internal"
332-
},
333-
{
334-
"type": "build",
335-
"name": "win32-internal"
336-
}
337-
]
338-
},
339269
{
340270
"name": "win32-profile",
341271
"steps": [
@@ -375,19 +305,6 @@
375305
}
376306
]
377307
},
378-
{
379-
"name": "win32-vcpkg-internal",
380-
"steps": [
381-
{
382-
"type": "configure",
383-
"name": "win32-vcpkg-internal"
384-
},
385-
{
386-
"type": "build",
387-
"name": "win32-vcpkg-internal"
388-
}
389-
]
390-
},
391308
{
392309
"name": "win32-vcpkg-profile",
393310
"steps": [

Core/CMakeLists.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,19 @@ add_library(corei_gameengine_include INTERFACE)
33
add_library(corei_libraries_include INTERFACE)
44
add_library(corei_libraries_source_wwvegas INTERFACE)
55
add_library(corei_libraries_source_wwvegas_wwlib INTERFACE)
6+
add_library(corei_main INTERFACE)
67
add_library(corei_always INTERFACE)
78

89
target_include_directories(corei_gameengine_include INTERFACE "GameEngine/Include")
910
target_include_directories(corei_libraries_include INTERFACE "Libraries/Include")
1011
target_include_directories(corei_libraries_source_wwvegas INTERFACE "Libraries/Source/WWVegas")
1112
target_include_directories(corei_libraries_source_wwvegas_wwlib INTERFACE "Libraries/Source/WWVegas/WWLib")
13+
target_include_directories(corei_main INTERFACE "Main")
14+
1215
target_link_libraries(corei_always INTERFACE
1316
core_utility
1417
corei_libraries_include
18+
resources
1519
)
1620

1721
# Set where the build results will end up
@@ -24,6 +28,6 @@ add_subdirectory(Libraries)
2428
add_subdirectory(GameEngine)
2529

2630
# Platform specific GameEngine code
27-
# add_subdirectory(GameEngineDevice)
31+
add_subdirectory(GameEngineDevice)
2832

2933
add_subdirectory(Tools)

Core/GameEngine/CMakeLists.txt

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
set(GAMEENGINE_SRC
22
# Include/Common/AcademyStats.h
33
# Include/Common/ActionManager.h
4-
# Include/Common/ArchiveFile.h
5-
# Include/Common/ArchiveFileSystem.h
4+
Include/Common/ArchiveFile.h
5+
Include/Common/ArchiveFileSystem.h
66
# Include/Common/AsciiString.h
77
# Include/Common/AudioAffect.h
88
# Include/Common/AudioEventInfo.h
@@ -37,8 +37,8 @@ set(GAMEENGINE_SRC
3737
# Include/Common/encrypt.h
3838
# Include/Common/Energy.h
3939
# Include/Common/Errors.h
40-
# Include/Common/file.h
41-
# Include/Common/FileSystem.h
40+
Include/Common/file.h
41+
Include/Common/FileSystem.h
4242
# Include/Common/FunctionLexicon.h
4343
# Include/Common/GameAudio.h
4444
# Include/Common/GameCommon.h
@@ -63,8 +63,8 @@ set(GAMEENGINE_SRC
6363
# Include/Common/Language.h
6464
# Include/Common/LatchRestore.h
6565
# Include/Common/List.h
66-
# Include/Common/LocalFile.h
67-
# Include/Common/LocalFileSystem.h
66+
Include/Common/LocalFile.h
67+
Include/Common/LocalFileSystem.h
6868
# Include/Common/MapObject.h
6969
# Include/Common/MapReaderWriterInfo.h
7070
# Include/Common/MessageStream.h
@@ -91,7 +91,7 @@ set(GAMEENGINE_SRC
9191
# Include/Common/QuickmatchPreferences.h
9292
# Include/Common/QuotedPrintable.h
9393
# Include/Common/Radar.h
94-
# Include/Common/RAMFile.h
94+
Include/Common/RAMFile.h
9595
# Include/Common/RandomValue.h
9696
# Include/Common/Recorder.h
9797
# Include/Common/Registry.h
@@ -112,7 +112,8 @@ set(GAMEENGINE_SRC
112112
# Include/Common/StateMachine.h
113113
# Include/Common/StatsCollector.h
114114
# Include/Common/STLTypedefs.h
115-
# Include/Common/StreamingArchiveFile.h
115+
Include/Common/STLUtils.h
116+
Include/Common/StreamingArchiveFile.h
116117
# Include/Common/SubsystemInterface.h
117118
# Include/Common/SystemInfo.h
118119
# Include/Common/Team.h
@@ -629,8 +630,8 @@ set(GAMEENGINE_SRC
629630
# Source/Common/SkirmishBattleHonors.cpp
630631
# Source/Common/StateMachine.cpp
631632
# Source/Common/StatsCollector.cpp
632-
# Source/Common/System/ArchiveFile.cpp
633-
# Source/Common/System/ArchiveFileSystem.cpp
633+
Source/Common/System/ArchiveFile.cpp
634+
Source/Common/System/ArchiveFileSystem.cpp
634635
# Source/Common/System/AsciiString.cpp
635636
# Source/Common/System/BuildAssistant.cpp
636637
# Source/Common/System/CDManager.cpp
@@ -640,28 +641,28 @@ set(GAMEENGINE_SRC
640641
# Source/Common/System/Directory.cpp
641642
# Source/Common/System/DisabledTypes.cpp
642643
# Source/Common/System/encrypt.cpp
643-
# Source/Common/System/File.cpp
644-
# Source/Common/System/FileSystem.cpp
644+
Source/Common/System/File.cpp
645+
Source/Common/System/FileSystem.cpp
645646
# Source/Common/System/FunctionLexicon.cpp
646647
# Source/Common/System/GameCommon.cpp
647648
#Source/Common/System/GameMemory.cpp # is conditionally appended
648649
# Source/Common/System/GameType.cpp
649650
# Source/Common/System/Geometry.cpp
650651
# Source/Common/System/KindOf.cpp
651652
# Source/Common/System/List.cpp
652-
# Source/Common/System/LocalFile.cpp
653-
# Source/Common/System/LocalFileSystem.cpp
653+
Source/Common/System/LocalFile.cpp
654+
Source/Common/System/LocalFileSystem.cpp
654655
#Source/Common/System/MemoryInit.cpp # is conditionally appended
655656
# Source/Common/System/ObjectStatusTypes.cpp
656657
# Source/Common/System/QuotedPrintable.cpp
657658
# Source/Common/System/Radar.cpp
658-
# Source/Common/System/RAMFile.cpp
659+
Source/Common/System/RAMFile.cpp
659660
# Source/Common/System/registry.cpp
660661
# Source/Common/System/SaveGame/GameState.cpp
661662
# Source/Common/System/SaveGame/GameStateMap.cpp
662663
# Source/Common/System/Snapshot.cpp
663664
# Source/Common/System/StackDump.cpp
664-
# Source/Common/System/StreamingArchiveFile.cpp
665+
Source/Common/System/StreamingArchiveFile.cpp
665666
# Source/Common/System/SubsystemInterface.cpp
666667
# Source/Common/System/Trig.cpp
667668
# Source/Common/System/UnicodeString.cpp
File renamed without changes.

GeneralsMD/Code/GameEngine/Include/Common/ArchiveFileSystem.h renamed to Core/GameEngine/Include/Common/ArchiveFileSystem.h

File renamed without changes.
File renamed without changes.

Core/GameEngine/Include/Common/GameDefines.h

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,3 +40,16 @@
4040
#ifndef ENABLE_GAMETEXT_SUBSTITUTES
4141
#define ENABLE_GAMETEXT_SUBSTITUTES (1) // The code can provide substitute texts when labels and strings are missing in the STR or CSF translation file
4242
#endif
43+
44+
// Previously the configurable shroud sat behind #if defined(RTS_DEBUG)
45+
// Enable the configurable shroud to properly draw the terrain in World Builder without RTS_DEBUG compiled in.
46+
// Disable the configurable shroud to make shroud hacking a bit less accessible in Release game builds.
47+
#ifndef ENABLE_CONFIGURABLE_SHROUD
48+
#define ENABLE_CONFIGURABLE_SHROUD (1) // When enabled, the GlobalData contains a field to turn on/off the shroud, otherwise shroud is always enabled
49+
#endif
50+
51+
// Enable buffered IO in File System. Was disabled in retail game.
52+
// Buffered IO generally is much faster than unbuffered for small reads and writes.
53+
#ifndef USE_BUFFERED_IO
54+
#define USE_BUFFERED_IO (1)
55+
#endif

GeneralsMD/Code/GameEngine/Include/Common/LocalFile.h renamed to Core/GameEngine/Include/Common/LocalFile.h

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,12 +54,7 @@
5454

5555
#include "Common/file.h"
5656

57-
// srj sez: this was purely an experiment in optimization.
58-
// at the present time, it doesn't appear to be a good one.
59-
// but I am leaving the code in for now.
60-
// if still present in 2003, please nuke.
61-
#define NO_USE_BUFFERED_IO
62-
#ifdef USE_BUFFERED_IO
57+
#if USE_BUFFERED_IO
6358
#include <stdio.h>
6459
#endif
6560

@@ -85,11 +80,12 @@ class LocalFile : public File
8580
MEMORY_POOL_GLUE_ABC(LocalFile)
8681
private:
8782

88-
#ifdef USE_BUFFERED_IO
83+
#if USE_BUFFERED_IO
84+
// srj sez: this was purely an experiment in optimization.
85+
// at the present time, it doesn't appear to be a good one.
86+
// TheSuperHackers @info It is a good optimization and will be
87+
// significantly faster than unbuffered IO with small reads and writes.
8988
FILE* m_file;
90-
91-
enum { BUF_SIZE = 32768 };
92-
char m_vbuf[BUF_SIZE];
9389
#else
9490
int m_handle; ///< Local C file handle
9591
#endif

GeneralsMD/Code/GameEngine/Include/Common/LocalFileSystem.h renamed to Core/GameEngine/Include/Common/LocalFileSystem.h

File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)