mirror of
https://github.com/overte-org/overte.git
synced 2025-04-23 18:13:29 +02:00
do not zero small velocities for non-bullet case
This commit is contained in:
parent
21b2d14956
commit
bf6b8f9ca7
1 changed files with 3 additions and 1 deletions
|
@ -714,10 +714,12 @@ void EntityItem::simulate(const quint64& now) {
|
|||
if (position.y <= getDistanceToBottomOfEntity()) {
|
||||
velocity = velocity * glm::vec3(1,-1,1);
|
||||
|
||||
// if we've slowed considerably, then just stop moving
|
||||
#ifndef USE_BULLET_PHYSICS
|
||||
// if we've slowed considerably, then just stop moving, but only if no BULLET
|
||||
if (glm::length(velocity) <= EPSILON_VELOCITY_LENGTH) {
|
||||
velocity = NO_VELOCITY;
|
||||
}
|
||||
#endif // !USE_BULLET_PHYSICS
|
||||
|
||||
position.y = getDistanceToBottomOfEntity();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue