mirror of
https://github.com/AleziaKurdis/overte.git
synced 2025-04-08 23:12:16 +02:00
fix sphere-cube collisions at edges
This commit is contained in:
parent
0e3d66caf6
commit
6cc8d53a6d
1 changed files with 2 additions and 0 deletions
|
@ -701,6 +701,7 @@ void ShapeColliderTests::sphereTouchesAACubeFaces() {
|
|||
|
||||
for (int i = 0; i < axes.size(); ++i) {
|
||||
glm::vec3 axis = axes[i];
|
||||
std::cout << "adebug j = " << i << " axis = " << axis << std::endl; // adebug
|
||||
// outside
|
||||
{
|
||||
collisions.clear();
|
||||
|
@ -809,6 +810,7 @@ void ShapeColliderTests::sphereTouchesAACubeEdges() {
|
|||
|
||||
for (int i =0; i < axes.size(); ++i) {
|
||||
glm::vec3 axis = axes[i];
|
||||
std::cout << "adebug i = " << i << " axis = " << axis << std::endl; // adebug
|
||||
float lengthAxis = glm::length(axis);
|
||||
axis /= lengthAxis;
|
||||
float overlap = 0.25f;
|
||||
|
|
Loading…
Reference in a new issue