refactor: Split preserve retail behavior flags#2691
refactor: Split preserve retail behavior flags#2691xezon merged 7 commits intoTheSuperHackers:mainfrom
Conversation
|
| Filename | Overview |
|---|---|
| Core/GameEngine/Include/Common/GameDefines.h | Replaces the single PRESERVE_RETAIL_BEHAVIOR flag with 14 granular PRESERVE_* flags plus a new ALLOW_MONEY_PER_MINUTE_FOR_PLAYER flag; all defaults are logically consistent with the original behavior or intentionally changed with Game Design Committee approval. |
| Core/GameEngine/Source/GameClient/SelectionInfo.cpp | Replaces PRESERVE_RETAIL_BEHAVIOR with PRESERVE_OCCUPANT_DETECTION_VIA_DRAG_SELECTION (default 1) in two guards; both #if expressions evaluate identically to before. |
| Generals/Code/GameEngine/Source/Common/GlobalData.cpp | Replaces #if !PRESERVE_RETAIL_BEHAVIOR with #if ALLOW_MONEY_PER_MINUTE_FOR_PLAYER (default 0); the AllowMoneyPerMinuteForPlayer INI entry remains disabled by default, preserving prior behavior. |
| GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Body/UndeadBody.cpp | Zero Hour-only file; swaps PRESERVE_RETAIL_BEHAVIOR for PRESERVE_PREMATURE_BATTLE_BUS_DEATH (default 1), keeping retail battle-bus death logic unchanged. |
| GeneralsMD/Code/GameEngine/Source/GameLogic/Object/Update/StealthUpdate.cpp | Zero Hour-only file; swaps PRESERVE_RETAIL_BEHAVIOR for PRESERVE_STRUCTURE_STEALTH_DURING_REPAIR (default 0, GDC-approved fix); the healing-damage stealth guard is now disabled by default. |
| Generals/Code/GameEngine/Source/GameLogic/Object/Weapon.cpp | Both trimOldHistoricDamage and processHistoricDamage guard expressions swap PRESERVE_RETAIL_BEHAVIOR for PRESERVE_UNRELIABLE_FIRESTORMS (default 0, GDC-approved); RETAIL_COMPATIBLE_CRC still forces the retail path when CRC compat is required. |
| Generals/Code/GameEngine/Source/GameLogic/Object/Collide/CrateCollide/CrateCollide.cpp | m_allowMultiPickup initialization now uses PRESERVE_MULTI_CRATE_PICKUP (default 0, GDC-approved); multi-pickup is disabled by default. |
Reviews (4): Last reviewed commit: "refactor: Order flags lexicographically" | Re-trigger Greptile
|
I think it would be better to split these defines out into their own file of GameplayFixDefines or something similar But keep preserve retail behaviour as an encompassing switch. |
How useful do you think a master flag would be? Does it outweigh the additional maintenance burden? |
|
I think after this change, we need to discuss what the workflow would be for controversial features or bug fixes that alter retail behaviour. Do we keep the default as what the author and reviewer think is correct? Or keep the original retail experience as default? Or wait for committee decision and input and implement that as the default? The cons of the first and third options are that balance changes a lot, has many talks, takes time and many people will disagree. Over time. This repo was for building the game, not publishing and shipping it. I think it is better to keep the retail behaviour as the default. And let the publishers decide what to enable or not, and whether to follow the committee. This will be helpful too for modders who prefer the retail experience for their mods. |
|
Much more fun to write it this way: This _MSC_VER Macro is very powerful, it symbolizes a specific match, one frozen in time. None may touch this. :) We have the long rumored Retail 1.0 someday. With this Macro style spread across the codebase we might even get to play with the classic Fork with he new tools as well. Like Tracy/SDL3 getting in nowadays. |
Generally, controversial code changes are default disabled first, but default enabled when approved by the Design Committee.
Right now, we set defaults for 2 Products:
This is already possible. Publishers can override the individual defines of GameDefines.h, without even touching GameDefines.h |
|
Does the title need to clarify that some setups were tweaked? |
Could it be in the extended description? |
This change splits the
PRESERVE_RETAIL_BEHAVIORflag into a separate, dedicated flag for each fix. This allows publishers to more easily toggle controversial fixes without having to manually look through the code and figure out how particular fixes work or are implemented.