Permalink
Browse files

[Cleanup] Remove tabs which have crept into the source

  • Loading branch information...
billy1arm committed Jan 10, 2019
1 parent befb584 commit 9389bd31535e021586593c6c4b2706af98dce389
@@ -2190,19 +2190,19 @@ void Pet::UpdateSpeed(UnitMoveType mtype, bool forced, float ratio)
return;
}

// Get owner current speed
float ownerSpeed = owner->GetSpeedRate(mtype);
int32 slow = owner->GetMaxNegativeAuraModifier(SPELL_AURA_MOD_DECREASE_SPEED);

// If owner is affected by speed reduction effects, do not take them into account
// (a dazed hunter does not affect pet's speed)
if (slow)
{ ownerSpeed *= 100.0f / (100.0f + slow); }
float speed = std::max(non_stack_bonus, stack_bonus) * ownerSpeed;
if (main_speed_mod)
speed = speed * (100.0f + main_speed_mod) / 100.0f;
// Get owner current speed
float ownerSpeed = owner->GetSpeedRate(mtype);
int32 slow = owner->GetMaxNegativeAuraModifier(SPELL_AURA_MOD_DECREASE_SPEED);

// If owner is affected by speed reduction effects, do not take them into account
// (a dazed hunter does not affect pet's speed)
if (slow)
{ ownerSpeed *= 100.0f / (100.0f + slow); }
float speed = std::max(non_stack_bonus, stack_bonus) * ownerSpeed;
if (main_speed_mod)
speed = speed * (100.0f + main_speed_mod) / 100.0f;

switch (mtype)
{
@@ -2227,7 +2227,7 @@ void Pet::UpdateSpeed(UnitMoveType mtype, bool forced, float ratio)
}

// Apply strongest slow aura mod to speed
slow = GetMaxNegativeAuraModifier(SPELL_AURA_MOD_DECREASE_SPEED);
slow = GetMaxNegativeAuraModifier(SPELL_AURA_MOD_DECREASE_SPEED);
if (slow)
{
speed *= (100.0f + slow) / 100.0f;
@@ -11046,8 +11046,8 @@ Item* Player::StoreNewItem(ItemPosCountVec const& dest, uint32 item, bool update
{
ItemAddedQuestCheck(item, count);
GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_RECEIVE_EPIC_ITEM, item, count);
GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_OWN_ITEM, item, count);
pItem = StoreItem(dest, pItem, update);
GetAchievementMgr().UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_OWN_ITEM, item, count);
pItem = StoreItem(dest, pItem, update);
}
return pItem;
}
@@ -19014,18 +19014,18 @@ bool Player::ActivateTaxiPathTo(std::vector<uint32> const& nodes, Creature* npc
// prevent stealth flight
RemoveSpellsCausingAura(SPELL_AURA_MOD_STEALTH);

if (sWorld.getConfig(CONFIG_BOOL_INSTANT_TAXI))
{
TaxiNodesEntry const* lastnode = sTaxiNodesStore.LookupEntry(nodes[nodes.size() - 1]);
m_taxi.ClearTaxiDestinations();
TeleportTo(lastnode->map_id, lastnode->x, lastnode->y, lastnode->z, GetOrientation());
return false;
}
else
{
GetSession()->SendActivateTaxiReply(ERR_TAXIOK);
GetSession()->SendDoFlight(mount_display_id, sourcepath);
}
if (sWorld.getConfig(CONFIG_BOOL_INSTANT_TAXI))
{
TaxiNodesEntry const* lastnode = sTaxiNodesStore.LookupEntry(nodes[nodes.size() - 1]);
m_taxi.ClearTaxiDestinations();
TeleportTo(lastnode->map_id, lastnode->x, lastnode->y, lastnode->z, GetOrientation());
return false;
}
else
{
GetSession()->SendActivateTaxiReply(ERR_TAXIOK);
GetSession()->SendDoFlight(mount_display_id, sourcepath);
}
return true;
}

@@ -8364,12 +8364,12 @@ bool Unit::IsVisibleForOrDetect(Unit const* u, WorldObject const* viewPoint, boo
if (u->GetTypeId() != TYPEID_PLAYER || !((Player*)u)->isGameMaster())
{ return false; }

// Death Knights in starting zones with Undying Resolve buff or
// in Acherus with Dominion Over Acherus buff - won't see opposite faction
if (u->GetTypeId() == TYPEID_PLAYER && GetTypeId() == TYPEID_PLAYER && !((Player*)u)->isGameMaster() &&
((Player*)u)->GetTeam() != ((Player*)this)->GetTeam() && (u->HasAura(51915) || u->HasAura(51721)))
return false;
// Death Knights in starting zones with Undying Resolve buff or
// in Acherus with Dominion Over Acherus buff - won't see opposite faction
if (u->GetTypeId() == TYPEID_PLAYER && GetTypeId() == TYPEID_PLAYER && !((Player*)u)->isGameMaster() &&
((Player*)u)->GetTeam() != ((Player*)this)->GetTeam() && (u->HasAura(51915) || u->HasAura(51721)))
return false;
// Visible units, always are visible for all units, except for units under invisibility and phases
if (m_Visibility == VISIBILITY_ON && u->m_invisibilityMask == 0)
{ return true; }
@@ -1291,18 +1291,18 @@ void AchievementMgr::UpdateAchievementCriteria(AchievementCriteriaTypes type, ui
break;
}
case ACHIEVEMENT_CRITERIA_TYPE_OWN_ITEM:
{
// speedup for non-login case
if (miscvalue1 && achievementCriteria->own_item.itemID != miscvalue1)
continue;
// check item count
if(!miscvalue2)
continue;

change = miscvalue2;
progressType = PROGRESS_ACCUMULATE;
break;
}
{
// speedup for non-login case
if (miscvalue1 && achievementCriteria->own_item.itemID != miscvalue1)
continue;
// check item count
if(!miscvalue2)
continue;

change = miscvalue2;
progressType = PROGRESS_ACCUMULATE;
break;
}
case ACHIEVEMENT_CRITERIA_TYPE_WIN_RATED_ARENA:
// miscvalue1 contains the personal rating
if (!miscvalue1) // no update at login
@@ -9182,10 +9182,10 @@ void SpellAuraHolder::_AddSpellAuraHolder()
// Faerie Fire (druid versions)
if (m_spellProto->IsFitToFamily(SPELLFAMILY_DRUID, UI64LIT(0x0000000000000400)))
m_target->ModifyAuraState(AURA_STATE_FAERIE_FIRE, true);
// Sting (hunter's pet ability)
if (m_spellProto->Category == 1133)
m_target->ModifyAuraState(AURA_STATE_FAERIE_FIRE, true);
if (m_spellProto->Category == 1133)
m_target->ModifyAuraState(AURA_STATE_FAERIE_FIRE, true);

// Victorious
if (m_spellProto->IsFitToFamily(SPELLFAMILY_WARRIOR, UI64LIT(0x0004000000000000)))
@@ -3001,7 +3001,7 @@ SpellAuraProcResult Unit::HandleProcTriggerSpellAuraProc(Unit* pVictim, uint32 d
// When your health drops below 35% ....
int32 health35 = int32(GetMaxHealth() * 35 / 100);
if (GetHealth() - damage > health35)
return SPELL_AURA_PROC_FAILED;
return SPELL_AURA_PROC_FAILED;

trigger_spell_id = 64569;

0 comments on commit 9389bd3

Please sign in to comment.