Skip to content

Commit 6a6c498

Browse files
committed
Adjusted "UseAccurateSphereToRectCollision" and "CheckBoxBoundariesForDistCalc", should calculate properly now
1 parent 7e6516d commit 6a6c498

File tree

2 files changed

+309
-174
lines changed

2 files changed

+309
-174
lines changed

GeneralsMD/Code/GameEngine/Include/GameLogic/PartitionManager.h

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,16 @@ enum DistanceCalculationType CPP_11(: Int)
159159
FROM_BOUNDINGSPHERE_3D = 3 ///< measure from Object bounding sphere in 3d.
160160
};
161161

162+
//=====================================
163+
/** */
164+
//=====================================
165+
enum HeightBoundaryCheckType CPP_11(: Int)
166+
{
167+
DEFAULT_HEIGHT_CHECK = 0,
168+
SKIP_HEIGHT_CHECK = 1,
169+
BOUNDARY_HEIGHT_CHECK = 2
170+
};
171+
162172
//=====================================
163173
/**
164174
a Plain Old Data structure that is used to get optional results from collidesWith().
@@ -167,6 +177,7 @@ struct CollideLocAndNormal
167177
{
168178
Coord3D loc;
169179
Coord3D normal;
180+
Real distSqr;
170181
};
171182

172183
//=====================================
@@ -1530,7 +1541,8 @@ class PartitionManager : public SubsystemInterface, public Snapshot
15301541
const Coord3D* pos2,
15311542
const GeometryInfo& geom2,
15321543
Real angle2,
1533-
Bool passHeightCheck = FALSE
1544+
HeightBoundaryCheckType heightCheckType = DEFAULT_HEIGHT_CHECK,
1545+
Real *abDistSqr = NULL
15341546
) const;
15351547

15361548
/// finding legal positions in the world

0 commit comments

Comments
 (0)