Fix chest interaction and measure server RTT for latency meter

Chests (and lockboxes, coffers, etc.) failed to open because CMSG_LOOT
was only sent on Classic/Turtle expansions, and only when GO type was
already cached as type 3.  Fix: always send CMSG_LOOT after
CMSG_GAMEOBJ_USE (server silently ignores it for non-lootable objects).
Also broaden CMSG_GAMEOBJ_REPORT_USE to all non-mailbox WotLK GOs.

Latency meter: record pingTimestamp_ in sendPing() and compute RTT in
handlePong(); add toggleable "Show Latency Meter" checkbox in Interface
settings (saved to settings.cfg).
This commit is contained in:
Kelsi 2026-03-11 19:45:03 -07:00
parent 14f672ab6a
commit 711cb966ef
4 changed files with 42 additions and 16 deletions

View file

@ -1862,6 +1862,7 @@ private:
float timeSinceLastMoveHeartbeat_ = 0.0f; // Periodic movement heartbeat to keep server position synced
float moveHeartbeatInterval_ = 0.5f;
uint32_t lastLatency = 0; // Last measured latency (milliseconds)
std::chrono::steady_clock::time_point pingTimestamp_; // Time CMSG_PING was sent
// Player GUID and map
uint64_t playerGuid = 0;