mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-03 02:53:48 +00:00
Merge branch 'master' into Playerbot
This commit is contained in:
@@ -7772,7 +7772,12 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
|
||||
{
|
||||
if (!victim || !victim->IsAlive() || victim->HasSpellCooldown(20267))
|
||||
return false;
|
||||
// 2% of base mana
|
||||
|
||||
auto* caster = triggeredByAura->GetBase()->GetCaster();
|
||||
if (!caster || !victim->IsFriendlyTo(caster))
|
||||
return false;
|
||||
|
||||
// 2% of base health
|
||||
basepoints0 = int32(victim->CountPctFromMaxHealth(2));
|
||||
victim->CastCustomSpell(victim, 20267, &basepoints0, 0, 0, true, 0, triggeredByAura);
|
||||
victim->AddSpellCooldown(20267, 0, 4 * IN_MILLISECONDS);
|
||||
@@ -7784,6 +7789,10 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere
|
||||
if (!victim || !victim->IsAlive() || !victim->HasActivePowerType(POWER_MANA) || victim->HasSpellCooldown(20268))
|
||||
return false;
|
||||
|
||||
auto* caster = triggeredByAura->GetBase()->GetCaster();
|
||||
if (!caster || !victim->IsFriendlyTo(caster))
|
||||
return false;
|
||||
|
||||
// 2% of base mana
|
||||
basepoints0 = int32(CalculatePct(victim->GetCreateMana(), 2));
|
||||
victim->CastCustomSpell(victim, 20268, &basepoints0, nullptr, nullptr, true, 0, triggeredByAura);
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
#define ACORE_GRIDNOTIFIERSIMPL_H
|
||||
|
||||
#include "Corpse.h"
|
||||
#include "CreatureAI.h"
|
||||
#include "GridNotifiers.h"
|
||||
#include "Object.h"
|
||||
#include "Player.h"
|
||||
|
||||
@@ -29,15 +29,14 @@
|
||||
template<class T>
|
||||
RandomMovementGenerator<T>::~RandomMovementGenerator() { }
|
||||
|
||||
template<>
|
||||
RandomMovementGenerator<Creature>::~RandomMovementGenerator()
|
||||
{
|
||||
delete _pathGenerator;
|
||||
}
|
||||
template RandomMovementGenerator<Creature>::~RandomMovementGenerator();
|
||||
|
||||
template<>
|
||||
void RandomMovementGenerator<Creature>::_setRandomLocation(Creature* creature)
|
||||
{
|
||||
if (!creature)
|
||||
return;
|
||||
|
||||
if (creature->_moveState != MAP_OBJECT_CELL_MOVE_NONE)
|
||||
return;
|
||||
|
||||
@@ -135,7 +134,7 @@ void RandomMovementGenerator<Creature>::_setRandomLocation(Creature* creature)
|
||||
else // ground
|
||||
{
|
||||
if (!_pathGenerator)
|
||||
_pathGenerator = new PathGenerator(creature);
|
||||
_pathGenerator = std::make_unique<PathGenerator>(creature);
|
||||
else
|
||||
_pathGenerator->Clear();
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ private:
|
||||
TimeTrackerSmall _nextMoveTime;
|
||||
uint8 _moveCount;
|
||||
float _wanderDistance;
|
||||
PathGenerator* _pathGenerator;
|
||||
std::unique_ptr<PathGenerator> _pathGenerator;
|
||||
std::vector<G3D::Vector3> _destinationPoints;
|
||||
std::vector<uint8> _validPointsVector[RANDOM_POINTS_NUMBER + 1];
|
||||
uint8 _currentPoint;
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
#include "AllScriptsObjects.h"
|
||||
#include "InstanceScript.h"
|
||||
#include "LFGScripts.h"
|
||||
#include "ScriptObject.h"
|
||||
#include "ScriptSystem.h"
|
||||
#include "SmartAI.h"
|
||||
#include "SpellMgr.h"
|
||||
|
||||
@@ -1276,7 +1276,7 @@ void Aura::HandleAuraSpecificMods(AuraApplication const* aurApp, Unit* caster, b
|
||||
for (SpellAreaForAreaMap::const_iterator itr = saBounds.first; itr != saBounds.second; ++itr)
|
||||
{
|
||||
// some auras remove at aura remove
|
||||
if (!itr->second->IsFitToRequirements(target->ToPlayer(), zone, area))
|
||||
if (!itr->second->IsFitToRequirements(target->ToPlayer(), zone, area) && !apply)
|
||||
target->RemoveAurasDueToSpell(itr->second->spellId);
|
||||
// some auras applied at aura apply
|
||||
else if (itr->second->autocast)
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
#include "BattlegroundIC.h"
|
||||
#include "BattlegroundMgr.h"
|
||||
#include "BattlegroundSA.h"
|
||||
#include "BattlegroundWS.h"
|
||||
#include "CellImpl.h"
|
||||
#include "Chat.h"
|
||||
#include "Common.h"
|
||||
|
||||
@@ -4000,12 +4000,6 @@ void SpellMgr::LoadSpellInfoCorrections()
|
||||
spellInfo->Effects[EFFECT_0].TargetB = SpellImplicitTargetInfo();
|
||||
});
|
||||
|
||||
// Luffa
|
||||
ApplySpellFix({ 23595 }, [](SpellInfo* spellInfo)
|
||||
{
|
||||
spellInfo->Effects[EFFECT_0].BasePoints = 1; // Remove only 1 bleed effect
|
||||
});
|
||||
|
||||
// Eye of Kilrogg Passive (DND)
|
||||
ApplySpellFix({ 2585 }, [](SpellInfo* spellInfo)
|
||||
{
|
||||
@@ -4856,6 +4850,18 @@ void SpellMgr::LoadSpellInfoCorrections()
|
||||
spellInfo->AttributesEx3 |= SPELL_ATTR3_SUPPRESS_CASTER_PROCS;
|
||||
});
|
||||
|
||||
// Fury
|
||||
ApplySpellFix({ 40601 }, [](SpellInfo* spellInfo)
|
||||
{
|
||||
spellInfo->AttributesEx3 |= SPELL_ATTR3_SUPPRESS_CASTER_PROCS;
|
||||
});
|
||||
|
||||
// Black Qiraji Battle Tank
|
||||
ApplySpellFix({ 26655, 26656 }, [](SpellInfo* spellInfo)
|
||||
{
|
||||
spellInfo->AuraInterruptFlags &= ~(AURA_INTERRUPT_FLAG_CHANGE_MAP | AURA_INTERRUPT_FLAG_TELEPORTED);
|
||||
});
|
||||
|
||||
for (uint32 i = 0; i < GetSpellInfoStoreSize(); ++i)
|
||||
{
|
||||
SpellInfo* spellInfo = mSpellInfoMap[i];
|
||||
|
||||
@@ -25,7 +25,7 @@ bool _SpellScript::_Validate(SpellInfo const* entry)
|
||||
{
|
||||
if (!Validate(entry))
|
||||
{
|
||||
LOG_ERROR("scripts.spells", "_SpellScript::_Validate: Spell `{}` did not pass Validate() function of script `{}` - script will not be added to the spell", entry->Id, m_scriptName->c_str());
|
||||
LOG_ERROR("spells.scripts", "_SpellScript::_Validate: Spell `{}` did not pass Validate() function of script `{}` - script will not be added to the spell", entry->Id, m_scriptName->c_str());
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
@@ -35,7 +35,7 @@ bool _SpellScript::_ValidateSpellInfo(uint32 spellId)
|
||||
{
|
||||
if (!sSpellMgr->GetSpellInfo(spellId))
|
||||
{
|
||||
LOG_ERROR("scripts.spells", "_SpellScript::ValidateSpellInfo: Spell {} does not exist.", spellId);
|
||||
LOG_ERROR("spells.scripts", "_SpellScript::ValidateSpellInfo: Spell {} does not exist.", spellId);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -21,7 +21,6 @@
|
||||
#include "ObjectGuid.h"
|
||||
#include <map>
|
||||
#include <set>
|
||||
#include <string>
|
||||
|
||||
enum DumpTableType
|
||||
{
|
||||
|
||||
@@ -21,7 +21,6 @@
|
||||
#include "ARC4.h"
|
||||
#include "AuthDefines.h"
|
||||
#include "ByteBuffer.h"
|
||||
#include "WardenCheckMgr.h"
|
||||
#include "WardenPayloadMgr.h"
|
||||
#include <array>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user