Core/Misc: Some random cleanups

This commit is contained in:
tobmaps
2011-06-09 19:41:13 +07:00
parent 93c329658d
commit 60470e4bd8
3 changed files with 4 additions and 7 deletions
+1 -1
View File
@@ -1513,7 +1513,7 @@ void Player::Update(uint32 p_time)
// If this is set during update SetSpellModTakingSpell call is missing somewhere in the code // If this is set during update SetSpellModTakingSpell call is missing somewhere in the code
// Having this would prevent more aura charges to be dropped, so let's crash // Having this would prevent more aura charges to be dropped, so let's crash
//ASSERT (!m_spellModTakingSpell); //ASSERT (!m_spellModTakingSpell);
if ( m_spellModTakingSpell) if (m_spellModTakingSpell)
{ {
//sLog->outCrash("Player has m_pad %u during update!", m_pad); //sLog->outCrash("Player has m_pad %u during update!", m_pad);
//if (m_spellModTakingSpell) //if (m_spellModTakingSpell)
@@ -188,7 +188,7 @@ void SocialMgr::GetFriendInfo(Player *player, uint32 friendGUID, FriendInfo &fri
uint32 team = player->GetTeam(); uint32 team = player->GetTeam();
AccountTypes security = player->GetSession()->GetSecurity(); AccountTypes security = player->GetSession()->GetSecurity();
bool allowTwoSideWhoList = sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_WHO_LIST); bool allowTwoSideWhoList = sWorld->getBoolConfig(CONFIG_ALLOW_TWO_SIDE_WHO_LIST);
AccountTypes gmLevelInWhoList = AccountTypes (sWorld->getIntConfig(CONFIG_GM_LEVEL_IN_WHO_LIST)); AccountTypes gmLevelInWhoList = AccountTypes(sWorld->getIntConfig(CONFIG_GM_LEVEL_IN_WHO_LIST));
PlayerSocialMap::iterator itr = player->GetSocial()->m_playerSocialMap.find(friendGUID); PlayerSocialMap::iterator itr = player->GetSocial()->m_playerSocialMap.find(friendGUID);
if (itr != player->GetSocial()->m_playerSocialMap.end()) if (itr != player->GetSocial()->m_playerSocialMap.end())
@@ -126,11 +126,8 @@ class boss_void_reaver : public CreatureScript
pTarget = Unit::GetUnit(*me, (*itr)->getUnitGuid()); pTarget = Unit::GetUnit(*me, (*itr)->getUnitGuid());
if (!pTarget) if (!pTarget)
continue; continue;
// exclude pets & totems // exclude pets & totems, 18 yard radius minimum
if (pTarget->GetTypeId() != TYPEID_PLAYER) if (pTarget->GetTypeId() == TYPEID_PLAYER && pTarget->isAlive() && !pTarget->IsWithinDist(me, 18, false))
continue;
//18 yard radius minimum
if (pTarget && pTarget->GetTypeId() == TYPEID_PLAYER && pTarget->isAlive() && !pTarget->IsWithinDist(me, 18, false))
target_list.push_back(pTarget); target_list.push_back(pTarget);
pTarget = NULL; pTarget = NULL;
} }