unify(map): Merge and move GameLogic map headers and implementations to Core - #3189
Conversation
PR Summary by QodoUnify map: merge GameLogic map implementations
AI Description
Diagram
High-Level Assessment
Files changed (6)
|
Code Review by Qodo
1. Retail parser reads v2 dictionaries
|
59b40a9 to
21a5be6
Compare
|
You missed the other instances of |
|
/agentic_review |
ok, this is bad, well im working on it, maybe im still lacking, well get them all. |
|
Code review by qodo was updated up to the latest commit 21a5be6 |
21a5be6 to
82d9f62
Compare
i think i chnaged them all, hope so. |
|
You should try to minimize these guards, only add as needed. Consider when it may affect the CRC and when it doesn’t. For example deleting polygon triggers you would expect impacts CRC, but adding a function or class member or define generally doesn’t. |
One of the finer nuances here that determines if it affects the CRC is how the data is handled for the CRC. There are some instances where a whole object get's CRC'ed instead of its portion of the CRC being generated from the objects specific CRC function. But what you mentioned is true as long as the above is not a problem. |
well, yes that make sense, will look into it, but how can i test if my chnage will impact CRC, like replays or something, a general question? |
There is no standardized vgenerals replay testing right now but you could create a new replay in a map that has polygon triggers (or add them yourself, and make sure the trigger affects the game somehow) with AI's and then replay check them with |
82d9f62 to
7177417
Compare
|
updated and cleaned up the merge, it now has less guards, and now the behavior is:
ready for review |
|
/agentic_review |
|
Code review by qodo was updated up to the latest commit 7177417 |
|
Note that "merge with rebase" is the same as "squash merge" when you only have one commit. Perhaps close #3190 and put the move in here? Right now it's also confusing for people to review because of the depends on |
|
75e2c2c to
2ca07b0
Compare
9190d17 to
d0148eb
Compare
d0148eb to
23c73bd
Compare
what is left for this to get merged? |
|
There are 2 open comments. |
yes the trigger points and the comment, i will add the comment, as for the trigger point i assume it can be left as it is, behind a guard, well just to be safe! |
23c73bd to
35e4f35
Compare
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (19)
💤 Files with no reviewable changes (9)
🚧 Files skipped from review as they are similar to previous changes (2)
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review. WalkthroughThe change moves map and game-logic sources into Core, removes legacy copies, adds retail compatibility guards, updates polygon-trigger serialization, and adds terrain crater generation. ChangesCore game-engine migration
Priority: ➖ Normal Estimated code review effort: 4 (Complex) | ~45 minutes Change: Feature 🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Advanced
Run ID: f7bab736-5b3d-4d54-8985-12751d8fe003
📒 Files selected for processing (19)
Core/GameEngine/CMakeLists.txtCore/GameEngine/Include/Common/GameDefines.hCore/GameEngine/Include/Common/MapReaderWriterInfo.hCore/GameEngine/Include/GameLogic/PolygonTrigger.hCore/GameEngine/Include/GameLogic/SidesList.hCore/GameEngine/Include/GameLogic/TerrainLogic.hCore/GameEngine/Source/GameLogic/Map/PolygonTrigger.cppCore/GameEngine/Source/GameLogic/Map/SidesList.cppCore/GameEngine/Source/GameLogic/Map/TerrainLogic.cppGenerals/Code/GameEngine/CMakeLists.txtGenerals/Code/GameEngine/Include/Common/MapReaderWriterInfo.hGenerals/Code/GameEngine/Include/GameLogic/PolygonTrigger.hGenerals/Code/GameEngine/Include/GameLogic/SidesList.hGenerals/Code/GameEngine/Include/GameLogic/TerrainLogic.hGenerals/Code/GameEngine/Source/GameLogic/Map/PolygonTrigger.cppGenerals/Code/GameEngine/Source/GameLogic/Map/SidesList.cppGenerals/Code/GameEngine/Source/GameLogic/Map/TerrainLogic.cppGeneralsMD/Code/GameEngine/CMakeLists.txtscripts/cpp/unify_move_files.py
💤 Files with no reviewable changes (6)
- Generals/Code/GameEngine/Include/GameLogic/PolygonTrigger.h
- Generals/Code/GameEngine/Source/GameLogic/Map/SidesList.cpp
- Generals/Code/GameEngine/Include/Common/MapReaderWriterInfo.h
- Generals/Code/GameEngine/Include/GameLogic/TerrainLogic.h
- Generals/Code/GameEngine/Include/GameLogic/SidesList.h
- Core/GameEngine/Source/GameLogic/Map/TerrainLogic.cpp
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review.
|
|
||
| for (Int i = iMin.x; i <= iMax.x; i++ ) | ||
| { | ||
| for ( Int j=0; j <= iMax.y; j++ ) |
There was a problem hiding this comment.
🚀 Performance & Scalability | 🟡 Minor | ⚡ Quick win
Start the inner loop at iMin.y.
For objects above y = 0, this loop scans rows from 0 through iMax.y. Rows below iMin.y cannot be inside the crater. The work therefore scales with the object Y coordinate instead of the crater radius.
Proposed fix
- for ( Int j=0; j <= iMax.y; j++ )
+ for ( Int j=iMin.y; j <= iMax.y; j++ )📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| for ( Int j=0; j <= iMax.y; j++ ) | |
| for ( Int j=iMin.y; j <= iMax.y; j++ ) |
There was a problem hiding this comment.
Can make a bug report for it. Outside the scope of this merge.
There was a problem hiding this comment.
@xezon, acknowledged. The loop-bound issue is outside the scope of this merge.
Do you want me to open a follow-up GitHub issue for TerrainLogic::createCraterInTerrain?
You are interacting with an AI system.
There was a problem hiding this comment.
Seems like the humans are having a chat. I'll hop back into my burrow for now. If you need me again, just tag @coderabbitai in a new comment, and I'll come hopping out!
35e4f35 to
b1aeb53
Compare
b1aeb53 to
ea1d6bd
Compare
Import 18 upstream commits from TheSuperHackers up to e401710, including the weekly-2026-09-18 tag. Key upstream updates integrated: - unify(map): Move SidesList, PolygonTrigger, and TerrainLogic to Core (TheSuperHackers#3189) - bugfix(recorder): Prevent null dereference in playback without local player (TheSuperHackers#3240) - bugfix(network): Prevent LAN game room hang from long player names (TheSuperHackers#3039) - fix(gameinfo): Clear GameSlot IP on reset (TheSuperHackers#3311) - fix(ww3d2): Copy string setter inputs before freeing aliased storage (TheSuperHackers#3313) - fix(saveload): Check version instead of currentVersion in xfer (TheSuperHackers#3300, TheSuperHackers#3299) - bugfix(ingameui): Convert MessageDelayMS to logic frames (TheSuperHackers#3133) - fix(controlbar): Prevent null deref when RallyPointMarker undefined (TheSuperHackers#3304) - fix(terrainvisual): Prevent null deref in loadRequire (TheSuperHackers#3306) - fix(pointgroup): Prevent null deref when no size array given (TheSuperHackers#3280) - fix(modeldraw): Prevent null deref in handleClientRecoil (TheSuperHackers#3301) - bugfix(pathfinder): Prevent crash in processHierarchicalCell (TheSuperHackers#3296) - fix(ini): Prevent uninitialized stack variable in parseBitString8 (TheSuperHackers#3307) - refactor(particlesys): Use particle alignment enum for batching (TheSuperHackers#3309) Conflicts resolved: - Core/GameEngine/Source/GameNetwork/GameInfo.cpp: Preserved percentEncodeMapName - Core/GameEngine/Source/GameNetwork/LANAPIhandlers.cpp: Preserved CopyWcharToWindowsWideChar - Generals/Code/GameEngine/Source/Common/Recorder.cpp: Preserved CRCInfo* allocation model - GeneralsMD/Code/GameEngine/Source/Common/Recorder.cpp: Preserved CRCInfo* allocation model - GeneralsMD/Code/GameEngine/Source/GameClient/InGameUI.cpp: Aligned timeout calculation - Deleted obsolete Generals/SidesList.cpp following Core unification - Rejected upstream changes to CI/CD workflow
Merge with Rebase
This merges and moves
MapReaderWriterInfo.h,PolygonTrigger,SidesList, andTerrainLogictogether with their matching headers.Target conditions preserve retail compatibility while sharing isolated Zero Hour improvements that do not affect the Generals CRC path:
Testing
git diff --check