WorldPacket packet; packet.Initialize(SMSG_POWER_UPDATE); packet << uint32(500); // add a uint32 value to the packet
WorldPacket packet; packet.Initialize(SMSG_UPDATE_OBJECT); packet << ObjectGuid(playerGUID) << uint8(0) << uint32(0);This code initializes a WorldPacket object with the SMSG_UPDATE_OBJECT op code and adds an ObjectGuid, a uint8 value of 0, and a uint32 value of 0 to the packet. It is difficult to determine the package library from just these code examples, as WorldPacket is a data structure that is used in many different WoW emulation projects with different package libraries.