aboutsummaryrefslogtreecommitdiff
path: root/src/game/debugcmds.cpp
diff options
context:
space:
mode:
authormegamage <none@none>2009-01-04 16:37:14 -0600
committermegamage <none@none>2009-01-04 16:37:14 -0600
commit2d319dd5b41c12f50250c006cca66f0316b90dc2 (patch)
tree4f8a547fc3a2a567dae63a61bf8b020e8a8126fe /src/game/debugcmds.cpp
parenteb5a7b02eef6fe13684dfe14faf048bbce1d0f83 (diff)
*Mangos: replaced dynamic by static allocation in server packets header. Added command to test large packets. By arrai.
*Mangos: [7022] Added support for packets > 64 kb. By derex. --HG-- branch : trunk
Diffstat (limited to 'src/game/debugcmds.cpp')
-rw-r--r--src/game/debugcmds.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/game/debugcmds.cpp b/src/game/debugcmds.cpp
index 8ec580f0c9f..a02a3db1761 100644
--- a/src/game/debugcmds.cpp
+++ b/src/game/debugcmds.cpp
@@ -620,4 +620,14 @@ bool ChatHandler::HandleSpawnVehicle(const char* args)
map->Add((Creature*)v);
return true;
-} \ No newline at end of file
+}
+
+bool ChatHandler::HandleSendLargePacketCommand(const char* args)
+{
+ const char* stuffingString = "This is a dummy string to push the packet's size beyond 128000 bytes. ";
+ std::ostringstream ss;
+ while(strlen(ss.str().c_str()) < 128000)
+ ss << stuffingString;
+ SendSysMessage(ss.str().c_str());
+ return true;
+}