mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-23 02:25:38 +01:00
[7980] Implement item use target requirements store and check (new table item_required_target). Author: NoFantasy
Signed-off-by: VladimirMangos <vladimir@getmangos.com> * Also implement this table reload * Static Spell::SendCastResult function for call not from spell code. Can be also used in scripts where need send explicitly spell cast error to client. --HG-- branch : trunk
This commit is contained in:
@@ -286,19 +286,7 @@ void WorldSession::HandlePetActionHelper(Unit *pet, uint64 guid1, uint16 spellid
|
||||
else
|
||||
{
|
||||
if(pet->isPossessed())
|
||||
{
|
||||
WorldPacket data(SMSG_CAST_FAILED, (4+1+1));
|
||||
data << uint8(0) << uint32(spellid) << uint8(result);
|
||||
switch (result)
|
||||
{
|
||||
case SPELL_FAILED_REQUIRES_SPELL_FOCUS:
|
||||
data << uint32(spellInfo->RequiresSpellFocus);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
SendPacket(&data);
|
||||
}
|
||||
Spell::SendCastResult(GetPlayer(),spellInfo,0,result);
|
||||
else
|
||||
pet->SendPetCastFail(spellid, result);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user