Core/Movement: merged Collision height handling from 335 branch to reduce the probability that creatures are falling under the map

This commit is contained in:
Ovahlord
2019-02-17 23:40:24 +01:00
parent 3357ae7940
commit 50a91bd590
16 changed files with 134 additions and 138 deletions

View File

@@ -221,7 +221,7 @@ bool DynamicMapTree::isInLineOfSight(G3D::Vector3 const& startPos, G3D::Vector3
float DynamicMapTree::getHeight(float x, float y, float z, float maxSearchDist, PhaseShift const& phaseShift) const
{
G3D::Vector3 v(x, y, z + 0.5f);
G3D::Vector3 v(x, y, z);
G3D::Ray r(v, G3D::Vector3(0, 0, -1));
DynamicTreeIntersectionCallback callback(phaseShift);
impl->intersectZAllignedRay(r, callback, maxSearchDist);