Skip to content

Commit

Permalink
Fixed invalid collideeMD usage when modInfo.allowSepAxisCollisionTest…
Browse files Browse the repository at this point in the history
… = true
  • Loading branch information
sanguinariojoe committed Mar 23, 2020
1 parent cb54625 commit 7c63c73
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rts/Sim/MoveTypes/GroundMoveType.cpp
Expand Up @@ -2038,7 +2038,7 @@ void CGroundMoveType::HandleUnitCollisions(
const float2 collideeParams = {collidee->speed.w, collideeMobile? collideeMD->CalcFootPrintMaxInteriorRadius(): collidee->CalcFootPrintMaxInteriorRadius()};
const float4 separationVect = {collider->pos - collidee->pos, Square(colliderParams.y + collideeParams.y)};

if (!checkCollisionFuncs[allowSAT && (forceSAT || (collideeMD->CalcFootPrintAxisStretchFactor() > 0.1f))](separationVect, collider, collidee, colliderMD, collideeMD))
if (!checkCollisionFuncs[allowSAT && (forceSAT || (collideeMobile && collideeMD->CalcFootPrintAxisStretchFactor() > 0.1f))](separationVect, collider, collidee, colliderMD, collideeMD))
continue;


Expand Down

0 comments on commit 7c63c73

Please sign in to comment.