Added (really horrible) dragging

This commit is contained in:
andreja6
2020-03-13 23:50:37 -07:00
parent 9217e78084
commit 520e7f1bef
3 changed files with 40 additions and 4 deletions

View File

@@ -52,14 +52,14 @@ Vector3 Mouse::getPosition()
if(G3D::isFinite(testRay.intersectionTime(p->getBox())))
{
if (nearest>testRay.intersectionTime(p->getBox()))
/*if (nearest>testRay.intersectionTime(p->getBox()))
{
// BROKEN
pos = (testRay.closestPoint(p->getPosition()/2));
}
}*/
/* // This would be an overall better solution
// This would be an overall better solution
for(char i = 0; i < 6; i++)
{
Vector3 side1;
@@ -74,7 +74,7 @@ Vector3 Mouse::getPosition()
nearest = newdistance;
pos = inter;
}
}*/
}
}
}
return pos;