Core: Updated to 11.2.0
Port From (https://github.com/TrinityCore/TrinityCore/commit/5cf0c6c8bb2c4e58a2d66ba5f304af34d18a4782)
This commit is contained in:
@@ -48,37 +48,6 @@ namespace Game.Networking.Packets
|
||||
public override void Write() { }
|
||||
}
|
||||
|
||||
class AreaTriggerRePath : ServerPacket
|
||||
{
|
||||
public AreaTriggerRePath() : base(ServerOpcodes.AreaTriggerRePath) { }
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WritePackedGuid(TriggerGUID);
|
||||
_worldPacket.WritePackedGuid(Unused_1100);
|
||||
|
||||
_worldPacket.WriteBit(AreaTriggerSpline != null);
|
||||
_worldPacket.WriteBit(AreaTriggerOrbit != null);
|
||||
_worldPacket.WriteBit(AreaTriggerMovementScript.HasValue);
|
||||
_worldPacket.FlushBits();
|
||||
|
||||
if (AreaTriggerSpline != null)
|
||||
AreaTriggerSpline.Write(_worldPacket);
|
||||
|
||||
if (AreaTriggerMovementScript.HasValue)
|
||||
AreaTriggerMovementScript.Value.Write(_worldPacket);
|
||||
|
||||
if (AreaTriggerOrbit != null)
|
||||
AreaTriggerOrbit.Write(_worldPacket);
|
||||
}
|
||||
|
||||
public AreaTriggerSplineInfo AreaTriggerSpline;
|
||||
public AreaTriggerOrbitInfo AreaTriggerOrbit;
|
||||
public AreaTriggerMovementScriptInfo? AreaTriggerMovementScript;
|
||||
public ObjectGuid TriggerGUID;
|
||||
public ObjectGuid Unused_1100;
|
||||
}
|
||||
|
||||
class AreaTriggerPlaySpellVisual : ServerPacket
|
||||
{
|
||||
public ObjectGuid AreaTriggerGUID;
|
||||
@@ -108,31 +77,4 @@ namespace Game.Networking.Packets
|
||||
TargetGUID = _worldPacket.ReadPackedGuid();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//Structs
|
||||
class AreaTriggerSplineInfo
|
||||
{
|
||||
public static void WriteAreaTriggerSpline(WorldPacket data, uint timeToTarget, uint elapsedTimeForMovement, Spline<float> areaTriggerSpline)
|
||||
{
|
||||
data.WriteUInt32(timeToTarget);
|
||||
data.WriteUInt32(elapsedTimeForMovement);
|
||||
|
||||
var points = areaTriggerSpline.GetPoints();
|
||||
data.WriteBits(points.Length, 16);
|
||||
data.FlushBits();
|
||||
|
||||
foreach (Vector3 point in points)
|
||||
data.WriteVector3(point);
|
||||
}
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
WriteAreaTriggerSpline(data, TimeToTarget, ElapsedTimeForMovement, Points);
|
||||
}
|
||||
|
||||
public uint TimeToTarget;
|
||||
public uint ElapsedTimeForMovement;
|
||||
public Spline<float> Points;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -40,62 +40,30 @@ namespace Game.Networking.Packets
|
||||
}
|
||||
}
|
||||
|
||||
public class BuyBankSlot : ClientPacket
|
||||
public class BuyBankTab : ClientPacket
|
||||
{
|
||||
public BuyBankSlot(WorldPacket packet) : base(packet) { }
|
||||
public ObjectGuid Banker;
|
||||
public BankType BankType;
|
||||
|
||||
public BuyBankTab(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Guid = _worldPacket.ReadPackedGuid();
|
||||
Banker = _worldPacket.ReadPackedGuid();
|
||||
BankType = (BankType)_worldPacket.ReadInt8();
|
||||
}
|
||||
|
||||
public ObjectGuid Guid;
|
||||
}
|
||||
|
||||
class AutoBankReagent : ClientPacket
|
||||
class AutoDepositCharacterBank : ClientPacket
|
||||
{
|
||||
public AutoBankReagent(WorldPacket packet) : base(packet) { }
|
||||
public ObjectGuid Banker;
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Inv = new(_worldPacket);
|
||||
PackSlot = _worldPacket.ReadUInt8();
|
||||
Slot = _worldPacket.ReadUInt8();
|
||||
}
|
||||
|
||||
public InvUpdate Inv;
|
||||
public byte Slot;
|
||||
public byte PackSlot;
|
||||
}
|
||||
|
||||
class AutoStoreBankReagent : ClientPacket
|
||||
{
|
||||
public AutoStoreBankReagent(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Inv = new(_worldPacket);
|
||||
Slot = _worldPacket.ReadUInt8();
|
||||
PackSlot = _worldPacket.ReadUInt8();
|
||||
}
|
||||
|
||||
public InvUpdate Inv;
|
||||
public byte Slot;
|
||||
public byte PackSlot;
|
||||
}
|
||||
|
||||
// CMSG_BUY_REAGENT_BANK
|
||||
// CMSG_REAGENT_BANK_DEPOSIT
|
||||
class ReagentBank : ClientPacket
|
||||
{
|
||||
public ReagentBank(WorldPacket packet) : base(packet) { }
|
||||
public AutoDepositCharacterBank(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Banker = _worldPacket.ReadPackedGuid();
|
||||
}
|
||||
|
||||
public ObjectGuid Banker;
|
||||
}
|
||||
|
||||
class BankerActivate : ClientPacket
|
||||
@@ -111,4 +79,43 @@ namespace Game.Networking.Packets
|
||||
InteractionType = (PlayerInteractionType)_worldPacket.ReadInt32();
|
||||
}
|
||||
}
|
||||
|
||||
class UpdateBankTabSettings : ClientPacket
|
||||
{
|
||||
public ObjectGuid Banker;
|
||||
public BankType BankType;
|
||||
public byte Tab;
|
||||
public BankTabSettings Settings;
|
||||
|
||||
public UpdateBankTabSettings(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Banker = _worldPacket.ReadPackedGuid();
|
||||
BankType = (BankType)_worldPacket.ReadInt8();
|
||||
Tab = _worldPacket.ReadUInt8();
|
||||
Settings.Read(_worldPacket);
|
||||
}
|
||||
}
|
||||
|
||||
public struct BankTabSettings
|
||||
{
|
||||
public string Name;
|
||||
public string Icon;
|
||||
public string Description;
|
||||
public BagSlotFlags DepositFlags;
|
||||
|
||||
public void Read(WorldPacket data)
|
||||
{
|
||||
data.ResetBitPos();
|
||||
var nameLength = data.ReadBits<uint>(7);
|
||||
var iconLength = data.ReadBits<uint>(9);
|
||||
var descriptionLength = data.ReadBits<uint>(14);
|
||||
DepositFlags = (BagSlotFlags)data.ReadInt32();
|
||||
|
||||
Name = data.ReadString(nameLength);
|
||||
Icon = data.ReadString(iconLength);
|
||||
Description = data.ReadString(descriptionLength);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -50,6 +50,8 @@ namespace Game.Networking.Packets
|
||||
for (int i = 0; i < PvpTalents.Count; ++i)
|
||||
_worldPacket.WriteUInt16(PvpTalents[i]);
|
||||
|
||||
TalentInfo.Write(_worldPacket);
|
||||
|
||||
_worldPacket.WriteBit(GuildData.HasValue);
|
||||
_worldPacket.WriteBit(AzeriteLevel.HasValue);
|
||||
_worldPacket.FlushBits();
|
||||
@@ -79,6 +81,7 @@ namespace Game.Networking.Packets
|
||||
public ushort TodayHK;
|
||||
public ushort YesterdayHK;
|
||||
public byte LifetimeMaxRank;
|
||||
public ClassicTalentInfoUpdate TalentInfo;
|
||||
public TraitInspectInfo TraitsInfo = new();
|
||||
}
|
||||
|
||||
|
||||
@@ -657,13 +657,6 @@ namespace Game.Networking.Packets
|
||||
public override void Read() { }
|
||||
}
|
||||
|
||||
class SortReagentBankBags : ClientPacket
|
||||
{
|
||||
public SortReagentBankBags(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read() { }
|
||||
}
|
||||
|
||||
class BagCleanupFinished : ServerPacket
|
||||
{
|
||||
public BagCleanupFinished() : base(ServerOpcodes.BagCleanupFinished, ConnectionType.Instance) { }
|
||||
@@ -1006,24 +999,6 @@ namespace Game.Networking.Packets
|
||||
}
|
||||
}
|
||||
|
||||
public ItemInstance(VoidStorageItem voidItem)
|
||||
{
|
||||
ItemID = voidItem.ItemEntry;
|
||||
|
||||
if (voidItem.FixedScalingLevel != 0)
|
||||
Modifications.Values.Add(new ItemMod(voidItem.FixedScalingLevel, ItemModifier.TimewalkerLevel));
|
||||
|
||||
if (voidItem.ArtifactKnowledgeLevel != 0)
|
||||
Modifications.Values.Add(new ItemMod(voidItem.ArtifactKnowledgeLevel, ItemModifier.ArtifactKnowledgeLevel));
|
||||
|
||||
if (!voidItem.BonusListIDs.Empty())
|
||||
{
|
||||
ItemBonus = new();
|
||||
ItemBonus.Context = voidItem.Context;
|
||||
ItemBonus.BonusListIDs = voidItem.BonusListIDs;
|
||||
}
|
||||
}
|
||||
|
||||
public ItemInstance(SocketedGem gem)
|
||||
{
|
||||
ItemID = gem.ItemId;
|
||||
|
||||
@@ -333,9 +333,9 @@ namespace Game.Networking.Packets
|
||||
if (moveSpline.anim_tier != null)
|
||||
{
|
||||
data.WriteUInt32(moveSpline.anim_tier.TierTransitionId);
|
||||
data.WriteUInt8(moveSpline.anim_tier.AnimTier);
|
||||
data.WriteInt32(moveSpline.effect_start_time);
|
||||
data.WriteUInt32(0);
|
||||
data.WriteUInt8(moveSpline.anim_tier.AnimTier);
|
||||
}
|
||||
|
||||
//if (HasUnknown901)
|
||||
@@ -1473,9 +1473,9 @@ namespace Game.Networking.Packets
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteInt32(TierTransitionID);
|
||||
data.WriteUInt8(AnimTier);
|
||||
data.WriteUInt32(StartTime);
|
||||
data.WriteUInt32(EndTime);
|
||||
data.WriteUInt8(AnimTier);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -782,6 +782,7 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteUInt8(LeaderFactionGroup);
|
||||
_worldPacket.WriteInt32((int)PingRestriction);
|
||||
_worldPacket.WriteInt32(PlayerList.Count);
|
||||
_worldPacket.WriteBit(ChallengeMode.HasValue);
|
||||
_worldPacket.WriteBit(LfgInfos.HasValue);
|
||||
_worldPacket.WriteBit(LootSettings.HasValue);
|
||||
_worldPacket.WriteBit(DifficultySettings.HasValue);
|
||||
@@ -796,6 +797,9 @@ namespace Game.Networking.Packets
|
||||
if (DifficultySettings.HasValue)
|
||||
DifficultySettings.Value.Write(_worldPacket);
|
||||
|
||||
if (ChallengeMode.HasValue)
|
||||
ChallengeMode.Value.Write(_worldPacket);
|
||||
|
||||
if (LfgInfos.HasValue)
|
||||
LfgInfos.Value.Write(_worldPacket);
|
||||
}
|
||||
@@ -815,6 +819,7 @@ namespace Game.Networking.Packets
|
||||
|
||||
public List<PartyPlayerInfo> PlayerList = new();
|
||||
|
||||
public ChallengeModeData? ChallengeMode;
|
||||
public PartyLFGInfo? LfgInfos;
|
||||
public PartyLootSettings? LootSettings;
|
||||
public PartyDifficultySettings? DifficultySettings;
|
||||
@@ -1253,8 +1258,50 @@ namespace Game.Networking.Packets
|
||||
public DungeonScoreSummary DungeonScore = new();
|
||||
}
|
||||
|
||||
public struct LeaverInfo
|
||||
{
|
||||
public ObjectGuid BnetAccountGUID;
|
||||
public float LeaveScore;
|
||||
public uint SeasonID;
|
||||
public uint TotalLeaves;
|
||||
public uint TotalSuccesses;
|
||||
public int ConsecutiveSuccesses;
|
||||
public long LastPenaltyTime;
|
||||
public long LeaverExpirationTime;
|
||||
public int Unknown_1120;
|
||||
public bool LeaverStatus;
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WritePackedGuid(BnetAccountGUID);
|
||||
data.WriteFloat(LeaveScore);
|
||||
data.WriteUInt32(SeasonID);
|
||||
data.WriteUInt32(TotalLeaves);
|
||||
data.WriteUInt32(TotalSuccesses);
|
||||
data.WriteInt32(ConsecutiveSuccesses);
|
||||
data.WriteInt64(LastPenaltyTime);
|
||||
data.WriteInt64(LeaverExpirationTime);
|
||||
data.WriteInt32(Unknown_1120);
|
||||
data.WriteBits(LeaverStatus, 1);
|
||||
data.FlushBits();
|
||||
}
|
||||
}
|
||||
|
||||
struct PartyPlayerInfo
|
||||
{
|
||||
public ObjectGuid GUID;
|
||||
public string Name;
|
||||
public string VoiceStateID; // same as bgs.protocol.club.v1.MemberVoiceState.id
|
||||
public LeaverInfo Leaver;
|
||||
public byte Class;
|
||||
public byte Subgroup;
|
||||
public byte Flags;
|
||||
public byte RolesAssigned;
|
||||
public byte FactionGroup;
|
||||
public bool FromSocialQueue;
|
||||
public bool VoiceChatSilenced;
|
||||
public bool Connected;
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteBits(Name.GetByteCount(), 6);
|
||||
@@ -1262,6 +1309,7 @@ namespace Game.Networking.Packets
|
||||
data.WriteBit(Connected);
|
||||
data.WriteBit(VoiceChatSilenced);
|
||||
data.WriteBit(FromSocialQueue);
|
||||
Leaver.Write(data);
|
||||
data.WritePackedGuid(GUID);
|
||||
data.WriteUInt8(Subgroup);
|
||||
data.WriteUInt8(Flags);
|
||||
@@ -1272,22 +1320,21 @@ namespace Game.Networking.Packets
|
||||
if (!VoiceStateID.IsEmpty())
|
||||
data.WriteString(VoiceStateID);
|
||||
}
|
||||
|
||||
public ObjectGuid GUID;
|
||||
public string Name;
|
||||
public string VoiceStateID; // same as bgs.protocol.club.v1.MemberVoiceState.id
|
||||
public byte Class;
|
||||
public byte Subgroup;
|
||||
public byte Flags;
|
||||
public byte RolesAssigned;
|
||||
public byte FactionGroup;
|
||||
public bool FromSocialQueue;
|
||||
public bool VoiceChatSilenced;
|
||||
public bool Connected;
|
||||
}
|
||||
|
||||
struct PartyLFGInfo
|
||||
{
|
||||
public uint Slot;
|
||||
public byte MyFlags;
|
||||
public uint MyRandomSlot;
|
||||
public byte MyPartialClear;
|
||||
public float MyGearDiff;
|
||||
public byte MyStrangerCount;
|
||||
public byte MyKickVoteCount;
|
||||
public byte BootCount;
|
||||
public bool Aborted;
|
||||
public bool MyFirstReward;
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteUInt32(Slot);
|
||||
@@ -1302,44 +1349,60 @@ namespace Game.Networking.Packets
|
||||
data.WriteBit(MyFirstReward);
|
||||
data.FlushBits();
|
||||
}
|
||||
|
||||
public uint Slot;
|
||||
public byte MyFlags;
|
||||
public uint MyRandomSlot;
|
||||
public byte MyPartialClear;
|
||||
public float MyGearDiff;
|
||||
public byte MyStrangerCount;
|
||||
public byte MyKickVoteCount;
|
||||
public byte BootCount;
|
||||
public bool Aborted;
|
||||
public bool MyFirstReward;
|
||||
}
|
||||
|
||||
struct PartyLootSettings
|
||||
{
|
||||
public byte Method;
|
||||
public ObjectGuid LootMaster;
|
||||
public byte Threshold;
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteUInt8(Method);
|
||||
data.WritePackedGuid(LootMaster);
|
||||
data.WriteUInt8(Threshold);
|
||||
}
|
||||
|
||||
public byte Method;
|
||||
public ObjectGuid LootMaster;
|
||||
public byte Threshold;
|
||||
}
|
||||
|
||||
struct PartyDifficultySettings
|
||||
{
|
||||
public uint DungeonDifficultyID;
|
||||
public uint RaidDifficultyID;
|
||||
public uint LegacyRaidDifficultyID;
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteUInt32(DungeonDifficultyID);
|
||||
data.WriteUInt32(RaidDifficultyID);
|
||||
data.WriteUInt32(LegacyRaidDifficultyID);
|
||||
}
|
||||
}
|
||||
|
||||
public uint DungeonDifficultyID;
|
||||
public uint RaidDifficultyID;
|
||||
public uint LegacyRaidDifficultyID;
|
||||
struct ChallengeModeData
|
||||
{
|
||||
public int Unknown_1120_1;
|
||||
public int Unknown_1120_2;
|
||||
public ulong Unknown_1120_3;
|
||||
public long Unknown_1120_4;
|
||||
public ObjectGuid KeystoneOwnerGUID;
|
||||
public ObjectGuid LeaverGUID;
|
||||
public bool IsActive;
|
||||
public bool HasRestrictions;
|
||||
public bool CanVoteAbandon;
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteInt32(Unknown_1120_1);
|
||||
data.WriteInt32(Unknown_1120_2);
|
||||
data.WriteUInt64(Unknown_1120_3);
|
||||
data.WriteInt64(Unknown_1120_4);
|
||||
data.WritePackedGuid(KeystoneOwnerGUID);
|
||||
data.WritePackedGuid(LeaverGUID);
|
||||
data.WriteBit(IsActive);
|
||||
data.WriteBit(HasRestrictions);
|
||||
data.WriteBit(CanVoteAbandon);
|
||||
data.FlushBits();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -767,7 +767,7 @@ namespace Game.Networking.Packets
|
||||
public int CreatureDifficultyID;
|
||||
public int WidgetSetID;
|
||||
public int WidgetSetUnitConditionID;
|
||||
public uint[] Flags = new uint[2];
|
||||
public uint[] Flags = new uint[3];
|
||||
public uint[] ProxyCreatureID = new uint[SharedConst.MaxCreatureKillCredit];
|
||||
public StringArray Name = new(SharedConst.MaxCreatureNames);
|
||||
public StringArray NameAlt = new(SharedConst.MaxCreatureNames);
|
||||
|
||||
@@ -29,7 +29,6 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteUInt32(KioskSessionDurationMinutes);
|
||||
_worldPacket.WriteInt64(RedeemForBalanceAmount);
|
||||
|
||||
_worldPacket.WriteUInt32(BpayStorePurchaseTimeout);
|
||||
_worldPacket.WriteUInt32(ClubsPresenceDelay);
|
||||
_worldPacket.WriteUInt32(ClubPresenceUnsubscribeDelay);
|
||||
|
||||
@@ -57,60 +56,58 @@ namespace Game.Networking.Packets
|
||||
|
||||
_worldPacket.WriteBit(VoiceEnabled);
|
||||
_worldPacket.WriteBit(EuropaTicketSystemStatus.HasValue);
|
||||
_worldPacket.WriteBit(BpayStoreEnabled);
|
||||
_worldPacket.WriteBit(BpayStoreAvailable);
|
||||
_worldPacket.WriteBit(BpayStoreDisabledByParentalControls);
|
||||
_worldPacket.WriteBit(ItemRestorationButtonEnabled);
|
||||
_worldPacket.WriteBit(BrowserEnabled);
|
||||
|
||||
_worldPacket.WriteBit(SessionAlert.HasValue);
|
||||
_worldPacket.WriteBit(RAFSystem.Enabled);
|
||||
_worldPacket.WriteBit(RAFSystem.RecruitingEnabled);
|
||||
|
||||
_worldPacket.WriteBit(CharUndeleteEnabled);
|
||||
_worldPacket.WriteBit(RestrictedAccount);
|
||||
_worldPacket.WriteBit(CommerceServerEnabled);
|
||||
_worldPacket.WriteBit(TutorialEnabled);
|
||||
|
||||
_worldPacket.WriteBit(VeteranTokenRedeemWillKick);
|
||||
_worldPacket.WriteBit(WorldTokenRedeemWillKick);
|
||||
_worldPacket.WriteBit(KioskModeEnabled);
|
||||
_worldPacket.WriteBit(CompetitiveModeEnabled);
|
||||
|
||||
_worldPacket.WriteBit(RedeemForBalanceAvailable);
|
||||
_worldPacket.WriteBit(WarModeEnabled);
|
||||
_worldPacket.WriteBit(CommunitiesEnabled);
|
||||
_worldPacket.WriteBit(BnetGroupsEnabled);
|
||||
|
||||
_worldPacket.WriteBit(CharacterCommunitiesEnabled);
|
||||
_worldPacket.WriteBit(ClubPresenceAllowSubscribeAll);
|
||||
_worldPacket.WriteBit(VoiceChatParentalDisabled);
|
||||
_worldPacket.WriteBit(VoiceChatParentalMuted);
|
||||
|
||||
_worldPacket.WriteBit(QuestSessionEnabled);
|
||||
_worldPacket.WriteBit(IsChatMuted);
|
||||
_worldPacket.WriteBit(ClubFinderEnabled);
|
||||
_worldPacket.WriteBit(CommunityFinderEnabled);
|
||||
_worldPacket.WriteBit(BrowserCrashReporterEnabled);
|
||||
_worldPacket.WriteBit(SpeakForMeAllowed);
|
||||
|
||||
_worldPacket.WriteBit(DoesAccountNeedAADCPrompt);
|
||||
_worldPacket.WriteBit(IsAccountOptedInToAADC);
|
||||
|
||||
_worldPacket.WriteBit(LfgRequireAuthenticatorEnabled);
|
||||
_worldPacket.WriteBit(ScriptsDisallowedForBeta);
|
||||
_worldPacket.WriteBit(TimerunningEnabled);
|
||||
_worldPacket.WriteBit(WarGamesEnabled);
|
||||
_worldPacket.WriteBit(IsPlayerContentTrackingEnabled);
|
||||
_worldPacket.WriteBit(SellAllJunkEnabled);
|
||||
|
||||
_worldPacket.WriteBit(GroupFinderEnabled);
|
||||
_worldPacket.WriteBit(IsPremadeGroupEnabled);
|
||||
|
||||
_worldPacket.WriteBit(false); // unused 10.2.7
|
||||
_worldPacket.WriteBit(GuildEventsEditsEnabled);
|
||||
_worldPacket.WriteBit(GuildTradeSkillsEnabled);
|
||||
_worldPacket.WriteBits(Unknown1027.GetByteCount(), 7);
|
||||
_worldPacket.WriteBits(Unknown1027.GetByteCount(), 10);
|
||||
_worldPacket.WriteBit(BNSendWhisperUseV2Services);
|
||||
_worldPacket.WriteBit(BNSendGameDataUseV2Services);
|
||||
_worldPacket.WriteBit(IsAccountCurrencyTransferEnabled);
|
||||
_worldPacket.WriteBit(false); // unused 11.0.7
|
||||
|
||||
_worldPacket.WriteBit(false); // unused 11.0.7
|
||||
_worldPacket.WriteBit(LobbyMatchmakerQueueFromMainlineEnabled);
|
||||
_worldPacket.WriteBit(CanSendLobbyMatchmakerPartyCustomizations);
|
||||
_worldPacket.WriteBit(AddonProfilerEnabled);
|
||||
@@ -139,9 +136,7 @@ namespace Game.Networking.Packets
|
||||
}
|
||||
|
||||
public bool VoiceEnabled;
|
||||
public bool BrowserEnabled;
|
||||
public bool BpayStoreAvailable;
|
||||
public bool BpayStoreEnabled;
|
||||
public SessionAlertConfig? SessionAlert;
|
||||
public EuropaTicketConfig? EuropaTicketSystemStatus;
|
||||
public uint CfgRealmID;
|
||||
@@ -149,7 +144,6 @@ namespace Game.Networking.Packets
|
||||
public int CfgRealmRecID;
|
||||
public uint CommercePricePollTimeSeconds;
|
||||
public long RedeemForBalanceAmount;
|
||||
public uint BpayStorePurchaseTimeout;
|
||||
public uint ClubsPresenceDelay;
|
||||
public uint ClubPresenceUnsubscribeDelay; // Timer for updating club presence when communities ui frame is hidden
|
||||
public uint KioskSessionDurationMinutes;
|
||||
@@ -308,7 +302,6 @@ namespace Game.Networking.Packets
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WriteBit(BpayStoreEnabled);
|
||||
_worldPacket.WriteBit(BpayStoreAvailable);
|
||||
_worldPacket.WriteBit(BpayStoreDisabledByParentalControls);
|
||||
_worldPacket.WriteBit(CharUndeleteEnabled);
|
||||
@@ -316,8 +309,8 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteBit(VeteranTokenRedeemWillKick);
|
||||
_worldPacket.WriteBit(WorldTokenRedeemWillKick);
|
||||
_worldPacket.WriteBit(ExpansionPreorderInStore);
|
||||
|
||||
_worldPacket.WriteBit(KioskModeEnabled);
|
||||
|
||||
_worldPacket.WriteBit(CompetitiveModeEnabled);
|
||||
_worldPacket.WriteBit(BoostEnabled);
|
||||
_worldPacket.WriteBit(TrialBoostEnabled);
|
||||
@@ -325,8 +318,8 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteBit(PaidCharacterTransfersBetweenBnetAccountsEnabled);
|
||||
_worldPacket.WriteBit(LiveRegionCharacterListEnabled);
|
||||
_worldPacket.WriteBit(LiveRegionCharacterCopyEnabled);
|
||||
|
||||
_worldPacket.WriteBit(LiveRegionAccountCopyEnabled);
|
||||
|
||||
_worldPacket.WriteBit(LiveRegionKeyBindingsCopyEnabled);
|
||||
_worldPacket.WriteBit(BrowserCrashReporterEnabled);
|
||||
_worldPacket.WriteBit(IsEmployeeAccount);
|
||||
@@ -334,16 +327,16 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteBit(NameReservationOnly);
|
||||
_worldPacket.WriteBit(LaunchDurationETA.HasValue);
|
||||
_worldPacket.WriteBit(TimerunningEnabled);
|
||||
|
||||
_worldPacket.WriteBit(ScriptsDisallowedForBeta);
|
||||
|
||||
_worldPacket.WriteBit(PlayerIdentityOptionsEnabled);
|
||||
_worldPacket.WriteBit(AccountExportEnabled);
|
||||
_worldPacket.WriteBit(AccountLockedPostExport);
|
||||
_worldPacket.WriteBits(RealmHiddenAlert.GetByteCount() + 1, 11);
|
||||
|
||||
_worldPacket.WriteBit(BNSendWhisperUseV2Services);
|
||||
|
||||
_worldPacket.WriteBit(BNSendGameDataUseV2Services);
|
||||
|
||||
_worldPacket.WriteBit(CharacterSelectListModeRealmless);
|
||||
_worldPacket.WriteBit(WowTokenLimitedMode);
|
||||
_worldPacket.WriteBit(false); // unused 11.1.7
|
||||
@@ -360,7 +353,6 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteInt64(RedeemForBalanceAmount);
|
||||
_worldPacket.WriteInt32(MaxCharactersOnThisRealm);
|
||||
_worldPacket.WriteInt32(LiveRegionCharacterCopySourceRegions.Count);
|
||||
_worldPacket.WriteUInt32(BpayStorePurchaseTimeout);
|
||||
_worldPacket.WriteInt32(ActiveBoostType);
|
||||
_worldPacket.WriteInt32(TrialBoostType);
|
||||
_worldPacket.WriteInt32(MinimumExpansionLevel);
|
||||
@@ -395,7 +387,6 @@ namespace Game.Networking.Packets
|
||||
public bool BpayStoreAvailable; // NYI
|
||||
public bool BpayStoreDisabledByParentalControls; // NYI
|
||||
public bool CharUndeleteEnabled;
|
||||
public bool BpayStoreEnabled; // NYI
|
||||
public bool CommerceServerEnabled; // NYI
|
||||
public bool VeteranTokenRedeemWillKick; // NYI
|
||||
public bool WorldTokenRedeemWillKick; // NYI
|
||||
@@ -428,7 +419,6 @@ namespace Game.Networking.Packets
|
||||
public uint CommercePricePollTimeSeconds; // NYI
|
||||
public long RedeemForBalanceAmount; // NYI
|
||||
public int MaxCharactersOnThisRealm;
|
||||
public uint BpayStorePurchaseTimeout; // NYI
|
||||
public int ActiveBoostType; // NYI
|
||||
public int TrialBoostType; // NYI
|
||||
public int MinimumExpansionLevel;
|
||||
|
||||
@@ -22,12 +22,16 @@ namespace Game.Networking.Packets
|
||||
_worldPacket.WriteUInt32(talentGroupInfo.SpecID);
|
||||
_worldPacket.WriteInt32(talentGroupInfo.TalentIDs.Count);
|
||||
_worldPacket.WriteInt32(talentGroupInfo.PvPTalents.Count);
|
||||
_worldPacket.WriteInt32(talentGroupInfo.GlyphIDs.Count);
|
||||
|
||||
foreach (var talentID in talentGroupInfo.TalentIDs)
|
||||
_worldPacket.WriteUInt16(talentID);
|
||||
|
||||
foreach (PvPTalent talent in talentGroupInfo.PvPTalents)
|
||||
talent.Write(_worldPacket);
|
||||
|
||||
foreach (uint talent in talentGroupInfo.GlyphIDs)
|
||||
_worldPacket.WriteUInt16((ushort)talent);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -38,6 +42,7 @@ namespace Game.Networking.Packets
|
||||
public uint SpecID;
|
||||
public List<ushort> TalentIDs = new();
|
||||
public List<PvPTalent> PvPTalents = new();
|
||||
public List<uint> GlyphIDs = new();
|
||||
}
|
||||
|
||||
public class TalentInfoUpdate
|
||||
@@ -183,6 +188,9 @@ namespace Game.Networking.Packets
|
||||
|
||||
struct GlyphBinding
|
||||
{
|
||||
uint SpellID;
|
||||
ushort GlyphID;
|
||||
|
||||
public GlyphBinding(uint spellId, ushort glyphId)
|
||||
{
|
||||
SpellID = spellId;
|
||||
@@ -194,8 +202,66 @@ namespace Game.Networking.Packets
|
||||
data.WriteUInt32(SpellID);
|
||||
data.WriteUInt16(GlyphID);
|
||||
}
|
||||
}
|
||||
|
||||
uint SpellID;
|
||||
ushort GlyphID;
|
||||
public struct ClassicTalentEntry
|
||||
{
|
||||
public int TalentID;
|
||||
public int Rank;
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteInt32(TalentID);
|
||||
data.WriteInt32(Rank);
|
||||
}
|
||||
}
|
||||
|
||||
public class ClassicTalentGroupInfo
|
||||
{
|
||||
public byte NumTalents;
|
||||
public List<ClassicTalentEntry> Talents = new();
|
||||
public byte NumGlyphs;
|
||||
public List<ushort> GlyphIDs = new();
|
||||
public sbyte Role;
|
||||
public int PrimarySpecialization;
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteUInt8(NumTalents);
|
||||
data.WriteInt32(Talents.Count);
|
||||
|
||||
data.WriteUInt8(NumGlyphs);
|
||||
data.WriteInt32(GlyphIDs.Count);
|
||||
|
||||
data.WriteInt8(Role);
|
||||
data.WriteInt32(PrimarySpecialization);
|
||||
|
||||
foreach (ClassicTalentEntry talentEntry in Talents)
|
||||
talentEntry.Write(data);
|
||||
|
||||
foreach (ushort id in GlyphIDs)
|
||||
data.WriteUInt16(id);
|
||||
}
|
||||
}
|
||||
|
||||
public class ClassicTalentInfoUpdate
|
||||
{
|
||||
public int UnspentTalentPoints;
|
||||
public byte ActiveGroup;
|
||||
public bool IsPetTalents;
|
||||
public List<ClassicTalentGroupInfo> Talents = new();
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data.WriteInt32(UnspentTalentPoints);
|
||||
data.WriteUInt8(ActiveGroup);
|
||||
data.WriteInt32(Talents.Count);
|
||||
|
||||
foreach (ClassicTalentGroupInfo talents in Talents)
|
||||
talents.Write(data);
|
||||
|
||||
data.WriteBit(IsPetTalents);
|
||||
data.FlushBits();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -121,6 +121,7 @@ namespace Game.Networking.Packets
|
||||
public int TraitNodeEntryID;
|
||||
public int Rank;
|
||||
public int GrantedRanks;
|
||||
public int BonusRanks;
|
||||
|
||||
public TraitEntryPacket() { }
|
||||
public TraitEntryPacket(TraitEntry ufEntry)
|
||||
@@ -137,6 +138,7 @@ namespace Game.Networking.Packets
|
||||
TraitNodeEntryID = data.ReadInt32();
|
||||
Rank = data.ReadInt32();
|
||||
GrantedRanks = data.ReadInt32();
|
||||
BonusRanks = data.ReadInt32();
|
||||
}
|
||||
|
||||
public void Write(WorldPacket data)
|
||||
@@ -145,6 +147,7 @@ namespace Game.Networking.Packets
|
||||
data.WriteInt32(TraitNodeEntryID);
|
||||
data.WriteInt32(Rank);
|
||||
data.WriteInt32(GrantedRanks);
|
||||
data.WriteInt32(BonusRanks);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,169 +0,0 @@
|
||||
// Copyright (c) CypherCore <http://github.com/CypherCore> All rights reserved.
|
||||
// Licensed under the GNU GENERAL PUBLIC LICENSE. See LICENSE file in the project root for full license information.
|
||||
|
||||
using Framework.Constants;
|
||||
using Game.Entities;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Game.Networking.Packets
|
||||
{
|
||||
class VoidTransferResult : ServerPacket
|
||||
{
|
||||
public VoidTransferResult(VoidTransferError result) : base(ServerOpcodes.VoidTransferResult, ConnectionType.Instance)
|
||||
{
|
||||
Result = result;
|
||||
}
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WriteInt32((int)Result);
|
||||
}
|
||||
|
||||
public VoidTransferError Result;
|
||||
}
|
||||
|
||||
class UnlockVoidStorage : ClientPacket
|
||||
{
|
||||
public UnlockVoidStorage(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Npc = _worldPacket.ReadPackedGuid();
|
||||
}
|
||||
|
||||
public ObjectGuid Npc;
|
||||
}
|
||||
|
||||
class QueryVoidStorage : ClientPacket
|
||||
{
|
||||
public QueryVoidStorage(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Npc = _worldPacket.ReadPackedGuid();
|
||||
}
|
||||
|
||||
public ObjectGuid Npc;
|
||||
}
|
||||
|
||||
class VoidStorageFailed : ServerPacket
|
||||
{
|
||||
public VoidStorageFailed() : base(ServerOpcodes.VoidStorageFailed, ConnectionType.Instance) { }
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WriteUInt8(Reason);
|
||||
}
|
||||
|
||||
public byte Reason = 0;
|
||||
}
|
||||
|
||||
class VoidStorageContents : ServerPacket
|
||||
{
|
||||
public VoidStorageContents() : base(ServerOpcodes.VoidStorageContents, ConnectionType.Instance) { }
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WriteBits(Items.Count, 8);
|
||||
_worldPacket.FlushBits();
|
||||
|
||||
foreach (VoidItem voidItem in Items)
|
||||
voidItem.Write(_worldPacket);
|
||||
}
|
||||
|
||||
public List<VoidItem> Items = new();
|
||||
}
|
||||
|
||||
class VoidStorageTransfer : ClientPacket
|
||||
{
|
||||
public VoidStorageTransfer(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Npc = _worldPacket.ReadPackedGuid();
|
||||
var DepositCount = _worldPacket.ReadInt32();
|
||||
var WithdrawalCount = _worldPacket.ReadInt32();
|
||||
|
||||
for (uint i = 0; i < DepositCount; ++i)
|
||||
Deposits[i] = _worldPacket.ReadPackedGuid();
|
||||
|
||||
for (uint i = 0; i < WithdrawalCount; ++i)
|
||||
Withdrawals[i] = _worldPacket.ReadPackedGuid();
|
||||
}
|
||||
|
||||
public ObjectGuid[] Withdrawals = new ObjectGuid[(int)SharedConst.VoidStorageMaxWithdraw];
|
||||
public ObjectGuid[] Deposits = new ObjectGuid[(int)SharedConst.VoidStorageMaxDeposit];
|
||||
public ObjectGuid Npc;
|
||||
}
|
||||
|
||||
class VoidStorageTransferChanges : ServerPacket
|
||||
{
|
||||
public VoidStorageTransferChanges() : base(ServerOpcodes.VoidStorageTransferChanges, ConnectionType.Instance) { }
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WriteBits(AddedItems.Count, 4);
|
||||
_worldPacket.WriteBits(RemovedItems.Count, 4);
|
||||
_worldPacket.FlushBits();
|
||||
|
||||
foreach (VoidItem addedItem in AddedItems)
|
||||
addedItem.Write(_worldPacket);
|
||||
|
||||
foreach (ObjectGuid removedItem in RemovedItems)
|
||||
_worldPacket.WritePackedGuid(removedItem);
|
||||
}
|
||||
|
||||
public List<ObjectGuid> RemovedItems = new();
|
||||
public List<VoidItem> AddedItems = new();
|
||||
}
|
||||
|
||||
class SwapVoidItem : ClientPacket
|
||||
{
|
||||
public SwapVoidItem(WorldPacket packet) : base(packet) { }
|
||||
|
||||
public override void Read()
|
||||
{
|
||||
Npc = _worldPacket.ReadPackedGuid();
|
||||
VoidItemGuid = _worldPacket.ReadPackedGuid();
|
||||
DstSlot = _worldPacket.ReadUInt32();
|
||||
}
|
||||
|
||||
public ObjectGuid Npc;
|
||||
public ObjectGuid VoidItemGuid;
|
||||
public uint DstSlot;
|
||||
}
|
||||
|
||||
class VoidItemSwapResponse : ServerPacket
|
||||
{
|
||||
public VoidItemSwapResponse() : base(ServerOpcodes.VoidItemSwapResponse, ConnectionType.Instance) { }
|
||||
|
||||
public override void Write()
|
||||
{
|
||||
_worldPacket.WritePackedGuid(VoidItemA);
|
||||
_worldPacket.WriteUInt32(VoidItemSlotA);
|
||||
_worldPacket.WritePackedGuid(VoidItemB);
|
||||
_worldPacket.WriteUInt32(VoidItemSlotB);
|
||||
}
|
||||
|
||||
public ObjectGuid VoidItemA;
|
||||
public ObjectGuid VoidItemB;
|
||||
public uint VoidItemSlotA;
|
||||
public uint VoidItemSlotB;
|
||||
}
|
||||
|
||||
struct VoidItem
|
||||
{
|
||||
public void Write(WorldPacket data)
|
||||
{
|
||||
data .WritePackedGuid(Guid);
|
||||
data .WritePackedGuid(Creator);
|
||||
data .WriteUInt32(Slot);
|
||||
Item.Write(data);
|
||||
}
|
||||
|
||||
public ObjectGuid Guid;
|
||||
public ObjectGuid Creator;
|
||||
public uint Slot;
|
||||
public ItemInstance Item;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user