aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Spells
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2023-09-07 01:10:07 +0200
committerShauren <shauren.trinity@gmail.com>2023-09-07 01:10:07 +0200
commit8efeb202a500bda46283127f66fb85f6b91f9e76 (patch)
treec6c12b633d144d26927f615af4d3d64b07e62dcc /src/server/game/Spells
parent0bf5cf33c7dd909202ef492b69e317652e923f96 (diff)
Core: Update to 10.1.7
Diffstat (limited to 'src/server/game/Spells')
-rw-r--r--src/server/game/Spells/Auras/SpellAuraDefines.h2
-rw-r--r--src/server/game/Spells/Auras/SpellAuraEffects.cpp2
-rw-r--r--src/server/game/Spells/Spell.cpp11
-rw-r--r--src/server/game/Spells/Spell.h3
4 files changed, 10 insertions, 8 deletions
diff --git a/src/server/game/Spells/Auras/SpellAuraDefines.h b/src/server/game/Spells/Auras/SpellAuraDefines.h
index d1d552c368f..08a064b51eb 100644
--- a/src/server/game/Spells/Auras/SpellAuraDefines.h
+++ b/src/server/game/Spells/Auras/SpellAuraDefines.h
@@ -633,6 +633,8 @@ enum AuraType : uint32
SPELL_AURA_ALLOW_MOUNT_IN_COMBAT = 539,
SPELL_AURA_MOD_SUPPORT_STAT = 540, // NYI
SPELL_AURA_MOD_REQUIRED_MOUNT_CAPABILITY_FLAGS = 541,
+ SPELL_AURA_542 = 542,
+ SPELL_AURA_543 = 543,
TOTAL_AURAS
};
diff --git a/src/server/game/Spells/Auras/SpellAuraEffects.cpp b/src/server/game/Spells/Auras/SpellAuraEffects.cpp
index 6b008d36f06..9ad9cc23074 100644
--- a/src/server/game/Spells/Auras/SpellAuraEffects.cpp
+++ b/src/server/game/Spells/Auras/SpellAuraEffects.cpp
@@ -609,6 +609,8 @@ NonDefaultConstructible<pAuraEffectHandler> AuraEffectHandler[TOTAL_AURAS]=
&AuraEffect::HandleNoImmediateEffect, //539 SPELL_AURA_ALLOW_MOUNT_IN_COMBAT implemented in SpellInfo::CanBeUsedInCombat
&AuraEffect::HandleNULL, //540 SPELL_AURA_MOD_SUPPORT_STAT
&AuraEffect::HandleModRequiredMountCapabilityFlags, //541 SPELL_AURA_MOD_REQUIRED_MOUNT_CAPABILITY_FLAGS
+ &AuraEffect::HandleNULL, //542
+ &AuraEffect::HandleNULL, //543
};
AuraEffect::AuraEffect(Aura* base, SpellEffectInfo const& spellEfffectInfo, int32 const* baseAmount, Unit* caster) :
diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp
index 6e5fc130645..19a68fa341d 100644
--- a/src/server/game/Spells/Spell.cpp
+++ b/src/server/game/Spells/Spell.cpp
@@ -144,7 +144,7 @@ SpellCastTargets::SpellCastTargets(Unit* caster, WorldPackets::Spells::SpellCast
else
pos = &m_src._position;
- pos->Relocate(spellCastRequest.Target.SrcLocation->Location);
+ pos->Relocate(spellCastRequest.Target.SrcLocation->Location.Pos);
if (spellCastRequest.Target.Orientation)
pos->SetOrientation(*spellCastRequest.Target.Orientation);
}
@@ -158,7 +158,7 @@ SpellCastTargets::SpellCastTargets(Unit* caster, WorldPackets::Spells::SpellCast
else
pos = &m_dst._position;
- pos->Relocate(spellCastRequest.Target.DstLocation->Location);
+ pos->Relocate(spellCastRequest.Target.DstLocation->Location.Pos);
if (spellCastRequest.Target.Orientation)
pos->SetOrientation(*spellCastRequest.Target.Orientation);
}
@@ -4734,7 +4734,7 @@ void Spell::SendSpellStart()
}
if (castFlags & CAST_FLAG_PROJECTILE)
- UpdateSpellCastDataAmmo(castData.Ammo);
+ castData.AmmoDisplayID = GetSpellCastDataAmmo();
if (castFlags & CAST_FLAG_IMMUNITY)
{
@@ -4883,7 +4883,7 @@ void Spell::UpdateSpellCastDataTargets(WorldPackets::Spells::SpellCastData& data
m_channelTargetEffectMask = 0;
}
-void Spell::UpdateSpellCastDataAmmo(WorldPackets::Spells::SpellAmmo& ammo)
+int32 Spell::GetSpellCastDataAmmo()
{
uint32 ammoInventoryType = 0;
uint32 ammoDisplayID = 0;
@@ -4950,8 +4950,7 @@ void Spell::UpdateSpellCastDataAmmo(WorldPackets::Spells::SpellAmmo& ammo)
}
}
- ammo.DisplayID = ammoDisplayID;
- ammo.InventoryType = ammoInventoryType;
+ return ammoDisplayID;
}
void Spell::SendSpellExecuteLog()
diff --git a/src/server/game/Spells/Spell.h b/src/server/game/Spells/Spell.h
index 29f7b61fb62..3b3c37f4a80 100644
--- a/src/server/game/Spells/Spell.h
+++ b/src/server/game/Spells/Spell.h
@@ -32,7 +32,6 @@ namespace WorldPackets
{
namespace Spells
{
- struct SpellAmmo;
struct SpellCastData;
}
}
@@ -887,7 +886,7 @@ class TC_GAME_API Spell
void CalculateJumpSpeeds(SpellEffectInfo const* effInfo, float dist, float& speedXY, float& speedZ);
void UpdateSpellCastDataTargets(WorldPackets::Spells::SpellCastData& data);
- void UpdateSpellCastDataAmmo(WorldPackets::Spells::SpellAmmo& data);
+ int32 GetSpellCastDataAmmo();
SpellCastResult CanOpenLock(SpellEffectInfo const& effect, uint32 lockid, SkillType& skillid, int32& reqSkillValue, int32& skillValue);
// -------------------------------------------