don't accept incoming location edits if an entity is being controlled by a shouldSuppressLocationEdits action

This commit is contained in:
Seth Alves 2015-10-19 16:05:56 -07:00
parent 00594f0cce
commit 9e24542c0b

View file

@ -1810,25 +1810,25 @@ bool EntityItem::shouldSuppressLocationEdits() const {
}
void EntityItem::setPosition(const glm::vec3& value) {
if (!entity->shouldSuppressLocationEdits()) {
if (!shouldSuppressLocationEdits()) {
_transform.setTranslation(value); requiresRecalcBoxes();
}
}
void EntityItem::setRotation(const glm::quat& rotation) {
if (!entity->shouldSuppressLocationEdits()) {
if (!shouldSuppressLocationEdits()) {
_transform.setRotation(rotation); requiresRecalcBoxes();
}
}
void EntityItem::setVelocity(const glm::vec3& value) {
if (!entity->shouldSuppressLocationEdits()) {
if (!shouldSuppressLocationEdits()) {
_velocity = value;
}
}
void EntityItem::setAcceleration(const glm::vec3& value) {
if (!entity->shouldSuppressLocationEdits()) {
if (!shouldSuppressLocationEdits()) {
_acceleration = value;
}
}