using WowPacketParser.Misc; using WowPacketParser.Enums; byte[] packetData = // packet data buffer int offset = // offset to GUID value in buffer GuidType guidType = GuidType.Player; // type of GUID we're reading Guid playerGuid = Packet.ReadGuid(packetData, offset, guidType);
using WowPacketParser.Misc; using WowPacketParser.Enums; byte[] packetData = // packet data buffer int offset = // offset to GUID value in buffer GuidType guidType = GuidType.Object; // type of GUID we're reading Guid objectGuid = Packet.ReadGuid(packetData, offset, guidType);This example reads the GUID value for an object (such as an NPC or game item) from the packet data buffer. The `guidType` parameter tells the method to expect an object GUID value. The result is a `Guid` object containing the object's GUID value. The Packet ReadGuid method is part of the WowPacketParser library, which is an open source library for parsing and analyzing WoW packets. It can be found on Github at https://github.com/quasd/WowPacketParser.