mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 14:03:55 +02:00
don't cripple interface with log-spam
This commit is contained in:
parent
d939f03f8f
commit
d4faf69beb
1 changed files with 7 additions and 0 deletions
|
@ -15,6 +15,7 @@
|
|||
#include <EntityItemProperties.h>
|
||||
#include <EntityEditPacketSender.h>
|
||||
#include <PhysicsCollisionGroups.h>
|
||||
#include <LogHandler.h>
|
||||
|
||||
#include "BulletUtil.h"
|
||||
#include "EntityMotionState.h"
|
||||
|
@ -230,11 +231,17 @@ void EntityMotionState::setWorldTransform(const btTransform& worldTrans) {
|
|||
bool positionSuccess;
|
||||
_entity->setPosition(bulletToGLM(worldTrans.getOrigin()) + ObjectMotionState::getWorldOffset(), positionSuccess, false);
|
||||
if (!positionSuccess) {
|
||||
static QString repeatedMessage =
|
||||
LogHandler::getInstance().addRepeatedMessageRegex("EntityMotionState::setWorldTransform "
|
||||
"setPosition failed.*");
|
||||
qDebug() << "EntityMotionState::setWorldTransform setPosition failed" << _entity->getID();
|
||||
}
|
||||
bool orientationSuccess;
|
||||
_entity->setOrientation(bulletToGLM(worldTrans.getRotation()), orientationSuccess, false);
|
||||
if (!orientationSuccess) {
|
||||
static QString repeatedMessage =
|
||||
LogHandler::getInstance().addRepeatedMessageRegex("EntityMotionState::setWorldTransform "
|
||||
"setOrientation failed.*");
|
||||
qDebug() << "EntityMotionState::setWorldTransform setOrientation failed" << _entity->getID();
|
||||
}
|
||||
_entity->setVelocity(getBodyLinearVelocity());
|
||||
|
|
Loading…
Reference in a new issue