aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorjoschiwald <joschiwald.trinity@gmail.com>2018-08-25 20:13:19 +0200
committerjoschiwald <joschiwald.trinity@gmail.com>2018-08-25 20:13:19 +0200
commit5132547ab315375f6ac4324b25f9344e68e87fd9 (patch)
tree31c3310d9de308ccc81bef17632d8ac651cc41a1 /src
parent74022357cce4e8143855a48c17b8df8e4801975a (diff)
Scripts/Command: Use packet builder in .debug send channelnotify
Diffstat (limited to 'src')
-rw-r--r--src/server/scripts/Commands/cs_debug.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/server/scripts/Commands/cs_debug.cpp b/src/server/scripts/Commands/cs_debug.cpp
index be216e79d94..f146c1ca27b 100644
--- a/src/server/scripts/Commands/cs_debug.cpp
+++ b/src/server/scripts/Commands/cs_debug.cpp
@@ -27,6 +27,7 @@ EndScriptData */
#include "BattlefieldMgr.h"
#include "BattlegroundMgr.h"
#include "CellImpl.h"
+#include "ChannelPackets.h"
#include "Chat.h"
#include "ChatPackets.h"
#include "Conversation.h"
@@ -479,12 +480,10 @@ public:
char const* name = "test";
uint8 code = atoi(args);
- WorldPacket data(SMSG_CHANNEL_NOTIFY, (1+10));
- data << code; // notify type
- data << name; // channel name
- data << uint32(0);
- data << uint32(0);
- handler->GetSession()->SendPacket(&data);
+ WorldPackets::Channel::ChannelNotify channelNotify = WorldPackets::Channel::ChannelNotify();
+ channelNotify.Type = code;
+ channelNotify._Channel = name;
+ handler->GetSession()->SendPacket(channelNotify.Write());
return true;
}