mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 04:37:00 +00:00
[10688] New version of patch for send real diff from last update.
In new version last update time stopred for specific Cell that store all world objects placed in it. All objects of Cell updated (or not updated) in same time. Original version provided by ciphercom.
This commit is contained in:
parent
464908f453
commit
e219ee99bb
36 changed files with 183 additions and 151 deletions
|
|
@ -117,12 +117,20 @@ class MANGOS_DLL_DECL Grid
|
|||
return i_container.template remove<SPECIFIC_OBJECT>(obj);
|
||||
}
|
||||
|
||||
uint32 SetLastUpdateTimeAndReturnDiff(uint32 newtime)
|
||||
{
|
||||
uint32 realdiff = getMSTimeDiff(m_LastUpdateTime,newtime);
|
||||
m_LastUpdateTime = newtime;
|
||||
return realdiff;
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
TypeMapContainer<GRID_OBJECT_TYPES> i_container;
|
||||
TypeMapContainer<WORLD_OBJECT_TYPES> i_objects;
|
||||
typedef std::set<void*> ActiveGridObjects;
|
||||
ActiveGridObjects m_activeGridObjects;
|
||||
uint32 m_LastUpdateTime; // last time when Update call has been or current started, used and set Map::Update
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue