[Server] Print debug info only for certain world packets

0.6.1
David Cernat 8 years ago
parent 417284c701
commit 89a8ace41c

@ -38,8 +38,6 @@ bool WorldProcessor::Process(RakNet::Packet &packet, BaseEvent &event) noexcept
Player *player = Players::getPlayer(packet.guid);
WorldPacket *myPacket = Networking::get().getWorldController()->GetPacket(packet.data[0]);
LOG_MESSAGE_SIMPLE(Log::LOG_VERBOSE, "Received %s from %s", processor.second->strPacketID.c_str(),
player->npc.mName.c_str());
myPacket->setEvent(&event);
if (!processor.second->avoidReading)

@ -15,6 +15,8 @@ namespace mwmp
void Do(WorldPacket &packet, Player &player, BaseEvent &event) override
{
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received %s from %s", strPacketID.c_str(), player.npc.mName.c_str());
// Send only to players who have the cell loaded
Cell *serverCell = CellController::get()->getCell(&event.cell);

@ -19,6 +19,7 @@ namespace mwmp
void Do(WorldPacket &packet, Player &player, BaseEvent &event) override
{
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received %s from %s", strPacketID.c_str(), player.npc.mName.c_str());
LOG_APPEND(Log::LOG_INFO, "- action: %i", event.action);
// Until we have a timestamp-based system, send packets pertaining to more

@ -19,6 +19,8 @@ namespace mwmp
void Do(WorldPacket &packet, Player &player, BaseEvent &event) override
{
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received %s from %s", strPacketID.c_str(), player.npc.mName.c_str());
packet.Send(true);
Script::Call<Script::CallbackIdentity("OnObjectDelete")>(player.getId(), event.cell.getDescription().c_str());

@ -19,6 +19,8 @@ namespace mwmp
void Do(WorldPacket &packet, Player &player, BaseEvent &event) override
{
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received %s from %s", strPacketID.c_str(), player.npc.mName.c_str());
packet.Send(true);
Script::Call<Script::CallbackIdentity("OnObjectLock")>(player.getId(), event.cell.getDescription().c_str());

@ -20,6 +20,8 @@ namespace mwmp
void Do(WorldPacket &packet, Player &player, BaseEvent &event) override
{
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received %s from %s", strPacketID.c_str(), player.npc.mName.c_str());
for (unsigned int i = 0; i < event.objectChanges.count; i++)
{
event.objectChanges.objects.at(i).mpNum = mwmp::Networking::getPtr()->incrementMpNum();

@ -19,6 +19,8 @@ namespace mwmp
void Do(WorldPacket &packet, Player &player, BaseEvent &event) override
{
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received %s from %s", strPacketID.c_str(), player.npc.mName.c_str());
packet.Send(true);
Script::Call<Script::CallbackIdentity("OnObjectScale")>(player.getId(), event.cell.getDescription().c_str());

@ -19,6 +19,8 @@ namespace mwmp
void Do(WorldPacket &packet, Player &player, BaseEvent &event) override
{
LOG_MESSAGE_SIMPLE(Log::LOG_INFO, "Received %s from %s", strPacketID.c_str(), player.npc.mName.c_str());
packet.Send(true);
Script::Call<Script::CallbackIdentity("OnObjectUnlock")>(player.getId(), event.cell.getDescription().c_str());

Loading…
Cancel
Save