Validate and Reposition Ground Units algorithm

[ADDED] UTILS.ValidateAndRepositionGroundUnits
[ADDED] SPAWN:InitValidateAndRepositionGroundUnits
[ADDED] CTLD.validateAndRepositionUnits
This commit is contained in:
smiki
2025-08-24 15:10:47 +02:00
parent 67cb844550
commit 78b3efcf00
2 changed files with 3 additions and 2 deletions

View File

@@ -4872,7 +4872,7 @@ function UTILS.FindNearestPointOnCircle(Vec1,Radius,Vec2)
return {x=qx, y=qy}
end
--- This function uses Disposition and other fallback logic to find better ground positions for a group of ground units.
--- This function uses Disposition and other fallback logic to find better ground positions for ground units.
--- NOTE: This is not a spawn randomizer.
--- It will try to find clear ground locations avoiding trees, water, roads, runways, map scenery, statics and other units in the area and modifies the provided positions table.
--- Maintains the original layout and unit positions as close as possible by searching for the next closest valid position to each unit.