further decode merc packets

This commit is contained in:
wish
2023-01-29 12:22:07 +11:00
parent 753d215211
commit 1382e99fc6
3 changed files with 15 additions and 9 deletions

View File

@@ -13,7 +13,7 @@ type MsgMhfContractMercenary struct {
AckHandle uint32
PactMercID uint32
CID uint32
Unk bool
Cancel bool
}
// Opcode returns the ID associated with this packet type.
@@ -26,7 +26,7 @@ func (m *MsgMhfContractMercenary) Parse(bf *byteframe.ByteFrame, ctx *clientctx.
m.AckHandle = bf.ReadUint32()
m.PactMercID = bf.ReadUint32()
m.CID = bf.ReadUint32()
m.Unk = bf.ReadBool()
m.Cancel = bf.ReadBool()
return nil
}

View File

@@ -11,7 +11,7 @@ import (
// MsgMhfReadMercenaryW represents the MSG_MHF_READ_MERCENARY_W
type MsgMhfReadMercenaryW struct {
AckHandle uint32
GetPact bool
Op uint8
Unk1 uint8
Unk2 uint16 // Hardcoded 0 in the binary
}
@@ -24,7 +24,7 @@ func (m *MsgMhfReadMercenaryW) Opcode() network.PacketID {
// Parse parses the packet from binary
func (m *MsgMhfReadMercenaryW) Parse(bf *byteframe.ByteFrame, ctx *clientctx.ClientContext) error {
m.AckHandle = bf.ReadUint32()
m.GetPact = bf.ReadBool()
m.Op = bf.ReadUint8()
m.Unk1 = bf.ReadUint8()
m.Unk2 = bf.ReadUint16()
return nil