Core/PacketIO: Fixed structure for SMSG_DISPLAY_TOAST

Port From (https://github.com/TrinityCore/TrinityCore/commit/63cad8f18206c7403af9e5ed40209e814913b5e0)
This commit is contained in:
Hondacrx
2025-08-17 23:09:42 -04:00
parent e8a430a178
commit 7b57778f14
@@ -1358,15 +1358,16 @@ namespace Game.Networking.Packets
class DisplayToast : ServerPacket class DisplayToast : ServerPacket
{ {
public ulong Quantity; public ulong Quantity;
public uint QuestID;
public DisplayToastMethod DisplayToastMethod; public DisplayToastMethod DisplayToastMethod;
public bool Mailed; public bool Mailed;
public DisplayToastType Type = DisplayToastType.Money; public DisplayToastType Type = DisplayToastType.Money;
public uint QuestID;
public bool IsSecondaryResult; public bool IsSecondaryResult;
public ItemInstance Item; public ItemInstance Item;
public bool BonusRoll;
public int LootSpec; public int LootSpec;
public Gender Gender = Gender.None; public Gender Gender = Gender.None;
public bool BonusRoll;
public bool ForceToast; // Ignores ITEM_FLAG3_DO_NOT_TOAST
public uint CurrencyID; public uint CurrencyID;
public DisplayToast() : base(ServerOpcodes.DisplayToast, ConnectionType.Instance) { } public DisplayToast() : base(ServerOpcodes.DisplayToast, ConnectionType.Instance) { }
@@ -1385,6 +1386,7 @@ namespace Game.Networking.Packets
{ {
case DisplayToastType.NewItem: case DisplayToastType.NewItem:
_worldPacket.WriteBit(BonusRoll); _worldPacket.WriteBit(BonusRoll);
_worldPacket.WriteBit(ForceToast);
Item.Write(_worldPacket); Item.Write(_worldPacket);
_worldPacket.WriteInt32(LootSpec); _worldPacket.WriteInt32(LootSpec);
_worldPacket.WriteInt8((sbyte)Gender); _worldPacket.WriteInt8((sbyte)Gender);