mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-01-17 10:55:43 +00:00
Revert "Build/Clang: fixed 96 warnings + improved code readability"
This reverts commit a4589f71d5.
This commit is contained in:
@@ -4190,8 +4190,8 @@ void Player::removeSpell(uint32 spellId, uint8 removeSpecMask, bool onlyTemporar
|
||||
continue;
|
||||
|
||||
// pussywizard: don't understand why whole skill is removed when just single spell from it is removed
|
||||
if ((_spell_idx->second->learnOnGetSkill == ABILITY_LEARNED_ON_GET_RACE_OR_CLASS_SKILL && pSkill->categoryId != SKILL_CATEGORY_CLASS) || // pussywizard: don't unlearn class skills
|
||||
((pSkill->id == SKILL_LOCKPICKING || pSkill->id == SKILL_RUNEFORGING) && _spell_idx->second->max_value == 0))
|
||||
if (_spell_idx->second->learnOnGetSkill == ABILITY_LEARNED_ON_GET_RACE_OR_CLASS_SKILL && pSkill->categoryId != SKILL_CATEGORY_CLASS || // pussywizard: don't unlearn class skills
|
||||
(pSkill->id == SKILL_LOCKPICKING || pSkill->id == SKILL_RUNEFORGING) && _spell_idx->second->max_value == 0)
|
||||
{
|
||||
// not reset skills for professions and racial abilities
|
||||
if ((pSkill->categoryId == SKILL_CATEGORY_SECONDARY || pSkill->categoryId == SKILL_CATEGORY_PROFESSION) && (IsProfessionSkill(pSkill->id) || _spell_idx->second->racemask != 0))
|
||||
@@ -17486,8 +17486,7 @@ bool Player::LoadFromDB(uint32 guid, SQLQueryHolder *holder)
|
||||
MapEntry const* mapEntry = sMapStore.LookupEntry(mapId);
|
||||
|
||||
// pussywizard: group changed difficulty when player was offline, teleport to the enterance of new difficulty
|
||||
if (mapEntry && ((mapEntry->IsNonRaidDungeon() && dungeonDiff != GetDungeonDifficulty()) ||
|
||||
(mapEntry->IsRaid() && raidDiff != GetRaidDifficulty())))
|
||||
if (mapEntry && (mapEntry->IsNonRaidDungeon() && dungeonDiff != GetDungeonDifficulty() || mapEntry->IsRaid() && raidDiff != GetRaidDifficulty()))
|
||||
{
|
||||
bool fixed = false;
|
||||
if (uint32 destInstId = sInstanceSaveMgr->PlayerGetDestinationInstanceId(this, mapId, GetDifficulty(mapEntry->IsRaid())))
|
||||
@@ -22833,9 +22832,7 @@ void Player::ApplyEquipCooldown(Item* pItem)
|
||||
|
||||
// xinef: dont apply equip cooldown if spell on item has insignificant cooldown
|
||||
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellData.SpellId);
|
||||
if (spellData.SpellCooldown <= 3000 &&
|
||||
spellData.SpellCategoryCooldown <= 3000 &&
|
||||
(!spellInfo || (spellInfo->RecoveryTime <= 3000 && spellInfo->CategoryRecoveryTime <= 3000)))
|
||||
if (spellData.SpellCooldown <= 3000 && spellData.SpellCategoryCooldown <= 3000 && (!spellInfo || spellInfo->RecoveryTime <= 3000 && spellInfo->CategoryRecoveryTime <= 3000))
|
||||
continue;
|
||||
|
||||
// Don't replace longer cooldowns by equip cooldown if we have any.
|
||||
@@ -26366,10 +26363,7 @@ uint8 Player::GetMostPointsTalentTree() const
|
||||
bool Player::IsHealerTalentSpec() const
|
||||
{
|
||||
uint8 tree = GetMostPointsTalentTree();
|
||||
return ((getClass() == CLASS_DRUID && tree == 2) ||
|
||||
(getClass() == CLASS_PALADIN && tree == 0) ||
|
||||
(getClass() == CLASS_PRIEST && tree <= 1) ||
|
||||
(getClass() == CLASS_SHAMAN && tree == 2));
|
||||
return (getClass() == CLASS_DRUID && tree == 2 || getClass() == CLASS_PALADIN && tree == 0 || getClass() == CLASS_PRIEST && tree <= 1 || getClass() == CLASS_SHAMAN && tree == 2);
|
||||
}
|
||||
|
||||
void Player::ResetTimeSync()
|
||||
|
||||
Reference in New Issue
Block a user