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
fix(gameengine): rocket smoke trail is the first effect culled
Olcay Seyganba0dd63f1261
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 4f94af13c..421f8f4bf 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -1275,7 +1275,7 @@ The whole HUD is on the hardware. Four colours carry it, and they mean the same- A big smoke cloud darkens the ground under it and fades as it does.- Smoke and dust stand in the sunlight. A column off a burning building throws a soft shadow as thick as the smoke is: a puff of dust barely tints the sand, a black plume darkens the ground, the tanks and the houses under it and the smoke behind it. The column itself is bright on the side facing the sun and goes dark on the far side, and a cloud drifting through a building's shadow greys over with everything else in there. A cloud used to cast a round patch straight down whichever way the sun stood, and took no shade from anything. Fire casts nothing, it is light. A machine that cannot run the newer picture keeps the round patch.- Fire lights its own smoke. The bottom of a column over a burning tank glows orange from the flames under it and flickers with them, then goes grey as it climbs out of their reach; an explosion's flash warms the smoke drifting past it. Smoke used to keep the same flat grey right down into the fire. Both renderers draw it. On the newer picture the glow stays lit where the column's own shadow falls, so a fire burning on the far side of a plume still shows orange through it instead of going dark with the smoke around it.-- Rockets leave smoke. A Tank Hunter's or a Missile Defender's rocket, a Comanche's pods, a Raptor's missiles and a Patriot's used to fly on a thin bright line of fire and nothing else. Now a grey trail hangs behind each one for under two seconds and thins away before it gets wider than a tank, and on the newer picture it shades the ground under it like any other smoke. The fire line and the flash at the nose are still there. Scuds, Tomahawks and TOW missiles had their smoke already and keep it.+- Rockets leave smoke. A Tank Hunter's or a Missile Defender's rocket, a Comanche's pods, a Raptor's missiles and a Patriot's used to fly on a thin bright line of fire and nothing else. Now a grey trail hangs behind each one for under two seconds and thins away before it gets wider than a tank, and on the newer picture it shades the ground under it like any other smoke. The fire line and the flash at the nose are still there. Scuds, Tomahawks and TOW missiles had their smoke already and keep it. On a low particle setting, or when the frame rate falls under 25, this smoke is the first effect to go: with the slider at 300, a rocket fight that keeps the slider full draws no trail at all and gives all 300 to the explosions and the rockets' own fire.- The soft blob shadow for trees and scenery had never been drawn at all.- Every one of the 128 tree types casts now, plus the bushes and palms.- A tree's shadow is the tree. Trunk, crown, and the gaps between the leaves, lying along thediff --git a/GeneralsMD/Code/Data/INI/ParticleSystemReforged.ini b/GeneralsMD/Code/Data/INI/ParticleSystemReforged.iniindex 89cd21b25..f7341e56d 100644--- a/GeneralsMD/Code/Data/INI/ParticleSystemReforged.ini+++ b/GeneralsMD/Code/Data/INI/ParticleSystemReforged.ini@@ -353,9 +353,11 @@ End; and it fades before it widens past a tank. BurstCount is the puffs laid along the path between two; bursts of the streak, which the Comanche's pods fire every second frame. The name holds no "smoke", so -smoke; leaves it alone. Scud, Tomahawk, TOW and Neutron missiles had smoke already and keep EA's.+; WEAPON_EXPLOSION is the lowest priority there is, so near the particle cap, or under dynamic LOD+; once the frame rate drops below 25, this smoke is the first to go and the streak and its flare stay.ParticleSystem MissileExhaustTrail- Priority = WEAPON_TRAIL+ Priority = WEAPON_EXPLOSIONIsOneShot = NoShader = ALPHAType = PARTICLEdiff --git a/GeneralsMD/Code/GameEngine/Source/GameClient/System/ParticleSys.cpp b/GeneralsMD/Code/GameEngine/Source/GameClient/System/ParticleSys.cppindex 6a995b9ae..2f004d0f9 100644--- a/GeneralsMD/Code/GameEngine/Source/GameClient/System/ParticleSys.cpp+++ b/GeneralsMD/Code/GameEngine/Source/GameClient/System/ParticleSys.cpp@@ -2333,7 +2333,9 @@ Bool ParticleSystem::updateEmission( Int localPlayerIndex, Bool *keepSystem )chainedInfo.m_pos.x = from.x + (rootPos.x - from.x) * along + offset->x;chainedInfo.m_pos.y = from.y + (rootPos.y - from.y) * along + offset->y;chainedInfo.m_pos.z = from.z + (rootPos.z - from.z) * along + offset->z;- chained->createParticle( &chainedInfo, priority );+ // its own priority, not the master's: the LOD and cap checks then drop the+ // chained smoke before the streak it rides on+ chained->createParticle( &chainedInfo, chained->getPriority() );}}}