mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-22 23:30:14 +00:00
tbc: fix quest log stride and CMSG_QUESTGIVER_QUERY_QUEST format
TBC 2.4.3 quest log update fields use 4 fields per slot (questId, state, counts, timer) vs WotLK's 5 (extra counts field). The wrong stride (5) caused all quest log reads to use wrong indices beyond the first slot, breaking quest tracking on TBC servers. TBC 2.4.3 CMSG_QUESTGIVER_QUERY_QUEST is guid(8) + questId(4) = 12 bytes. WotLK added a trailing isDialogContinued(u8) byte that TBC servers don't expect; sending it caused quest details to not be sent back on some emulators.
This commit is contained in:
parent
8f0d2cc4ab
commit
d5de031c23
2 changed files with 20 additions and 0 deletions
|
|
@ -345,6 +345,12 @@ public:
|
|||
bool parseSpellDamageLog(network::Packet& packet, SpellDamageLogData& data) override;
|
||||
// TBC 2.4.3 SMSG_SPELLHEALLOG uses full uint64 GUIDs (WotLK uses packed GUIDs)
|
||||
bool parseSpellHealLog(network::Packet& packet, SpellHealLogData& data) override;
|
||||
// TBC 2.4.3 quest log has 4 update fields per slot (questId, state, counts, timer)
|
||||
// WotLK expands this to 5 (splits counts into two fields).
|
||||
uint8_t questLogStride() const override { return 4; }
|
||||
// TBC 2.4.3 CMSG_QUESTGIVER_QUERY_QUEST: guid(8) + questId(4) — no trailing
|
||||
// isDialogContinued byte that WotLK added
|
||||
network::Packet buildQueryQuestPacket(uint64_t npcGuid, uint32_t questId) override;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -698,6 +698,20 @@ network::Packet TbcPacketParsers::buildAcceptQuestPacket(uint64_t npcGuid, uint3
|
|||
return packet;
|
||||
}
|
||||
|
||||
// ============================================================================
|
||||
// TBC 2.4.3 CMSG_QUESTGIVER_QUERY_QUEST
|
||||
//
|
||||
// WotLK adds a trailing uint8 isDialogContinued byte; TBC does not.
|
||||
// TBC format: guid(8) + questId(4) = 12 bytes.
|
||||
// ============================================================================
|
||||
network::Packet TbcPacketParsers::buildQueryQuestPacket(uint64_t npcGuid, uint32_t questId) {
|
||||
network::Packet packet(wireOpcode(Opcode::CMSG_QUESTGIVER_QUERY_QUEST));
|
||||
packet.writeUInt64(npcGuid);
|
||||
packet.writeUInt32(questId);
|
||||
// No isDialogContinued byte (WotLK-only addition)
|
||||
return packet;
|
||||
}
|
||||
|
||||
// ============================================================================
|
||||
// TBC parseAuraUpdate - SMSG_AURA_UPDATE doesn't exist in TBC
|
||||
// TBC uses inline aura update fields + SMSG_INIT_EXTRA_AURA_INFO_OBSOLETE (0x3A3) /
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue