mirror of
https://github.com/mangosfour/server.git
synced 2025-12-12 10:37:03 +00:00
[9146] More poolmgr cleanps.
* Replace mixed values used type args by function template specializations * More explcilty show fact that poolmgr work only with db guids.
This commit is contained in:
parent
edfec630e8
commit
4d90a2e1f2
7 changed files with 134 additions and 85 deletions
|
|
@ -375,9 +375,9 @@ void Creature::Update(uint32 diff)
|
|||
//Call AI respawn virtual function
|
||||
i_AI->JustRespawned();
|
||||
|
||||
uint16 poolid = sPoolMgr.IsPartOfAPool(GetGUIDLow(), GetTypeId());
|
||||
uint16 poolid = GetDBTableGUIDLow() ? sPoolMgr.IsPartOfAPool<Creature>(GetDBTableGUIDLow()) : 0;
|
||||
if (poolid)
|
||||
sPoolMgr.UpdatePool(poolid, GetGUIDLow(), TYPEID_UNIT);
|
||||
sPoolMgr.UpdatePool<Creature>(poolid, GetDBTableGUIDLow());
|
||||
else
|
||||
GetMap()->Add(this);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue