mirror of
https://github.com/overte-org/overte.git
synced 2025-07-28 21:50:24 +02:00
if an edit packet doesn't include a change to lifetime, don't attempt to cap the lifetime
This commit is contained in:
parent
7b0b56d793
commit
b9f9b18083
1 changed files with 3 additions and 1 deletions
|
@ -904,7 +904,9 @@ int EntityTree::processEditPacketData(ReceivedMessage& message, const unsigned c
|
||||||
endDecode = usecTimestampNow();
|
endDecode = usecTimestampNow();
|
||||||
|
|
||||||
const quint64 LAST_EDITED_SERVERSIDE_BUMP = 1; // usec
|
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.
|
// this node is only allowed to rez temporary entities. if need be, cap the lifetime.
|
||||||
if (properties.getLifetime() == ENTITY_ITEM_IMMORTAL_LIFETIME ||
|
if (properties.getLifetime() == ENTITY_ITEM_IMMORTAL_LIFETIME ||
|
||||||
properties.getLifetime() > _maxTmpEntityLifetime) {
|
properties.getLifetime() > _maxTmpEntityLifetime) {
|
||||||
|
|
Loading…
Reference in a new issue