From b9f9b180838a94d86c821b8d0bd6fb00b1e2ba25 Mon Sep 17 00:00:00 2001 From: Seth Alves Date: Thu, 30 Jun 2016 15:41:58 -0700 Subject: [PATCH] if an edit packet doesn't include a change to lifetime, don't attempt to cap the lifetime --- libraries/entities/src/EntityTree.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libraries/entities/src/EntityTree.cpp b/libraries/entities/src/EntityTree.cpp index 21e5865c09..ef0401ceaf 100644 --- a/libraries/entities/src/EntityTree.cpp +++ b/libraries/entities/src/EntityTree.cpp @@ -904,7 +904,9 @@ int EntityTree::processEditPacketData(ReceivedMessage& message, const unsigned c endDecode = usecTimestampNow(); const quint64 LAST_EDITED_SERVERSIDE_BUMP = 1; // usec - if (!senderNode->getCanRez() && senderNode->getCanRezTmp()) { + if ((message.getType() == PacketType::EntityAdd || + (message.getType() == PacketType::EntityEdit && properties.lifetimeChanged())) && + !senderNode->getCanRez() && senderNode->getCanRezTmp()) { // this node is only allowed to rez temporary entities. if need be, cap the lifetime. if (properties.getLifetime() == ENTITY_ITEM_IMMORTAL_LIFETIME || properties.getLifetime() > _maxTmpEntityLifetime) {