From 4d828a1b1305ab88dab5f6cb04b303d71cc88e40 Mon Sep 17 00:00:00 2001 From: MayaTheShy Date: Sat, 8 Nov 2025 18:21:15 -0500 Subject: [PATCH] feat: add debug output for protocol version signature computation in NLPacket --- src/NLPacketCodec.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/NLPacketCodec.cpp b/src/NLPacketCodec.cpp index 2787060..d91408c 100644 --- a/src/NLPacketCodec.cpp +++ b/src/NLPacketCodec.cpp @@ -8,6 +8,7 @@ #include #include #include +#include namespace Overte { @@ -467,11 +468,19 @@ std::vector NLPacket::computeProtocolVersionSignature() { uint8_t numPacketTypes = static_cast(numPacketTypesInt); buffer.push_back(numPacketTypes); + // Debug: print version table + std::cout << "[OverteClient] Computing protocol signature with " << (int)numPacketTypes << " packet types:" << std::endl; + // Write version for each packet type for (uint8_t i = 0; i < numPacketTypes; i++) { PacketType type = static_cast(i); uint8_t version = versionForPacketType(type); buffer.push_back(version); + if (i < 20 || i >= numPacketTypes - 10) { // Print first 20 and last 10 + std::cout << " Type " << (int)i << ": version " << (int)version << std::endl; + } else if (i == 20) { + std::cout << " ... (middle entries omitted) ..." << std::endl; + } } // Compute MD5 hash