mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Value copy / allocation optimizations mostly in server, SAO and serialize code
This commit is contained in:
parent
2fd5f38c45
commit
471e567657
16 changed files with 52 additions and 64 deletions
|
@ -1603,14 +1603,14 @@ void ServerEnvironment::setStaticForActiveObjectsInBlock(
|
|||
}
|
||||
}
|
||||
|
||||
ActiveObjectMessage ServerEnvironment::getActiveObjectMessage()
|
||||
bool ServerEnvironment::getActiveObjectMessage(ActiveObjectMessage *dest)
|
||||
{
|
||||
if(m_active_object_messages.empty())
|
||||
return ActiveObjectMessage(0);
|
||||
return false;
|
||||
|
||||
ActiveObjectMessage message = m_active_object_messages.front();
|
||||
*dest = std::move(m_active_object_messages.front());
|
||||
m_active_object_messages.pop();
|
||||
return message;
|
||||
return true;
|
||||
}
|
||||
|
||||
void ServerEnvironment::getSelectedActiveObjects(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue