Core/Objects: Rewritten UpdateMask class to perform bit operations faster at the cost of higher memory use and moved building the mask for packet to a separate method.

Closes #9127
This commit is contained in:
Shauren
2013-02-09 23:59:09 +01:00
parent e5e970baec
commit 38eb090e9a
2 changed files with 67 additions and 67 deletions

View File

@@ -509,7 +509,7 @@ void Object::_BuildValuesUpdate(uint8 updatetype, ByteBuffer * data, UpdateMask*
WPAssert(updateMask && updateMask->GetCount() == m_valuesCount);
*data << (uint8)updateMask->GetBlockCount();
data->append(updateMask->GetMask(), updateMask->GetLength());
updateMask->AppendToPacket(data);
// 2 specialized loops for speed optimization in non-unit case
if (isType(TYPEMASK_UNIT)) // unit (creature/player) case