Zero Hour rebuilt from EA's source: x64, Direct3D 11, VS2022/CMake, ~60 original bugs fixed, an AI that builds a base. Bring your own game.
C++ cmakecnccommand-and-conquercppdirectx11game-enginegame-preservationgeneralsrtssage-enginex64zero-hour
merge: reforged lighting, d3d11 object looks, china mine leds, faster tracers and shell glow
Olcay Seygan0a54d71450a7
diff --cc CHANGELOG.mdindex 269e89309,447401d2b..3c5ff2736--- a/CHANGELOG.md+++ b/CHANGELOG.md@@@ -344,8 -326,8 +346,8 @@@ found and fixed — EA's own, not- A Chinook unloads its passengers one at a time, not stacked in one frame.- Campaign reinforcements flown in by Chinook land again. That one-at-a-time unloading sent a mission's scripted Chinooks home with their cargo still aboard, so on the second American mission the dozers announced at the docks never got off, and neither did the next one.- A guarding unit no longer fights itself between returning to post and shooting back.-- Guard covers the circle you choose. How far a guard reached used to come from each unit's own eyesight, so Rangers and Missile Defenders posted on the same spot held circles of 180 and 270 and a raider standing between the two was only shot by half the group. Now one guard order gives the whole group one circle, the widest any of them had. Roll the mouse wheel while the guard key or the guard button is armed and the circle grows or shrinks before you click, drawn on the ground under the pointer as you go. Select a guarding group and its circle is drawn round the post, and every unit of yours on guard carries a small steel shield over its head, selected or not, in place of the blocky "G" it used to wear. The shield has smooth edges and a lit and a shaded half, and it shrinks as you zoom out the way the health bars do: at 1080p it was 24 pixels tall over every unit at every zoom, and it is now 18 up close and 11 from the opening camera, about the height of an infantryman's head.+- Every unit of yours on guard carries a small steel shield over its head, selected or not, in place of the blocky "G" it used to wear. The shield has smooth edges and a lit and a shaded half, and it shrinks as you zoom out the way the health bars do: at 1080p it was 24 pixels tall over every unit at every zoom, and it is now 18 up close and 11 from the opening camera, about the height of an infantryman's head.- - An Ambulance cleans up the toxins around it without being told. Its hose reaches 100, and that was all it ever looked at, so one parked a truck's length from a toxin pool sat and watched it. Standing idle or on guard, it now notices a pool, an anthrax cloud or a radiation field up to 300 away, drives over, washes off every one in that circle, and goes back to where it stood; one that was on guard is back on guard. A unit you are moving is never pulled off its order, and any order you give while it is cleaning ends the cleanup. Put down 150 to 250 from two Ambulances, one idle and one guarding, three poison fields were gone inside 16 seconds, both trucks were back on their spots, and a third Ambulance driving past a fourth field went straight on to where it was sent. The Cleanup Area button works better for it too: an Ambulance sent to clean an area used to shoot only at what was already in reach once it got there and stood still in front of the rest, and once the area was clean it never counted as idle again, so it ignored the next spill. Replays recorded before this change play out differently.+ - An Ambulance cleans up the toxins around it without being told. Its hose reaches 100, and that was all it ever looked at, so one parked a truck's length from a toxin pool sat and watched it. Standing idle or on guard, it now notices a pool, an anthrax cloud or a radiation field up to 300 away, drives over, washes off every one in that circle, and goes back to where it stood; one that was on guard is back on guard. A unit you are moving is never pulled off its order, and any order you give while it is cleaning ends the cleanup. Put down 150 to 250 from two Ambulances, one idle and one guarding, three poison fields were gone inside 16 seconds, both trucks were back on their spots, and a third Ambulance driving past a fourth field went straight on to where it was sent. The Cleanup Area button works better for it too: an Ambulance sent to clean an area used to shoot only at what was already in reach once it got there and stood still in front of the rest, and once the area was clean it never counted as idle again, so it ignored the next spill. An Ambulance guarding a tank goes back to guarding the tank after a cleanup, not the patch of ground it left from, so it follows the tank again: with the tank driven 600 away after the cleanup, the Ambulance reached it 17 seconds later. One that gives up on a spill it cannot drive up to no longer goes back for the same spill every time it stands idle; telling it to clean the area yourself still sends it. Replays recorded before this change play out differently.- Jets on guard attack what is inside the circle you drew. A plane on guard flies to its post and circles it, and since guards stopped shooting at enemies hidden in fog it only went after what that loop brought into its own sight: a Raptor guarding a circle of 700 hung over the post for the whole 80 seconds of the test with a power plant 550 out, and an Aurora circled for ten seconds before it found the same one. Aircraft are back on the original rule and take anything in the circle, fog or not. The Raptor's first missiles now land 11 seconds after the order and the Aurora's bomb after 9, and neither flies over the post first. Ground units still leave alone what they cannot see. A replay recorded before this change plays back differently.- H now sets a stance for the group. Defensive is how your units have always behaved: they fire on what comes into range and stay put. Aggressive lets them go after anything they can see, the way the computer's own units do, so a group left on aggressive clears the ground around it without being told. The button shows the stance the selection holds.- A queued attack move finishes its fights before the next order on the list goes out. The first enemy it met used to count as arriving, so a list of attack moves round a town skipped ahead a step at every skirmish and the group was off to the last point while the first was still contested. Replays recorded before this version play back differently.diff --cc GeneralsMD/Code/BuildFingerprint.manifestindex f43c048a1,f51c2c5a3..b685fbd0a--- a/GeneralsMD/Code/BuildFingerprint.manifest+++ b/GeneralsMD/Code/BuildFingerprint.manifest@@@ -9,20 -9,12 +9,24 @@@ Data/Art/Textures/ReforgedBarChinaRightData/Art/Textures/ReforgedBarGLACenter.tgaData/Art/Textures/ReforgedBarGLALeft.tgaData/Art/Textures/ReforgedBarGLARight.tga+Data/Art/Textures/ReforgedHudAmericaCommandBar.dds+Data/Art/Textures/ReforgedHudAmericaPowers.dds+Data/Art/Textures/ReforgedHudBlankTexture.tga+Data/Art/Textures/ReforgedHudChinaCommandBar.dds+Data/Art/Textures/ReforgedHudChinaPowers.dds+Data/Art/Textures/ReforgedHudControlButtons.dds+Data/Art/Textures/ReforgedHudDiplomacyWindow.dds+Data/Art/Textures/ReforgedHudDisconnectWindow.dds+Data/Art/Textures/ReforgedHudGlaCommandBar.dds+Data/Art/Textures/ReforgedHudGlaPowers.dds+Data/Art/Textures/ReforgedHudHelpbox.dds+Data/Art/Textures/ReforgedHudObsCommandBar.dds+Data/Art/Textures/ReforgedHudObsPlayerWindow.ddsData/Art/Textures/ReforgedLaserPink.tga+ Data/Art/Textures/ReforgedMineGlowBlue.tga+ Data/Art/Textures/ReforgedMineGlowRed.tga+ Data/Art/Textures/ReforgedMineLedBlue.tga+ Data/Art/Textures/ReforgedMineLedRed.tga-Data/Art/Textures/ReforgedOrders.tgaData/Art/Textures/ReforgedSignalAttack.tgaData/Art/Textures/ReforgedSignalDefend.tgaData/Art/Textures/ReforgedSignalLook.tga@@@ -257,6 -253,6 +277,7 @@@ Data/Scenarios/scudlaunch_film.txData/Scenarios/scudstorm.txtData/Scenarios/sentryattack.txtData/Scenarios/sentrydrone.txt++Data/Scenarios/shellpaths.txtData/Scenarios/shiftorders.txtData/Scenarios/shiftqueue.txtData/Scenarios/spectre_reaim.txtdiff --cc GeneralsMD/Code/GameEngine/Include/Common/GlobalData.hindex 0f4b14e12,66b0cc4fa..d169b42e7--- a/GeneralsMD/Code/GameEngine/Include/Common/GlobalData.h+++ b/GeneralsMD/Code/GameEngine/Include/Common/GlobalData.h@@@ -196,8 -225,8 +208,9 @@@ publicBool m_shadowsForParticles; // "ShadowsForParticles": big alpha-blended particle clouds drop a soft blob on the groundBool m_volumetricSmokeShadows; // "VolumetricSmokeShadows": smoke and dust shade the world and themselves through the sun's map (Direct3D 11)Bool m_smokeFireLighting; // "SmokeFireLighting": smoke takes light from the fire beside it+ Int m_shadowQuality; // "ShadowQuality": the sun's depth map at 1024, 2048 or 4096 texels a side (Direct3D 11)Bool m_classicGraphics; // "ClassicGraphics": the game's own art, tile, shadows and picture; read at startup+ Int m_lightingStyle; // "LightingStyle": LightingStyleType; the map's lights are rebalanced as each map loadsBool m_shadowMap; // "-shadowmap": draw the casters into the sun's depth buffer as wellBool m_shadowMapReport; // "-shadowmapreport": log what ended up in that buffer, once a secondBool m_shadowMapOnly; // "-shadowmaponly": the map's shadows with the stencil volumes' own darkening offdiff --cc GeneralsMD/Code/GameEngine/Source/Common/GlobalData.cppindex bafd2d399,f1e32d09d..ed2563ed5--- a/GeneralsMD/Code/GameEngine/Source/Common/GlobalData.cpp+++ b/GeneralsMD/Code/GameEngine/Source/Common/GlobalData.cpp@@@ -691,8 -694,8 +691,9 @@@ GlobalData::GlobalData(m_shadowsForParticles = TRUE; //on by default: the shipped INI has no entry for itm_volumetricSmokeShadows = TRUE;m_smokeFireLighting = TRUE;+ m_shadowQuality = 1; //medium, the 2048 map the shadows always hadm_classicGraphics = FALSE;+ m_lightingStyle = LIGHTING_STYLE_REFORGED;m_shadowMap = TRUE; //the sun's own shadows are what the game draws with nowm_shadowMapOnly = TRUE; //and they replace the stencil volumes rather than joining themm_shadowMapReport = FALSE;diff --cc GeneralsMD/Code/GameEngine/Source/Common/OptionsCatalog.cppindex 272ecfc02,411436498..9cd62693e--- a/GeneralsMD/Code/GameEngine/Source/Common/OptionsCatalog.cpp+++ b/GeneralsMD/Code/GameEngine/Source/Common/OptionsCatalog.cpp@@@ -96,7 -100,9 +96,8 @@@ OPTION_INT_ACCESSORS( m_fullscreenScaliOPTION_INT_ACCESSORS( m_msaaLevel )OPTION_BOOL_ACCESSORS( m_vsync )OPTION_BOOL_ACCESSORS( m_classicGraphics )+ OPTION_INT_ACCESSORS( m_lightingStyle )OPTION_INT_ACCESSORS( m_healthBarMode )-OPTION_INT_ACCESSORS( m_hudScale )OPTION_INT_ACCESSORS( m_playerColorScheme )OPTION_INT_ACCESSORS( m_textLanguage )OPTION_BOOL_ACCESSORS( m_showOrderLines )