aboutsummaryrefslogtreecommitdiff
path: root/src/server/game/Spells/Spell.cpp
diff options
context:
space:
mode:
authorWarpten <vertozor@gmail.com>2016-06-03 09:27:27 +0200
committerWarpten <vertozor@gmail.com>2016-06-03 09:27:27 +0200
commit12f029d442ecc2c89c4e4c37120db786f74b2e4f (patch)
tree6d6bdc5842b21bebc65eb9bf807d451ac66a79cc /src/server/game/Spells/Spell.cpp
parentc631656fb8c751e65cce6b880bee8f213e07ac98 (diff)
Core/PacketIO: Implemented new Cast HighGuid type and fix some mistakes with SMSG_MOVE_UPDATE_APPLY_MOVEMENT_FORCE
Core/Updatefields: Health is now stored as an unsigned long int.
Diffstat (limited to 'src/server/game/Spells/Spell.cpp')
-rw-r--r--src/server/game/Spells/Spell.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp
index 4a166351fe5..84cfabf4e8f 100644
--- a/src/server/game/Spells/Spell.cpp
+++ b/src/server/game/Spells/Spell.cpp
@@ -589,7 +589,7 @@ m_spellValue(new SpellValue(caster->GetMap()->GetDifficultyID(), m_spellInfo)),
m_procVictim = 0;
m_procEx = 0;
focusObject = NULL;
- m_cast_count = 0;
+ m_cast_count = ObjectGuid::Empty;
memset(m_misc.Raw.Data, 0, sizeof(m_misc.Raw.Data));
m_SpellVisual = m_spellInfo->GetSpellXSpellVisualId(caster->GetMap()->GetDifficultyID());
m_preCastSpell = 0;
@@ -2925,7 +2925,7 @@ void Spell::prepare(SpellCastTargets const* targets, AuraEffect const* triggered
m_caster->m_Events.AddEvent(Event, m_caster->m_Events.CalculateTime(1));
//Prevent casting at cast another spell (ServerSide check)
- if (!(_triggeredCastFlags & TRIGGERED_IGNORE_CAST_IN_PROGRESS) && m_caster->IsNonMeleeSpellCast(false, true, true) && m_cast_count)
+ if (!(_triggeredCastFlags & TRIGGERED_IGNORE_CAST_IN_PROGRESS) && m_caster->IsNonMeleeSpellCast(false, true, true) && !m_cast_count.IsEmpty())
{
SendCastResult(SPELL_FAILED_SPELL_IN_PROGRESS);
finish(false);
@@ -3742,7 +3742,7 @@ void Spell::SendPetCastResult(SpellCastResult result)
SendCastResult(owner->ToPlayer(), m_spellInfo, m_cast_count, result, SPELL_CUSTOM_ERROR_NONE, SMSG_PET_CAST_FAILED, m_misc.Raw.Data);
}
-void Spell::SendCastResult(Player* caster, SpellInfo const* spellInfo, uint8 cast_count, SpellCastResult result, SpellCustomErrors customError /*= SPELL_CUSTOM_ERROR_NONE*/, OpcodeServer opcode /*= SMSG_CAST_FAILED*/, uint32* misc /*= nullptr*/)
+void Spell::SendCastResult(Player* caster, SpellInfo const* spellInfo, ObjectGuid cast_count, SpellCastResult result, SpellCustomErrors customError /*= SPELL_CUSTOM_ERROR_NONE*/, OpcodeServer opcode /*= SMSG_CAST_FAILED*/, uint32* misc /*= nullptr*/)
{
if (result == SPELL_CAST_OK)
return;