mirror of
https://github.com/JulianGro/overte.git
synced 2025-05-06 17:49:05 +02:00
don't accept incoming location edits if an entity is being controlled by a shouldSuppressLocationEdits action
This commit is contained in:
parent
00594f0cce
commit
9e24542c0b
1 changed files with 4 additions and 4 deletions
|
@ -1810,25 +1810,25 @@ bool EntityItem::shouldSuppressLocationEdits() const {
|
||||||
}
|
}
|
||||||
|
|
||||||
void EntityItem::setPosition(const glm::vec3& value) {
|
void EntityItem::setPosition(const glm::vec3& value) {
|
||||||
if (!entity->shouldSuppressLocationEdits()) {
|
if (!shouldSuppressLocationEdits()) {
|
||||||
_transform.setTranslation(value); requiresRecalcBoxes();
|
_transform.setTranslation(value); requiresRecalcBoxes();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void EntityItem::setRotation(const glm::quat& rotation) {
|
void EntityItem::setRotation(const glm::quat& rotation) {
|
||||||
if (!entity->shouldSuppressLocationEdits()) {
|
if (!shouldSuppressLocationEdits()) {
|
||||||
_transform.setRotation(rotation); requiresRecalcBoxes();
|
_transform.setRotation(rotation); requiresRecalcBoxes();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void EntityItem::setVelocity(const glm::vec3& value) {
|
void EntityItem::setVelocity(const glm::vec3& value) {
|
||||||
if (!entity->shouldSuppressLocationEdits()) {
|
if (!shouldSuppressLocationEdits()) {
|
||||||
_velocity = value;
|
_velocity = value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void EntityItem::setAcceleration(const glm::vec3& value) {
|
void EntityItem::setAcceleration(const glm::vec3& value) {
|
||||||
if (!entity->shouldSuppressLocationEdits()) {
|
if (!shouldSuppressLocationEdits()) {
|
||||||
_acceleration = value;
|
_acceleration = value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue