Core: Update to 10.1
Port From (https://github.com/TrinityCore/TrinityCore/commit/16bc74667e8996b64258718e95b97258dfc0217a)
This commit is contained in:
@@ -718,6 +718,9 @@ namespace Game.Networking.Packets
|
||||
|
||||
if (MmrChange.HasValue)
|
||||
data.WriteInt32(MmrChange.Value);
|
||||
|
||||
if (PostMatchMMR.HasValue)
|
||||
data.WriteUInt32(PostMatchMMR.Value);
|
||||
}
|
||||
|
||||
public ObjectGuid PlayerGUID;
|
||||
@@ -731,6 +734,7 @@ namespace Game.Networking.Packets
|
||||
public int? RatingChange;
|
||||
public uint? PreMatchMMR;
|
||||
public int? MmrChange;
|
||||
public uint? PostMatchMMR;
|
||||
public List<PVPMatchPlayerPVPStat> Stats = new();
|
||||
public int PrimaryTalentTree;
|
||||
public int Sex;
|
||||
|
||||
@@ -216,12 +216,12 @@ namespace Game.Networking.Packets
|
||||
public override void Read()
|
||||
{
|
||||
PetGuid = _worldPacket.ReadPackedGuid();
|
||||
Flags = _worldPacket.ReadUInt32();
|
||||
Flags = _worldPacket.ReadUInt16();
|
||||
ControlType = (FlagsControlType)_worldPacket.ReadBits<byte>(2);
|
||||
}
|
||||
|
||||
public ObjectGuid PetGuid;
|
||||
public uint Flags;
|
||||
public ushort Flags;
|
||||
public FlagsControlType ControlType;
|
||||
}
|
||||
|
||||
|
||||
@@ -224,7 +224,7 @@ namespace Game.Networking.Packets
|
||||
public byte RaceId;
|
||||
public Class ClassId;
|
||||
public byte SexId;
|
||||
public Array<ChrCustomizationChoice> Customizations = new(72);
|
||||
public Array<ChrCustomizationChoice> Customizations = new(125);
|
||||
public byte ExperienceLevel;
|
||||
public uint ZoneId;
|
||||
public uint MapId;
|
||||
@@ -566,7 +566,7 @@ namespace Game.Networking.Packets
|
||||
public string Name;
|
||||
public byte SexID;
|
||||
public byte RaceID;
|
||||
public Array<ChrCustomizationChoice> Customizations = new(72);
|
||||
public Array<ChrCustomizationChoice> Customizations = new(125);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -878,7 +878,7 @@ namespace Game.Networking.Packets
|
||||
}
|
||||
|
||||
public byte NewSex;
|
||||
public Array<ChrCustomizationChoice> Customizations = new(72);
|
||||
public Array<ChrCustomizationChoice> Customizations = new(125);
|
||||
public int CustomizedRace;
|
||||
}
|
||||
|
||||
@@ -1028,7 +1028,7 @@ namespace Game.Networking.Packets
|
||||
ObjectGuid CharGUID;
|
||||
string CharName = "";
|
||||
byte SexID;
|
||||
Array<ChrCustomizationChoice> Customizations = new(72);
|
||||
Array<ChrCustomizationChoice> Customizations = new(125);
|
||||
}
|
||||
|
||||
class CharCustomizeFailure : ServerPacket
|
||||
@@ -1090,7 +1090,7 @@ namespace Game.Networking.Packets
|
||||
public Race RaceId = Race.None;
|
||||
public Class ClassId = Class.None;
|
||||
public Gender Sex = Gender.None;
|
||||
public Array<ChrCustomizationChoice> Customizations = new(72);
|
||||
public Array<ChrCustomizationChoice> Customizations = new(125);
|
||||
public uint? TemplateSet;
|
||||
public bool IsTrialBoost;
|
||||
public bool UseNPE;
|
||||
@@ -1111,7 +1111,7 @@ namespace Game.Networking.Packets
|
||||
public ObjectGuid CharGUID;
|
||||
public Gender SexID = Gender.None;
|
||||
public string CharName;
|
||||
public Array<ChrCustomizationChoice> Customizations = new(72);
|
||||
public Array<ChrCustomizationChoice> Customizations = new(125);
|
||||
}
|
||||
|
||||
public class CharRaceOrFactionChangeInfo
|
||||
@@ -1122,7 +1122,7 @@ namespace Game.Networking.Packets
|
||||
public ObjectGuid Guid;
|
||||
public bool FactionChange;
|
||||
public string Name;
|
||||
public Array<ChrCustomizationChoice> Customizations = new(72);
|
||||
public Array<ChrCustomizationChoice> Customizations = new(125);
|
||||
}
|
||||
|
||||
public class CharacterUndeleteInfo
|
||||
|
||||
@@ -12,17 +12,30 @@ namespace Game.Networking.Packets
|
||||
{
|
||||
public class ChatMessage : ClientPacket
|
||||
{
|
||||
public string Text;
|
||||
public Language Language = Language.Universal;
|
||||
public bool IsSecure = true;
|
||||
|
||||
public ChatMessage(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Language = (Language)_worldPacket.ReadInt32();
|
||||
uint len = _worldPacket.ReadBits<uint>(11);
|
||||
switch (GetOpcode())
|
||||
{
|
||||
case ClientOpcodes.ChatMessageSay:
|
||||
case ClientOpcodes.ChatMessageParty:
|
||||
case ClientOpcodes.ChatMessageRaid:
|
||||
case ClientOpcodes.ChatMessageRaidWarning:
|
||||
case ClientOpcodes.ChatMessageInstanceChat:
|
||||
IsSecure = _worldPacket.HasBit();
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
Text = _worldPacket.ReadString(len);
|
||||
}
|
||||
|
||||
public string Text;
|
||||
public Language Language = Language.Universal;
|
||||
}
|
||||
|
||||
public class ChatMessageWhisper : ClientPacket
|
||||
@@ -45,6 +58,12 @@ namespace Game.Networking.Packets
|
||||
|
||||
public class ChatMessageChannel : ClientPacket
|
||||
{
|
||||
public Language Language = Language.Universal;
|
||||
public ObjectGuid ChannelGUID;
|
||||
public string Text;
|
||||
public string Target;
|
||||
public bool? IsSecure;
|
||||
|
||||
public ChatMessageChannel(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
@@ -53,14 +72,12 @@ namespace Game.Networking.Packets
|
||||
ChannelGUID = _worldPacket.ReadPackedGuid();
|
||||
uint targetLen = _worldPacket.ReadBits<uint>(9);
|
||||
uint textLen = _worldPacket.ReadBits<uint>(11);
|
||||
if (_worldPacket.HasBit())
|
||||
IsSecure = _worldPacket.HasBit();
|
||||
|
||||
Target = _worldPacket.ReadString(targetLen);
|
||||
Text = _worldPacket.ReadString(textLen);
|
||||
}
|
||||
|
||||
public Language Language = Language.Universal;
|
||||
public ObjectGuid ChannelGUID;
|
||||
public string Text;
|
||||
public string Target;
|
||||
}
|
||||
|
||||
public class ChatAddonMessage : ClientPacket
|
||||
@@ -143,7 +160,6 @@ namespace Game.Networking.Packets
|
||||
SenderGUID.Clear();
|
||||
SenderAccountGUID.Clear();
|
||||
SenderGuildGUID.Clear();
|
||||
PartyGUID.Clear();
|
||||
TargetGUID.Clear();
|
||||
SenderName = "";
|
||||
TargetName = "";
|
||||
@@ -181,10 +197,6 @@ namespace Game.Networking.Packets
|
||||
_ChatFlags = playerSender.GetChatFlags();
|
||||
|
||||
SenderGuildGUID = ObjectGuid.Create(HighGuid.Guild, playerSender.GetGuildId());
|
||||
|
||||
Group group = playerSender.GetGroup();
|
||||
if (group)
|
||||
PartyGUID = group.GetGUID();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -207,15 +219,15 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WritePackedGuid(TargetGUID);
|
||||
_worldPacket.WriteUInt32(TargetVirtualAddress);
|
||||
_worldPacket.WriteUInt32(SenderVirtualAddress);
|
||||
_worldPacket.WritePackedGuid(PartyGUID);
|
||||
_worldPacket.WriteUInt32(AchievementID);
|
||||
_worldPacket.WriteFloat(DisplayTime);
|
||||
_worldPacket.WriteUInt32(SpellID);
|
||||
_worldPacket.WriteBits(SenderName.GetByteCount(), 11);
|
||||
_worldPacket.WriteBits(TargetName.GetByteCount(), 11);
|
||||
_worldPacket.WriteBits(Prefix.GetByteCount(), 5);
|
||||
_worldPacket.WriteBits(Channel.GetByteCount(), 7);
|
||||
_worldPacket.WriteBits(ChatText.GetByteCount(), 12);
|
||||
_worldPacket.WriteBits((byte)_ChatFlags, 15);
|
||||
_worldPacket.WriteBits((ushort)_ChatFlags, 15);
|
||||
_worldPacket.WriteBit(HideChatLog);
|
||||
_worldPacket.WriteBit(FakeSenderName);
|
||||
_worldPacket.WriteBit(Unused_801.HasValue);
|
||||
@@ -241,7 +253,6 @@ namespace Game.Networking.Packets
|
||||
public ObjectGuid SenderGuildGUID;
|
||||
public ObjectGuid SenderAccountGUID;
|
||||
public ObjectGuid TargetGUID;
|
||||
public ObjectGuid PartyGUID;
|
||||
public uint SenderVirtualAddress;
|
||||
public uint TargetVirtualAddress;
|
||||
public string SenderName = "";
|
||||
@@ -252,6 +263,7 @@ namespace Game.Networking.Packets
|
||||
public uint AchievementID;
|
||||
public ChatFlags _ChatFlags;
|
||||
public float DisplayTime;
|
||||
public uint SpellID;
|
||||
public uint? Unused_801;
|
||||
public bool HideChatLog;
|
||||
public bool FakeSenderName;
|
||||
|
||||
@@ -551,7 +551,7 @@ namespace Game.Networking.Packets
|
||||
attackRoundInfo.WriteInt8(ContentTuning.TargetScalingLevelDelta);
|
||||
attackRoundInfo.WriteFloat(ContentTuning.PlayerItemLevel);
|
||||
attackRoundInfo.WriteFloat(ContentTuning.TargetItemLevel);
|
||||
attackRoundInfo.WriteUInt16(ContentTuning.ScalingHealthItemLevelCurveID);
|
||||
attackRoundInfo.WriteUInt32(ContentTuning.ScalingHealthItemLevelCurveID);
|
||||
attackRoundInfo.WriteUInt32((uint)ContentTuning.Flags);
|
||||
attackRoundInfo.WriteUInt32(ContentTuning.PlayerContentTuningID);
|
||||
attackRoundInfo.WriteUInt32(ContentTuning.TargetContentTuningID);
|
||||
|
||||
@@ -259,6 +259,15 @@ namespace Game.Networking.Packets
|
||||
|
||||
class StartLootRoll : ServerPacket
|
||||
{
|
||||
public ObjectGuid LootObj;
|
||||
public int MapID;
|
||||
public uint RollTime;
|
||||
public LootMethod Method;
|
||||
public RollMask ValidRolls;
|
||||
public Array<LootRollIneligibilityReason> LootRollIneligibleReason = new Array<LootRollIneligibilityReason>(4);
|
||||
public LootItemData Item = new();
|
||||
public uint DungeonEncounterID;
|
||||
|
||||
public StartLootRoll() : base(ServerOpcodes.StartLootRoll) { }
|
||||
|
||||
public override void Write()
|
||||
@@ -271,20 +280,22 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteUInt32((uint)reason);
|
||||
|
||||
_worldPacket.WriteUInt8((byte)Method);
|
||||
_worldPacket.WriteUInt32(DungeonEncounterID);
|
||||
Item.Write(_worldPacket);
|
||||
}
|
||||
|
||||
public ObjectGuid LootObj;
|
||||
public int MapID;
|
||||
public uint RollTime;
|
||||
public LootMethod Method;
|
||||
public RollMask ValidRolls;
|
||||
public Array<LootRollIneligibilityReason> LootRollIneligibleReason = new Array<LootRollIneligibilityReason>(4);
|
||||
public LootItemData Item = new();
|
||||
}
|
||||
|
||||
class LootRollBroadcast : ServerPacket
|
||||
{
|
||||
public ObjectGuid LootObj;
|
||||
public ObjectGuid Player;
|
||||
public int Roll; // Roll value can be negative, it means that it is an "offspec" roll but only during roll selection broadcast (not when sending the result)
|
||||
public RollVote RollType;
|
||||
public LootItemData Item = new();
|
||||
public bool Autopassed; // Triggers message |HlootHistory:%d|h[Loot]|h: You automatically passed on: %s because you cannot loot that item.
|
||||
public bool OffSpec;
|
||||
public uint DungeonEncounterID;
|
||||
|
||||
public LootRollBroadcast() : base(ServerOpcodes.LootRoll) { }
|
||||
|
||||
public override void Write()
|
||||
@@ -293,21 +304,24 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WritePackedGuid(Player);
|
||||
_worldPacket.WriteInt32(Roll);
|
||||
_worldPacket.WriteUInt8((byte)RollType);
|
||||
_worldPacket.WriteUInt32(DungeonEncounterID);
|
||||
Item.Write(_worldPacket);
|
||||
_worldPacket.WriteBit(Autopassed);
|
||||
_worldPacket.WriteBit(OffSpec);
|
||||
_worldPacket.FlushBits();
|
||||
}
|
||||
|
||||
public ObjectGuid LootObj;
|
||||
public ObjectGuid Player;
|
||||
public int Roll; // Roll value can be negative, it means that it is an "offspec" roll but only during roll selection broadcast (not when sending the result)
|
||||
public RollVote RollType;
|
||||
public LootItemData Item = new();
|
||||
public bool Autopassed; // Triggers message |HlootHistory:%d|h[Loot]|h: You automatically passed on: %s because you cannot loot that item.
|
||||
}
|
||||
|
||||
class LootRollWon : ServerPacket
|
||||
{
|
||||
public ObjectGuid LootObj;
|
||||
public ObjectGuid Winner;
|
||||
public int Roll;
|
||||
public RollVote RollType;
|
||||
public LootItemData Item = new();
|
||||
public bool MainSpec;
|
||||
public uint DungeonEncounterID;
|
||||
|
||||
public LootRollWon() : base(ServerOpcodes.LootRollWon) { }
|
||||
|
||||
public override void Write()
|
||||
@@ -316,45 +330,43 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WritePackedGuid(Winner);
|
||||
_worldPacket.WriteInt32(Roll);
|
||||
_worldPacket.WriteUInt8((byte)RollType);
|
||||
_worldPacket.WriteUInt32(DungeonEncounterID);
|
||||
Item.Write(_worldPacket);
|
||||
_worldPacket.WriteBit(MainSpec);
|
||||
_worldPacket.FlushBits();
|
||||
}
|
||||
|
||||
public ObjectGuid LootObj;
|
||||
public ObjectGuid Winner;
|
||||
public int Roll;
|
||||
public RollVote RollType;
|
||||
public LootItemData Item = new();
|
||||
public bool MainSpec;
|
||||
}
|
||||
|
||||
class LootAllPassed : ServerPacket
|
||||
{
|
||||
public ObjectGuid LootObj;
|
||||
public LootItemData Item = new();
|
||||
public uint DungeonEncounterID;
|
||||
|
||||
public LootAllPassed() : base(ServerOpcodes.LootAllPassed) { }
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WritePackedGuid(LootObj);
|
||||
_worldPacket.WriteUInt32(DungeonEncounterID);
|
||||
Item.Write(_worldPacket);
|
||||
}
|
||||
|
||||
public ObjectGuid LootObj;
|
||||
public LootItemData Item = new();
|
||||
}
|
||||
|
||||
class LootRollsComplete : ServerPacket
|
||||
{
|
||||
public ObjectGuid LootObj;
|
||||
public byte LootListID;
|
||||
public int DungeonEncounterID;
|
||||
|
||||
public LootRollsComplete() : base(ServerOpcodes.LootRollsComplete) { }
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WritePackedGuid(LootObj);
|
||||
_worldPacket.WriteUInt8(LootListID);
|
||||
_worldPacket.WriteInt32(DungeonEncounterID);
|
||||
}
|
||||
|
||||
public ObjectGuid LootObj;
|
||||
public byte LootListID;
|
||||
}
|
||||
|
||||
class MasterLootCandidateList : ServerPacket
|
||||
|
||||
@@ -106,7 +106,8 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteBit(QuantityGainSource.HasValue);
|
||||
_worldPacket.WriteBit(QuantityLostSource.HasValue);
|
||||
_worldPacket.WriteBit(FirstCraftOperationID.HasValue);
|
||||
_worldPacket.WriteBit(LastSpendTime.HasValue);
|
||||
_worldPacket.WriteBit(NextRechargeTime.HasValue);
|
||||
_worldPacket.WriteBit(RechargeCycleStartTime.HasValue);
|
||||
_worldPacket.FlushBits();
|
||||
|
||||
if (WeeklyQuantity.HasValue)
|
||||
@@ -133,8 +134,11 @@ namespace Game.Networking.Packets
|
||||
if (FirstCraftOperationID.HasValue)
|
||||
_worldPacket.WriteUInt32(FirstCraftOperationID.Value);
|
||||
|
||||
if (LastSpendTime.HasValue)
|
||||
_worldPacket.WriteInt64(LastSpendTime.Value);
|
||||
if (NextRechargeTime.HasValue)
|
||||
_worldPacket.WriteInt64(NextRechargeTime.Value);
|
||||
|
||||
if (RechargeCycleStartTime.HasValue)
|
||||
_worldPacket.WriteInt64(RechargeCycleStartTime.Value);
|
||||
}
|
||||
|
||||
public uint Type;
|
||||
@@ -149,7 +153,8 @@ namespace Game.Networking.Packets
|
||||
public CurrencyGainSource? QuantityGainSource;
|
||||
public CurrencyDestroyReason? QuantityLostSource;
|
||||
public uint? FirstCraftOperationID;
|
||||
public long? LastSpendTime;
|
||||
public long? NextRechargeTime;
|
||||
public long? RechargeCycleStartTime;
|
||||
public bool SuppressChatLog;
|
||||
}
|
||||
|
||||
@@ -197,7 +202,8 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteBit(data.TrackedQuantity.HasValue);
|
||||
_worldPacket.WriteBit(data.MaxQuantity.HasValue);
|
||||
_worldPacket.WriteBit(data.TotalEarned.HasValue);
|
||||
_worldPacket.WriteBit(data.LastSpendTime.HasValue);
|
||||
_worldPacket.WriteBit(data.NextRechargeTime.HasValue);
|
||||
_worldPacket.WriteBit(data.RechargeCycleStartTime.HasValue);
|
||||
_worldPacket.WriteBits(data.Flags, 5);
|
||||
_worldPacket.FlushBits();
|
||||
|
||||
@@ -211,8 +217,10 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteInt32(data.MaxQuantity.Value);
|
||||
if (data.TotalEarned.HasValue)
|
||||
_worldPacket.WriteInt32(data.TotalEarned.Value);
|
||||
if (data.LastSpendTime.HasValue)
|
||||
_worldPacket.WriteInt64(data.LastSpendTime.Value);
|
||||
if (data.NextRechargeTime.HasValue)
|
||||
_worldPacket.WriteInt64(data.NextRechargeTime.Value);
|
||||
if (data.RechargeCycleStartTime.HasValue)
|
||||
_worldPacket.WriteInt64(data.RechargeCycleStartTime.Value);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -227,7 +235,8 @@ namespace Game.Networking.Packets
|
||||
public uint? TrackedQuantity;
|
||||
public int? MaxQuantity;
|
||||
public int? TotalEarned;
|
||||
public long? LastSpendTime;
|
||||
public long? NextRechargeTime;
|
||||
public long? RechargeCycleStartTime;
|
||||
public byte Flags;
|
||||
}
|
||||
}
|
||||
@@ -1387,10 +1396,10 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteBit(IsFullUpdate);
|
||||
_worldPacket.WriteInt32(Mounts.Count);
|
||||
|
||||
foreach (var spell in Mounts)
|
||||
foreach (var (spellId, flags) in Mounts)
|
||||
{
|
||||
_worldPacket.WriteUInt32(spell.Key);
|
||||
_worldPacket.WriteBits(spell.Value, 2);
|
||||
_worldPacket.WriteUInt32(spellId);
|
||||
_worldPacket.WriteBits(flags, 4);
|
||||
}
|
||||
|
||||
_worldPacket.FlushBits();
|
||||
|
||||
@@ -83,8 +83,7 @@ namespace Game.Networking.Packets
|
||||
data.ReadPackedGuid();
|
||||
}
|
||||
|
||||
// ResetBitReader
|
||||
|
||||
bool hasStandingOnGameObjectGUID = data.HasBit();
|
||||
bool hasTransport = data.HasBit();
|
||||
bool hasFall = data.HasBit();
|
||||
bool hasSpline = data.HasBit(); // todo 6.x read this infos
|
||||
@@ -97,6 +96,9 @@ namespace Game.Networking.Packets
|
||||
if (hasTransport)
|
||||
ReadTransportInfo(data, ref movementInfo.transport);
|
||||
|
||||
if (hasStandingOnGameObjectGUID)
|
||||
movementInfo.standingOnGameObjectGUID = data.ReadPackedGuid();
|
||||
|
||||
if (hasInertia)
|
||||
{
|
||||
MovementInfo.Inertia inertia = new();
|
||||
@@ -143,6 +145,7 @@ namespace Game.Networking.Packets
|
||||
bool hasSpline = false; // todo 6.x send this infos
|
||||
bool hasInertia = movementInfo.inertia.HasValue;
|
||||
bool hasAdvFlying = movementInfo.advFlying.HasValue;
|
||||
bool hasStandingOnGameObjectGUID = movementInfo.standingOnGameObjectGUID.HasValue;
|
||||
|
||||
data.WritePackedGuid(movementInfo.Guid);
|
||||
data.WriteUInt32((uint)movementInfo.GetMovementFlags());
|
||||
@@ -167,6 +170,7 @@ namespace Game.Networking.Packets
|
||||
_worldPacket << ObjectGuid;
|
||||
}*/
|
||||
|
||||
data.WriteBit(hasStandingOnGameObjectGUID);
|
||||
data.WriteBit(hasTransportData);
|
||||
data.WriteBit(hasFallData);
|
||||
data.WriteBit(hasSpline);
|
||||
@@ -179,6 +183,9 @@ namespace Game.Networking.Packets
|
||||
if (hasTransportData)
|
||||
WriteTransportInfo(data, movementInfo.transport);
|
||||
|
||||
if (hasStandingOnGameObjectGUID)
|
||||
data.WritePackedGuid(movementInfo.standingOnGameObjectGUID.Value);
|
||||
|
||||
if (hasInertia)
|
||||
{
|
||||
data.WriteInt32(movementInfo.inertia.Value.id);
|
||||
|
||||
@@ -61,18 +61,11 @@ namespace Game.Networking.Packets
|
||||
public override void Read() { }
|
||||
}
|
||||
|
||||
public class RequestCategoryCooldowns : ClientPacket
|
||||
{
|
||||
public RequestCategoryCooldowns(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read() { }
|
||||
}
|
||||
|
||||
public class SpellCategoryCooldown : ServerPacket
|
||||
{
|
||||
public List<CategoryCooldownInfo> CategoryCooldowns = new();
|
||||
|
||||
public SpellCategoryCooldown() : base(ServerOpcodes.CategoryCooldown, ConnectionType.Instance) { }
|
||||
public SpellCategoryCooldown() : base(ServerOpcodes.SpellCategoryCooldown, ConnectionType.Instance) { }
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
@@ -1337,7 +1330,7 @@ namespace Game.Networking.Packets
|
||||
data.WriteFloat(PlayerItemLevel);
|
||||
data.WriteFloat(TargetItemLevel);
|
||||
data.WriteInt16(PlayerLevelDelta);
|
||||
data.WriteUInt16(ScalingHealthItemLevelCurveID);
|
||||
data.WriteUInt32(ScalingHealthItemLevelCurveID);
|
||||
data.WriteUInt8(TargetLevel);
|
||||
data.WriteUInt8(Expansion);
|
||||
data.WriteInt8(TargetScalingLevelDelta);
|
||||
@@ -1353,7 +1346,7 @@ namespace Game.Networking.Packets
|
||||
public short PlayerLevelDelta;
|
||||
public float PlayerItemLevel;
|
||||
public float TargetItemLevel;
|
||||
public ushort ScalingHealthItemLevelCurveID;
|
||||
public uint ScalingHealthItemLevelCurveID;
|
||||
public byte TargetLevel;
|
||||
public byte Expansion;
|
||||
public sbyte TargetScalingLevelDelta;
|
||||
@@ -1641,7 +1634,8 @@ namespace Game.Networking.Packets
|
||||
public MissileTrajectoryRequest MissileTrajectory;
|
||||
public MovementInfo MoveUpdate;
|
||||
public List<SpellWeight> Weight = new();
|
||||
public Array<SpellCraftingReagent> OptionalReagents = new(3);
|
||||
public Array<SpellCraftingReagent> OptionalReagents = new(6);
|
||||
public Array<SpellCraftingReagent> RemovedModifications = new(6);
|
||||
public Array<SpellExtraCurrencyCost> OptionalCurrencies = new(5 /*MAX_ITEM_EXT_COST_CURRENCIES*/);
|
||||
public ulong? CraftingOrderID;
|
||||
public ObjectGuid CraftingNPC;
|
||||
@@ -1659,10 +1653,11 @@ namespace Game.Networking.Packets
|
||||
MissileTrajectory.Read(data);
|
||||
CraftingNPC = data.ReadPackedGuid();
|
||||
|
||||
var optionalCurrencies = data.ReadUInt32();
|
||||
var optionalReagents = data.ReadUInt32();
|
||||
var optionalCurrenciesCount = data.ReadUInt32();
|
||||
var optionalReagentsCount = data.ReadUInt32();
|
||||
var removedModificationsCount = data.ReadUInt32();
|
||||
|
||||
for (var i = 0; i < optionalCurrencies; ++i)
|
||||
for (var i = 0; i < optionalCurrenciesCount; ++i)
|
||||
OptionalCurrencies[i].Read(data);
|
||||
|
||||
SendCastFlags = data.ReadBits<uint>(5);
|
||||
@@ -1675,9 +1670,12 @@ namespace Game.Networking.Packets
|
||||
if (hasCraftingOrderID)
|
||||
CraftingOrderID = data.ReadUInt64();
|
||||
|
||||
for (var i = 0; i < optionalReagents; ++i)
|
||||
for (var i = 0; i < optionalReagentsCount; ++i)
|
||||
OptionalReagents[i].Read(data);
|
||||
|
||||
for (var i = 0; i < removedModificationsCount; ++i)
|
||||
RemovedModifications[i].Read(data);
|
||||
|
||||
if (hasMoveUpdate)
|
||||
MoveUpdate = MovementExtensions.ReadMovementInfo(data);
|
||||
|
||||
|
||||
@@ -43,8 +43,8 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteBit(WindowInfo.HasValue);
|
||||
_worldPacket.FlushBits();
|
||||
|
||||
_worldPacket.WriteInt32(CanLandNodes.Length);
|
||||
_worldPacket.WriteInt32(CanUseNodes.Length);
|
||||
_worldPacket.WriteInt32(CanLandNodes.Length / 8); // client reads this in uint64 blocks, size is ensured to be divisible by 8 in TaxiMask constructor
|
||||
_worldPacket.WriteInt32(CanUseNodes.Length / 8); // client reads this in uint64 blocks, size is ensured to be divisible by 8 in TaxiMask constructor
|
||||
|
||||
if (WindowInfo.HasValue)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user