mirror of
https://github.com/mangosfour/server.git
synced 2025-12-28 04:37:04 +00:00
Merge branch 'master' into 303
This commit is contained in:
commit
ed77adf964
3 changed files with 13 additions and 4 deletions
|
|
@ -573,12 +573,21 @@ void Map::Update(const uint32 &t_diff)
|
|||
// for pets
|
||||
TypeContainerVisitor<MaNGOS::ObjectUpdater, WorldTypeMapContainer > world_object_update(updater);
|
||||
|
||||
for(MapRefManager::iterator iter = m_mapRefManager.begin(); iter != m_mapRefManager.end(); ++iter)
|
||||
//TODO: Player guard
|
||||
HashMapHolder<Player>::MapType& playerMap = HashMapHolder<Player>::GetContainer();
|
||||
for(HashMapHolder<Player>::MapType::iterator iter = playerMap.begin(); iter != playerMap.end(); ++iter)
|
||||
{
|
||||
Player* plr = iter->getSource();
|
||||
Player* plr = iter->second;
|
||||
|
||||
if(!plr->IsInWorld())
|
||||
continue;
|
||||
|
||||
if(plr->GetMapId() != GetId())
|
||||
continue;
|
||||
|
||||
if(plr->GetInstanceId() != GetInstanceId())
|
||||
continue;
|
||||
|
||||
CellPair standing_cell(MaNGOS::ComputeCellPair(plr->GetPositionX(), plr->GetPositionY()));
|
||||
|
||||
// Check for correctness of standing_cell, it also avoids problems with update_cell
|
||||
|
|
|
|||
|
|
@ -810,7 +810,7 @@ bool Pet::InitStatsForLevel(uint32 petlevel)
|
|||
SetFloatValue(UNIT_MOD_CAST_SPEED, 1.0);
|
||||
|
||||
CreatureFamilyEntry const* cFamily = sCreatureFamilyStore.LookupEntry(cinfo->family);
|
||||
if(cFamily && cFamily->minScale > 0.0f)
|
||||
if(cFamily && cFamily->minScale > 0.0f && getPetType()==HUNTER_PET)
|
||||
{
|
||||
float scale;
|
||||
if (getLevel() >= cFamily->maxScaleLevel)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue