diff options
| author | QAston <qaston@gmail.com> | 2012-02-16 12:06:14 +0100 |
|---|---|---|
| committer | QAston <qaston@gmail.com> | 2012-02-16 12:09:09 +0100 |
| commit | ad6613261cb3a9561faf96a5bcbed72cedde2d16 (patch) | |
| tree | ba8160ccdc241339cbbaca7fc063b1ecaa039a32 /src/server/game/Handlers/SpellHandler.cpp | |
| parent | d336c9efc5dfbfa93e8e79e01f55e8abe14820d0 (diff) | |
Core/Db/Conditions: Drop usage of CONDITION_ITEM_TARGET and CONDITION_SOURCE_TYPE_ITEM_REQUIRED_TARGET and use CONDITION_SOURCE_TYPE_SPELL instead.
Diffstat (limited to 'src/server/game/Handlers/SpellHandler.cpp')
| -rwxr-xr-x | src/server/game/Handlers/SpellHandler.cpp | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/src/server/game/Handlers/SpellHandler.cpp b/src/server/game/Handlers/SpellHandler.cpp index b8908d0f9f9..9ea0e124112 100755 --- a/src/server/game/Handlers/SpellHandler.cpp +++ b/src/server/game/Handlers/SpellHandler.cpp @@ -165,24 +165,6 @@ void WorldSession::HandleUseItemOpcode(WorldPacket& recvPacket) targets.Read(recvPacket, pUser); HandleClientCastFlags(recvPacket, castFlags, targets); - if (!pItem->IsTargetValidForItemUse(targets.GetUnitTarget())) - { - // free gray item after use fail - pUser->SendEquipError(EQUIP_ERR_NONE, pItem, NULL); - - // send spell error - if (SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellId)) - { - // for implicit area/coord target spells - if (!targets.GetUnitTarget()) - Spell::SendCastResult(_player, spellInfo, castCount, SPELL_FAILED_NO_VALID_TARGETS); - // for explicit target spells - else - Spell::SendCastResult(_player, spellInfo, castCount, SPELL_FAILED_BAD_TARGETS); - } - return; - } - // Note: If script stop casting it must send appropriate data to client to prevent stuck item in gray state. if (!sScriptMgr->OnItemUse(pUser, pItem, targets)) { |
