Core/Packets: converted SMSG_PET_ACTION_FEEDBACK to packet class and added spellId argument to Unit::SendPetActionFeedback

This commit is contained in:
Ovahlord committed 2022-12-11 20:03:57 +01:00
1 parent ec97df6528
commit 92c9661804
4 files changed
+36 -5

No files matched your search

@@ -16,6 +16,7 @@
*/
#include "PetPackets.h"
#include "PetDefines.h"
WorldPacket const* WorldPackets::Pet::PetDismissSound::Write()
{
@@ -41,3 +42,20 @@ WorldPacket const* WorldPackets::Pet::SPetMode::Write()
return &_worldPacket;
}
WorldPacket const* WorldPackets::Pet::PetActionFeedback::Write()
{
_worldPacket << uint8(Response);
switch (Response)
{
case FEEDBACK_NOTHING_TO_ATT:
case FEEDBACK_CANT_ATT_TARGET:
_worldPacket << int32(SpellID);
break;
default:
break;
}
return &_worldPacket;
}