fix for velocity in units of domain size

This commit is contained in:
Andrew Meadows 2015-01-23 13:20:12 -08:00
parent f2bcdfa2b4
commit 36c20c24fe

View file

@ -732,7 +732,7 @@ void EntityItem::simulateKinematicMotion(float timeElapsed) {
} }
float speed = glm::length(velocity); float speed = glm::length(velocity);
const float EPSILON_LINEAR_VELOCITY_LENGTH = 0.001f; // 1mm/sec const float EPSILON_LINEAR_VELOCITY_LENGTH = 0.001f / (float)TREE_SCALE; // 1mm/sec
if (speed < EPSILON_LINEAR_VELOCITY_LENGTH) { if (speed < EPSILON_LINEAR_VELOCITY_LENGTH) {
setVelocity(ENTITY_ITEM_ZERO_VEC3); setVelocity(ENTITY_ITEM_ZERO_VEC3);
if (speed > 0.0f) { if (speed > 0.0f) {