Core: Updated to 11.0.7

Port From (https://github.com/TrinityCore/TrinityCore/commit/4f7079f471401d5cf7885351baabc027813f60f5)
This commit is contained in:
Hondacrx
2025-05-18 19:05:48 -04:00
parent 2448c07600
commit 5b992859d0
32 changed files with 1669 additions and 1429 deletions
+2 -1
View File
@@ -1085,7 +1085,7 @@ namespace Framework.Constants
Unk26 = 0x80000000 // ?
}
public enum ItemFieldFlags2
public enum ItemZoneFlags
{
Equipped = 0x1
}
@@ -1372,6 +1372,7 @@ namespace Framework.Constants
CantDeleteInAccountBank = 127,// Items Must Be Moved Out Of The Warband Bank To Be Deleted.
BankNotAccessible = 128,// This Character Does Not Have Access To This Bank.
CantTradeAccountItem = 129,// You Can't Trade An Item From The Warband Bank.
AccountMoneyLocked = 130,// You cannot withdraw or deposit gold from the warband bank currently; please try again later.
}
public enum BankType
File diff suppressed because it is too large Load Diff
+8 -2
View File
@@ -926,7 +926,13 @@ namespace Framework.Constants
public enum PlayerDataFlag
{
ExploredZonesIndex = 1,
CharacterIndex = 2,
AccountIndex = 3
CharacterDataIndex = 2,
AccountDataIndex = 3,
CharacterTaxiNodesIndex = 4,
AccountTaxiNodesIndex = 5,
AccountCombinedQuestsIndex = 6,
AccountCombinedQuestRewardsIndex = 7,
CharacterContentpushIndex = 8,
CharacterQuestCompletedIndex = 9,
}
}
+357 -347
View File
@@ -2749,353 +2749,363 @@ namespace Framework.Constants
LfgJoinedWorldPvpQueue = 821,
LfgJoinedBattlefieldQueue = 822,
LfgJoinedList = 823,
LfgLeftQueue = 824,
LfgLeftList = 825,
LfgRoleCheckAborted = 826,
LfgReadyCheckAborted = 827,
LfgCantUseBattleground = 828,
LfgCantUseDungeons = 829,
LfgReasonTooManyLfg = 830,
LfgFarmLimit = 831,
LfgNoCrossFactionParties = 832,
InvalidTeleportLocation = 833,
TooFarToInteract = 834,
BattlegroundPlayersFromDifferentRealms = 835,
DifficultyChangeCooldownS = 836,
DifficultyChangeCombatCooldownS = 837,
DifficultyChangeWorldstate = 838,
DifficultyChangeEncounter = 839,
DifficultyChangeCombat = 840,
DifficultyChangePlayerBusy = 841,
DifficultyChangePlayerOnVehicle = 842,
DifficultyChangeAlreadyStarted = 843,
DifficultyChangeOtherHeroicS = 844,
DifficultyChangeHeroicInstanceAlreadyRunning = 845,
ArenaTeamPartySize = 846,
SoloShuffleWargameGroupSize = 847,
SoloShuffleWargameGroupComp = 848,
SoloRbgWargameGroupSize = 849,
SoloRbgWargameGroupComp = 850,
SoloMinItemLevel = 851,
PvpPlayerAbandoned = 852,
BattlegroundJoinGroupQueueWithoutHealer = 853,
QuestForceRemovedS = 854,
AttackNoActions = 855,
InRandomBg = 856,
InNonRandomBg = 857,
BnFriendSelf = 858,
BnFriendAlready = 859,
BnFriendBlocked = 860,
BnFriendListFull = 861,
BnFriendRequestSent = 862,
BnBroadcastThrottle = 863,
BgDeveloperOnly = 864,
CurrencySpellSlotMismatch = 865,
CurrencyNotTradable = 866,
RequiresExpansionS = 867,
QuestFailedSpell = 868,
TalentFailedUnspentTalentPoints = 869,
TalentFailedNotEnoughTalentsInPrimaryTree = 870,
TalentFailedNoPrimaryTreeSelected = 871,
TalentFailedCantRemoveTalent = 872,
TalentFailedUnknown = 873,
TalentFailedInCombat = 874,
TalentFailedInPvpMatch = 875,
TalentFailedInMythicPlus = 876,
WargameRequestFailure = 877,
RankRequiresAuthenticator = 878,
GuildBankVoucherFailed = 879,
WargameRequestSent = 880,
RequiresAchievementI = 881,
RefundResultExceedMaxCurrency = 882,
CantBuyQuantity = 883,
ItemIsBattlePayLocked = 884,
PartyAlreadyInBattlegroundQueue = 885,
PartyConfirmingBattlegroundQueue = 886,
BattlefieldTeamPartySize = 887,
InsuffTrackedCurrencyIs = 888,
NotOnTournamentRealm = 889,
GuildTrialAccountTrial = 890,
GuildTrialAccountVeteran = 891,
GuildUndeletableDueToLevel = 892,
CantDoThatInAGroup = 893,
GuildLeaderReplaced = 894,
TransmogrifyCantEquip = 895,
TransmogrifyInvalidItemType = 896,
TransmogrifyNotSoulbound = 897,
TransmogrifyInvalidSource = 898,
TransmogrifyInvalidDestination = 899,
TransmogrifyMismatch = 900,
TransmogrifyLegendary = 901,
TransmogrifySameItem = 902,
TransmogrifySameAppearance = 903,
TransmogrifyNotEquipped = 904,
VoidDepositFull = 905,
VoidWithdrawFull = 906,
VoidStorageWrapped = 907,
VoidStorageStackable = 908,
VoidStorageUnbound = 909,
VoidStorageRepair = 910,
VoidStorageCharges = 911,
VoidStorageQuest = 912,
VoidStorageConjured = 913,
VoidStorageMail = 914,
VoidStorageBag = 915,
VoidTransferStorageFull = 916,
VoidTransferInvFull = 917,
VoidTransferInternalError = 918,
VoidTransferItemInvalid = 919,
DifficultyDisabledInLfg = 920,
VoidStorageUnique = 921,
VoidStorageLoot = 922,
VoidStorageHoliday = 923,
VoidStorageDuration = 924,
VoidStorageLoadFailed = 925,
VoidStorageInvalidItem = 926,
VoidStorageAccountItem = 927,
ParentalControlsChatMuted = 928,
SorStartExperienceIncomplete = 929,
SorInvalidEmail = 930,
SorInvalidComment = 931,
ChallengeModeResetCooldownS = 932,
ChallengeModeResetKeystone = 933,
PetJournalAlreadyInLoadout = 934,
ReportSubmittedSuccessfully = 935,
ReportSubmissionFailed = 936,
SuggestionSubmittedSuccessfully = 937,
BugSubmittedSuccessfully = 938,
ChallengeModeEnabled = 939,
ChallengeModeDisabled = 940,
PetbattleCreateFailed = 941,
PetbattleNotHere = 942,
PetbattleNotHereOnTransport = 943,
PetbattleNotHereUnevenGround = 944,
PetbattleNotHereObstructed = 945,
PetbattleNotWhileInCombat = 946,
PetbattleNotWhileDead = 947,
PetbattleNotWhileFlying = 948,
PetbattleTargetInvalid = 949,
PetbattleTargetOutOfRange = 950,
PetbattleTargetNotCapturable = 951,
PetbattleNotATrainer = 952,
PetbattleDeclined = 953,
PetbattleInBattle = 954,
PetbattleInvalidLoadout = 955,
PetbattleAllPetsDead = 956,
PetbattleNoPetsInSlots = 957,
PetbattleNoAccountLock = 958,
PetbattleWildPetTapped = 959,
PetbattleRestrictedAccount = 960,
PetbattleOpponentNotAvailable = 961,
PetbattleNotWhileInMatchedBattle = 962,
CantHaveMorePetsOfThatType = 963,
CantHaveMorePets = 964,
PvpMapNotFound = 965,
PvpMapNotSet = 966,
PetbattleQueueQueued = 967,
PetbattleQueueAlreadyQueued = 968,
PetbattleQueueJoinFailed = 969,
PetbattleQueueJournalLock = 970,
PetbattleQueueRemoved = 971,
PetbattleQueueProposalDeclined = 972,
PetbattleQueueProposalTimeout = 973,
PetbattleQueueOpponentDeclined = 974,
PetbattleQueueRequeuedInternal = 975,
PetbattleQueueRequeuedRemoved = 976,
PetbattleQueueSlotLocked = 977,
PetbattleQueueSlotEmpty = 978,
PetbattleQueueSlotNoTracker = 979,
PetbattleQueueSlotNoSpecies = 980,
PetbattleQueueSlotCantBattle = 981,
PetbattleQueueSlotRevoked = 982,
PetbattleQueueSlotDead = 983,
PetbattleQueueSlotNoPet = 984,
PetbattleQueueNotWhileNeutral = 985,
PetbattleGameTimeLimitWarning = 986,
PetbattleGameRoundsLimitWarning = 987,
HasRestriction = 988,
ItemUpgradeItemTooLowLevel = 989,
ItemUpgradeNoPath = 990,
ItemUpgradeNoMoreUpgrades = 991,
BonusRollEmpty = 992,
ChallengeModeFull = 993,
ChallengeModeInProgress = 994,
ChallengeModeIncorrectKeystone = 995,
BattletagFriendNotFound = 996,
BattletagFriendNotValid = 997,
BattletagFriendNotAllowed = 998,
BattletagFriendThrottled = 999,
BattletagFriendSuccess = 1000,
PetTooHighLevelToUncage = 1001,
PetbattleInternal = 1002,
CantCagePetYet = 1003,
NoLootInChallengeMode = 1004,
QuestPetBattleVictoriesPvpIi = 1005,
RoleCheckAlreadyInProgress = 1006,
RecruitAFriendAccountLimit = 1007,
RecruitAFriendFailed = 1008,
SetLootPersonal = 1009,
SetLootMethodFailedCombat = 1010,
ReagentBankFull = 1011,
ReagentBankLocked = 1012,
GarrisonBuildingExists = 1013,
GarrisonInvalidPlot = 1014,
GarrisonInvalidBuildingid = 1015,
GarrisonInvalidPlotBuilding = 1016,
GarrisonRequiresBlueprint = 1017,
GarrisonNotEnoughCurrency = 1018,
GarrisonNotEnoughGold = 1019,
GarrisonCompleteMissionWrongFollowerType = 1020,
AlreadyUsingLfgList = 1021,
RestrictedAccountLfgListTrial = 1022,
ToyUseLimitReached = 1023,
ToyAlreadyKnown = 1024,
TransmogSetAlreadyKnown = 1025,
NotEnoughCurrency = 1026,
SpecIsDisabled = 1027,
FeatureRestrictedTrial = 1028,
CantBeObliterated = 1029,
CantBeScrapped = 1030,
CantBeRecrafted = 1031,
ArtifactRelicDoesNotMatchArtifact = 1032,
MustEquipArtifact = 1033,
CantDoThatRightNow = 1034,
AffectingCombat = 1035,
EquipmentManagerCombatSwapS = 1036,
EquipmentManagerBagsFull = 1037,
EquipmentManagerMissingItemS = 1038,
MovieRecordingWarningPerf = 1039,
MovieRecordingWarningDiskFull = 1040,
MovieRecordingWarningNoMovie = 1041,
MovieRecordingWarningRequirements = 1042,
MovieRecordingWarningCompressing = 1043,
NoChallengeModeReward = 1044,
ClaimedChallengeModeReward = 1045,
ChallengeModePeriodResetSs = 1046,
CantDoThatChallengeModeActive = 1047,
TalentFailedRestArea = 1048,
CannotAbandonLastPet = 1049,
TestCvarSetSss = 1050,
QuestTurnInFailReason = 1051,
ClaimedChallengeModeRewardOld = 1052,
TalentGrantedByAura = 1053,
ChallengeModeAlreadyComplete = 1054,
GlyphTargetNotAvailable = 1055,
PvpWarmodeToggleOn = 1056,
PvpWarmodeToggleOff = 1057,
SpellFailedLevelRequirement = 1058,
SpellFailedCantFlyHere = 1059,
BattlegroundJoinRequiresLevel = 1060,
BattlegroundJoinDisqualified = 1061,
BattlegroundJoinDisqualifiedNoName = 1062,
VoiceChatGenericUnableToConnect = 1063,
VoiceChatServiceLost = 1064,
VoiceChatChannelNameTooShort = 1065,
VoiceChatChannelNameTooLong = 1066,
VoiceChatChannelAlreadyExists = 1067,
VoiceChatTargetNotFound = 1068,
VoiceChatTooManyRequests = 1069,
VoiceChatPlayerSilenced = 1070,
VoiceChatParentalDisableAll = 1071,
VoiceChatDisabled = 1072,
NoPvpReward = 1073,
ClaimedPvpReward = 1074,
AzeriteEssenceSelectionFailedEssenceNotUnlocked = 1075,
AzeriteEssenceSelectionFailedCantRemoveEssence = 1076,
AzeriteEssenceSelectionFailedConditionFailed = 1077,
AzeriteEssenceSelectionFailedRestArea = 1078,
AzeriteEssenceSelectionFailedSlotLocked = 1079,
AzeriteEssenceSelectionFailedNotAtForge = 1080,
AzeriteEssenceSelectionFailedHeartLevelTooLow = 1081,
AzeriteEssenceSelectionFailedNotEquipped = 1082,
SocketingRequiresPunchcardredGem = 1083,
SocketingPunchcardredGemOnlyInPunchcardredslot = 1084,
SocketingRequiresPunchcardyellowGem = 1085,
SocketingPunchcardyellowGemOnlyInPunchcardyellowslot = 1086,
SocketingRequiresPunchcardblueGem = 1087,
SocketingPunchcardblueGemOnlyInPunchcardblueslot = 1088,
SocketingRequiresDominationShard = 1089,
SocketingDominationShardOnlyInDominationslot = 1090,
SocketingRequiresCypherGem = 1091,
SocketingCypherGemOnlyInCypherslot = 1092,
SocketingRequiresTinkerGem = 1093,
SocketingTinkerGemOnlyInTinkerslot = 1094,
SocketingRequiresPrimordialGem = 1095,
SocketingPrimordialGemOnlyInPrimordialslot = 1096,
SocketingRequiresFragranceGem = 1097,
SocketingFragranceGemOnlyInFragranceslot = 1098,
LevelLinkingResultLinked = 1099,
LevelLinkingResultUnlinked = 1100,
ClubFinderErrorPostClub = 1101,
ClubFinderErrorApplyClub = 1102,
ClubFinderErrorRespondApplicant = 1103,
ClubFinderErrorCancelApplication = 1104,
ClubFinderErrorTypeAcceptApplication = 1105,
ClubFinderErrorTypeNoInvitePermissions = 1106,
ClubFinderErrorTypeNoPostingPermissions = 1107,
ClubFinderErrorTypeApplicantList = 1108,
ClubFinderErrorTypeApplicantListNoPerm = 1109,
ClubFinderErrorTypeFinderNotAvailable = 1110,
ClubFinderErrorTypeGetPostingIds = 1111,
ClubFinderErrorTypeJoinApplication = 1112,
ClubFinderErrorTypeRealmNotEligible = 1113,
ClubFinderErrorTypeFlaggedRename = 1114,
ClubFinderErrorTypeFlaggedDescriptionChange = 1115,
ItemInteractionNotEnoughGold = 1116,
ItemInteractionNotEnoughCurrency = 1117,
ItemInteractionNoConversionOutput = 1118,
PlayerChoiceErrorPendingChoice = 1119,
SoulbindInvalidConduit = 1120,
SoulbindInvalidConduitItem = 1121,
SoulbindInvalidTalent = 1122,
SoulbindDuplicateConduit = 1123,
ActivateSoulbindS = 1124,
ActivateSoulbindFailedRestArea = 1125,
CantUseProfanity = 1126,
NotInPetBattle = 1127,
NotInNpe = 1128,
NoSpec = 1129,
NoDominationshardOverwrite = 1130,
UseWeeklyRewardsDisabled = 1131,
CrossFactionGroupJoined = 1132,
CantTargetUnfriendlyInOverworld = 1133,
EquipablespellsSlotsFull = 1134,
ItemModAppearanceGroupAlreadyKnown = 1135,
CantBulkSellItemWithRefund = 1136,
NoSoulboundItemInAccountBank = 1137,
NoRefundableItemInAccountBank = 1138,
CantDeleteInAccountBank = 1139,
NoImmediateContainerInAccountBank = 1140,
NoOpenImmediateContainerInAccountBank = 1141,
CantTradeAccountItem = 1142,
NoAccountInventoryLock = 1143,
BankNotAccessible = 1144,
TooManyAccountBankTabs = 1145,
AccountBankTabNotUnlocked = 1146,
BankTabInvalidName = 1147,
BankTabInvalidText = 1148,
WowLabsPartyErrorTypePartyIsFull = 1149,
WowLabsPartyErrorTypeMaxInviteSent = 1150,
WowLabsPartyErrorTypePlayerAlreadyInvited = 1151,
WowLabsPartyErrorTypePartyInviteInvalid = 1152,
WowLabsLobbyMatchmakerErrorEnterQueueFailed = 1153,
WowLabsLobbyMatchmakerErrorLeaveQueueFailed = 1154,
TargetIsSelfFoundCannotTrade = 1155,
PlayerIsSelfFoundCannotTrade = 1156,
MailRecepientIsSelfFoundCannotReceiveMail = 1157,
PlayerIsSelfFoundCannotSendMail = 1158,
PlayerIsSelfFoundCannotUseAuctionHouse = 1159,
MailTargetCannotReceiveMail = 1160,
RemixInvalidTransferRequest = 1161,
CurrencyTransferInvalidCharacter = 1162,
CurrencyTransferInvalidCurrency = 1163,
CurrencyTransferInsufficientCurrency = 1164,
CurrencyTransferMaxQuantity = 1165,
CurrencyTransferNoValidSource = 1166,
CurrencyTransferCharacterLoggedIn = 1167,
CurrencyTransferServerError = 1168,
CurrencyTransferUnmetRequirements = 1169,
CurrencyTransferTransactionInProgress = 1170,
QueuedPlunderstorm = 824,
LfgLeftQueue = 825,
LfgLeftList = 826,
LfgRoleCheckAborted = 827,
LfgReadyCheckAborted = 828,
LfgCantUseBattleground = 829,
LfgCantUseDungeons = 830,
LfgReasonTooManyLfg = 831,
LfgFarmLimit = 832,
LfgNoCrossFactionParties = 833,
InvalidTeleportLocation = 834,
TooFarToInteract = 835,
BattlegroundPlayersFromDifferentRealms = 836,
DifficultyChangeCooldownS = 837,
DifficultyChangeCombatCooldownS = 838,
DifficultyChangeWorldstate = 839,
DifficultyChangeEncounter = 840,
DifficultyChangeCombat = 841,
DifficultyChangePlayerBusy = 842,
DifficultyChangePlayerOnVehicle = 843,
DifficultyChangeAlreadyStarted = 844,
DifficultyChangeOtherHeroicS = 845,
DifficultyChangeHeroicInstanceAlreadyRunning = 846,
ArenaTeamPartySize = 847,
SoloShuffleWargameGroupSize = 848,
SoloShuffleWargameGroupComp = 849,
SoloRbgWargameGroupSize = 850,
SoloRbgWargameGroupComp = 851,
SoloMinItemLevel = 852,
PvpPlayerAbandoned = 853,
BattlegroundJoinGroupQueueWithoutHealer = 854,
QuestForceRemovedS = 855,
AttackNoActions = 856,
InRandomBg = 857,
InNonRandomBg = 858,
BnFriendSelf = 859,
BnFriendAlready = 860,
BnFriendBlocked = 861,
BnFriendListFull = 862,
BnFriendRequestSent = 863,
BnBroadcastThrottle = 864,
BgDeveloperOnly = 865,
CurrencySpellSlotMismatch = 866,
CurrencyNotTradable = 867,
RequiresExpansionS = 868,
QuestFailedSpell = 869,
TalentFailedUnspentTalentPoints = 870,
TalentFailedNotEnoughTalentsInPrimaryTree = 871,
TalentFailedNoPrimaryTreeSelected = 872,
TalentFailedCantRemoveTalent = 873,
TalentFailedUnknown = 874,
TalentFailedInCombat = 875,
TalentFailedInPvpMatch = 876,
TalentFailedInMythicPlus = 877,
WargameRequestFailure = 878,
RankRequiresAuthenticator = 879,
GuildBankVoucherFailed = 880,
WargameRequestSent = 881,
RequiresAchievementI = 882,
RefundResultExceedMaxCurrency = 883,
CantBuyQuantity = 884,
ItemIsBattlePayLocked = 885,
PartyAlreadyInBattlegroundQueue = 886,
PartyConfirmingBattlegroundQueue = 887,
BattlefieldTeamPartySize = 888,
InsuffTrackedCurrencyIs = 889,
NotOnTournamentRealm = 890,
GuildTrialAccountTrial = 891,
GuildTrialAccountVeteran = 892,
GuildUndeletableDueToLevel = 893,
CantDoThatInAGroup = 894,
GuildLeaderReplaced = 895,
TransmogrifyCantEquip = 896,
TransmogrifyInvalidItemType = 897,
TransmogrifyNotSoulbound = 898,
TransmogrifyInvalidSource = 899,
TransmogrifyInvalidDestination = 900,
TransmogrifyMismatch = 901,
TransmogrifyLegendary = 902,
TransmogrifySameItem = 903,
TransmogrifySameAppearance = 904,
TransmogrifyNotEquipped = 905,
VoidDepositFull = 906,
VoidWithdrawFull = 907,
VoidStorageWrapped = 908,
VoidStorageStackable = 909,
VoidStorageUnbound = 910,
VoidStorageRepair = 911,
VoidStorageCharges = 912,
VoidStorageQuest = 913,
VoidStorageConjured = 914,
VoidStorageMail = 915,
VoidStorageBag = 916,
VoidTransferStorageFull = 917,
VoidTransferInvFull = 918,
VoidTransferInternalError = 919,
VoidTransferItemInvalid = 920,
DifficultyDisabledInLfg = 921,
VoidStorageUnique = 922,
VoidStorageLoot = 923,
VoidStorageHoliday = 924,
VoidStorageDuration = 925,
VoidStorageLoadFailed = 926,
VoidStorageInvalidItem = 927,
VoidStorageAccountItem = 928,
ParentalControlsChatMuted = 929,
SorStartExperienceIncomplete = 930,
SorInvalidEmail = 931,
SorInvalidComment = 932,
ChallengeModeResetCooldownS = 933,
ChallengeModeResetKeystone = 934,
PetJournalAlreadyInLoadout = 935,
ReportSubmittedSuccessfully = 936,
ReportSubmissionFailed = 937,
SuggestionSubmittedSuccessfully = 938,
BugSubmittedSuccessfully = 939,
ChallengeModeEnabled = 940,
ChallengeModeDisabled = 941,
PetbattleCreateFailed = 942,
PetbattleNotHere = 943,
PetbattleNotHereOnTransport = 944,
PetbattleNotHereUnevenGround = 945,
PetbattleNotHereObstructed = 946,
PetbattleNotWhileInCombat = 947,
PetbattleNotWhileDead = 948,
PetbattleNotWhileFlying = 949,
PetbattleTargetInvalid = 950,
PetbattleTargetOutOfRange = 951,
PetbattleTargetNotCapturable = 952,
PetbattleNotATrainer = 953,
PetbattleDeclined = 954,
PetbattleInBattle = 955,
PetbattleInvalidLoadout = 956,
PetbattleAllPetsDead = 957,
PetbattleNoPetsInSlots = 958,
PetbattleNoAccountLock = 959,
PetbattleWildPetTapped = 960,
PetbattleRestrictedAccount = 961,
PetbattleOpponentNotAvailable = 962,
PetbattleNotWhileInMatchedBattle = 963,
CantHaveMorePetsOfThatType = 964,
CantHaveMorePets = 965,
PvpMapNotFound = 966,
PvpMapNotSet = 967,
PetbattleQueueQueued = 968,
PetbattleQueueAlreadyQueued = 969,
PetbattleQueueJoinFailed = 970,
PetbattleQueueJournalLock = 971,
PetbattleQueueRemoved = 972,
PetbattleQueueProposalDeclined = 973,
PetbattleQueueProposalTimeout = 974,
PetbattleQueueOpponentDeclined = 975,
PetbattleQueueRequeuedInternal = 976,
PetbattleQueueRequeuedRemoved = 977,
PetbattleQueueSlotLocked = 978,
PetbattleQueueSlotEmpty = 979,
PetbattleQueueSlotNoTracker = 980,
PetbattleQueueSlotNoSpecies = 981,
PetbattleQueueSlotCantBattle = 982,
PetbattleQueueSlotRevoked = 983,
PetbattleQueueSlotDead = 984,
PetbattleQueueSlotNoPet = 985,
PetbattleQueueNotWhileNeutral = 986,
PetbattleGameTimeLimitWarning = 987,
PetbattleGameRoundsLimitWarning = 988,
HasRestriction = 989,
ItemUpgradeItemTooLowLevel = 990,
ItemUpgradeNoPath = 991,
ItemUpgradeNoMoreUpgrades = 992,
BonusRollEmpty = 993,
ChallengeModeFull = 994,
ChallengeModeInProgress = 995,
ChallengeModeIncorrectKeystone = 996,
BattletagFriendNotFound = 997,
BattletagFriendNotValid = 998,
BattletagFriendNotAllowed = 999,
BattletagFriendThrottled = 1000,
BattletagFriendSuccess = 1001,
PetTooHighLevelToUncage = 1002,
PetbattleInternal = 1003,
CantCagePetYet = 1004,
NoLootInChallengeMode = 1005,
QuestPetBattleVictoriesPvpIi = 1006,
RoleCheckAlreadyInProgress = 1007,
RecruitAFriendAccountLimit = 1008,
RecruitAFriendFailed = 1009,
SetLootPersonal = 1010,
SetLootMethodFailedCombat = 1011,
ReagentBankFull = 1012,
ReagentBankLocked = 1013,
GarrisonBuildingExists = 1014,
GarrisonInvalidPlot = 1015,
GarrisonInvalidBuildingid = 1016,
GarrisonInvalidPlotBuilding = 1017,
GarrisonRequiresBlueprint = 1018,
GarrisonNotEnoughCurrency = 1019,
GarrisonNotEnoughGold = 1020,
GarrisonCompleteMissionWrongFollowerType = 1021,
AlreadyUsingLfgList = 1022,
RestrictedAccountLfgListTrial = 1023,
ToyUseLimitReached = 1024,
ToyAlreadyKnown = 1025,
TransmogSetAlreadyKnown = 1026,
NotEnoughCurrency = 1027,
SpecIsDisabled = 1028,
FeatureRestrictedTrial = 1029,
CantBeObliterated = 1030,
CantBeScrapped = 1031,
CantBeRecrafted = 1032,
ArtifactRelicDoesNotMatchArtifact = 1033,
MustEquipArtifact = 1034,
CantDoThatRightNow = 1035,
AffectingCombat = 1036,
EquipmentManagerCombatSwapS = 1037,
EquipmentManagerBagsFull = 1038,
EquipmentManagerMissingItemS = 1039,
MovieRecordingWarningPerf = 1040,
MovieRecordingWarningDiskFull = 1041,
MovieRecordingWarningNoMovie = 1042,
MovieRecordingWarningRequirements = 1043,
MovieRecordingWarningCompressing = 1044,
NoChallengeModeReward = 1045,
ClaimedChallengeModeReward = 1046,
ChallengeModePeriodResetSs = 1047,
CantDoThatChallengeModeActive = 1048,
TalentFailedRestArea = 1049,
CannotAbandonLastPet = 1050,
TestCvarSetSss = 1051,
QuestTurnInFailReason = 1052,
ClaimedChallengeModeRewardOld = 1053,
TalentGrantedByAura = 1054,
ChallengeModeAlreadyComplete = 1055,
GlyphTargetNotAvailable = 1056,
PvpWarmodeToggleOn = 1057,
PvpWarmodeToggleOff = 1058,
SpellFailedLevelRequirement = 1059,
SpellFailedCantFlyHere = 1060,
BattlegroundJoinRequiresLevel = 1061,
BattlegroundJoinDisqualified = 1062,
BattlegroundJoinDisqualifiedNoName = 1063,
VoiceChatGenericUnableToConnect = 1064,
VoiceChatServiceLost = 1065,
VoiceChatChannelNameTooShort = 1066,
VoiceChatChannelNameTooLong = 1067,
VoiceChatChannelAlreadyExists = 1068,
VoiceChatTargetNotFound = 1069,
VoiceChatTooManyRequests = 1070,
VoiceChatPlayerSilenced = 1071,
VoiceChatParentalDisableAll = 1072,
VoiceChatDisabled = 1073,
NoPvpReward = 1074,
ClaimedPvpReward = 1075,
AzeriteEssenceSelectionFailedEssenceNotUnlocked = 1076,
AzeriteEssenceSelectionFailedCantRemoveEssence = 1077,
AzeriteEssenceSelectionFailedConditionFailed = 1078,
AzeriteEssenceSelectionFailedRestArea = 1079,
AzeriteEssenceSelectionFailedSlotLocked = 1080,
AzeriteEssenceSelectionFailedNotAtForge = 1081,
AzeriteEssenceSelectionFailedHeartLevelTooLow = 1082,
AzeriteEssenceSelectionFailedNotEquipped = 1083,
SocketingRequiresPunchcardredGem = 1084,
SocketingPunchcardredGemOnlyInPunchcardredslot = 1085,
SocketingRequiresPunchcardyellowGem = 1086,
SocketingPunchcardyellowGemOnlyInPunchcardyellowslot = 1087,
SocketingRequiresPunchcardblueGem = 1088,
SocketingPunchcardblueGemOnlyInPunchcardblueslot = 1089,
SocketingRequiresDominationShard = 1090,
SocketingDominationShardOnlyInDominationslot = 1091,
SocketingRequiresCypherGem = 1092,
SocketingCypherGemOnlyInCypherslot = 1093,
SocketingRequiresTinkerGem = 1094,
SocketingTinkerGemOnlyInTinkerslot = 1095,
SocketingRequiresPrimordialGem = 1096,
SocketingPrimordialGemOnlyInPrimordialslot = 1097,
SocketingRequiresFragranceGem = 1098,
SocketingFragranceGemOnlyInFragranceslot = 1099,
SocketingRequiresSingingThunderGem = 1100,
SocketingSingingthunderGemOnlyInSingingthunderslot = 1101,
SocketingRequiresSingingSeaGem = 1102,
SocketingSingingseaGemOnlyInSingingseaslot = 1103,
SocketingRequiresSingingWindGem = 1104,
SocketingSingingwindGemOnlyInSingingwindslot = 1105,
LevelLinkingResultLinked = 1106,
LevelLinkingResultUnlinked = 1107,
ClubFinderErrorPostClub = 1108,
ClubFinderErrorApplyClub = 1109,
ClubFinderErrorRespondApplicant = 1110,
ClubFinderErrorCancelApplication = 1111,
ClubFinderErrorTypeAcceptApplication = 1112,
ClubFinderErrorTypeNoInvitePermissions = 1113,
ClubFinderErrorTypeNoPostingPermissions = 1114,
ClubFinderErrorTypeApplicantList = 1115,
ClubFinderErrorTypeApplicantListNoPerm = 1116,
ClubFinderErrorTypeFinderNotAvailable = 1117,
ClubFinderErrorTypeGetPostingIds = 1118,
ClubFinderErrorTypeJoinApplication = 1119,
ClubFinderErrorTypeRealmNotEligible = 1120,
ClubFinderErrorTypeFlaggedRename = 1121,
ClubFinderErrorTypeFlaggedDescriptionChange = 1122,
ItemInteractionNotEnoughGold = 1123,
ItemInteractionNotEnoughCurrency = 1124,
ItemInteractionNoConversionOutput = 1125,
PlayerChoiceErrorPendingChoice = 1126,
SoulbindInvalidConduit = 1127,
SoulbindInvalidConduitItem = 1128,
SoulbindInvalidTalent = 1129,
SoulbindDuplicateConduit = 1130,
ActivateSoulbindS = 1131,
ActivateSoulbindFailedRestArea = 1132,
CantUseProfanity = 1133,
NotInPetBattle = 1134,
NotInNpe = 1135,
NoSpec = 1136,
NoDominationshardOverwrite = 1137,
UseWeeklyRewardsDisabled = 1138,
CrossFactionGroupJoined = 1139,
CantTargetUnfriendlyInOverworld = 1140,
EquipablespellsSlotsFull = 1141,
ItemModAppearanceGroupAlreadyKnown = 1142,
CantBulkSellItemWithRefund = 1143,
NoSoulboundItemInAccountBank = 1144,
NoRefundableItemInAccountBank = 1145,
CantDeleteInAccountBank = 1146,
NoImmediateContainerInAccountBank = 1147,
NoOpenImmediateContainerInAccountBank = 1148,
CantTradeAccountItem = 1149,
NoAccountInventoryLock = 1150,
BankNotAccessible = 1151,
TooManyAccountBankTabs = 1152,
AccountBankTabNotUnlocked = 1153,
AccountMoneyLocked = 1154,
BankTabInvalidName = 1155,
BankTabInvalidText = 1156,
WowLabsPartyErrorTypePartyIsFull = 1157,
WowLabsPartyErrorTypeMaxInviteSent = 1158,
WowLabsPartyErrorTypePlayerAlreadyInvited = 1159,
WowLabsPartyErrorTypePartyInviteInvalid = 1160,
WowLabsLobbyMatchmakerErrorEnterQueueFailed = 1161,
WowLabsLobbyMatchmakerErrorLeaveQueueFailed = 1162,
WowLabsSetWowLabsAreaIdFailed = 1163,
PlunderstormCannotQueue = 1164,
TargetIsSelfFoundCannotTrade = 1165,
PlayerIsSelfFoundCannotTrade = 1166,
MailRecepientIsSelfFoundCannotReceiveMail = 1167,
PlayerIsSelfFoundCannotSendMail = 1168,
PlayerIsSelfFoundCannotUseAuctionHouse = 1169,
MailTargetCannotReceiveMail = 1170,
RemixInvalidTransferRequest = 1171,
CurrencyTransferInvalidCharacter = 1172,
CurrencyTransferInvalidCurrency = 1173,
CurrencyTransferInsufficientCurrency = 1174,
CurrencyTransferMaxQuantity = 1175,
CurrencyTransferNoValidSource = 1176,
CurrencyTransferCharacterLoggedIn = 1177,
CurrencyTransferServerError = 1178,
CurrencyTransferUnmetRequirements = 1179,
CurrencyTransferTransactionInProgress = 1180,
}
public enum SceneFlags
@@ -2618,6 +2618,13 @@ namespace Framework.Constants
Unk331 = 331,
Unk332 = 332,
Unk333 = 333,
Unk334 = 334,
Unk335 = 335,
Unk336 = 336,
Unk337 = 337,
Unk338 = 338,
Unk339 = 339,
Unk340 = 340,
TotalSpellEffects
}
@@ -5,16 +5,16 @@ using System.Security.Cryptography;
namespace Framework.Cryptography
{
public class SessionKeyGenerator256
public class SessionKeyGenerator512
{
public SessionKeyGenerator256(byte[] buff, int size = 0)
public SessionKeyGenerator512(byte[] buff, int size = 0)
{
if (size == 0)
size = buff.Length;
int halfSize = size / 2;
sh = SHA256.Create();
sh = SHA512.Create();
sh.TransformFinalBlock(buff, 0, halfSize);
o1 = sh.Hash;
@@ -48,7 +48,7 @@ namespace Framework.Cryptography
taken = 0;
}
SHA256 sh;
SHA512 sh;
uint taken;
byte[] o0 = new byte[32];
byte[] o1 = new byte[32];
+81
View File
@@ -52,6 +52,51 @@ namespace Framework.Cryptography
public byte[] Digest { get; private set; }
}
public class Sha512
{
public Sha512()
{
sha = SHA512.Create();
sha.Initialize();
}
public void Process(byte[] data, int length)
{
sha.TransformBlock(data, 0, length, data, 0);
}
public void Process(uint data)
{
var bytes = BitConverter.GetBytes(data);
sha.TransformBlock(bytes, 0, 4, bytes, 0);
}
public void Process(string data)
{
var bytes = Encoding.UTF8.GetBytes(data);
sha.TransformBlock(bytes, 0, bytes.Length, bytes, 0);
}
public void Finish(byte[] data)
{
sha.TransformFinalBlock(data, 0, data.Length);
Digest = sha.Hash;
}
public void Finish(byte[] data, int offset, int length)
{
sha.TransformFinalBlock(data, offset, length);
Digest = sha.Hash;
}
SHA512 sha;
public byte[] Digest { get; private set; }
}
public class HmacHash : HMACSHA1
{
public HmacHash(byte[] key) : base(key)
@@ -132,4 +177,40 @@ namespace Framework.Cryptography
public byte[] Digest { get; private set; }
}
public class HmacSha512 : HMACSHA512
{
public HmacSha512(byte[] key) : base(key)
{
Initialize();
}
public void Process(byte[] data, int length)
{
TransformBlock(data, 0, length, data, 0);
}
public void Process(uint data)
{
var bytes = BitConverter.GetBytes(data);
TransformBlock(bytes, 0, bytes.Length, bytes, 0);
}
public void Process(string data)
{
var bytes = Encoding.ASCII.GetBytes(data);
TransformBlock(bytes, 0, bytes.Length, bytes, 0);
}
public void Finish(byte[] data, int length)
{
TransformFinalBlock(data, 0, length);
Digest = Hash;
}
public byte[] Digest { get; private set; }
}
}
@@ -895,8 +895,9 @@ namespace Framework.Database
// LfgDungeons.db2
PrepareStatement(HotfixStatements.SEL_LFG_DUNGEONS, "SELECT ID, Name, Description, TypeID, Subtype, Faction, IconTextureFileID, RewardsBgTextureFileID, " +
"PopupBgTextureFileID, ExpansionLevel, MapID, DifficultyID, MinGear, GroupID, OrderIndex, RequiredPlayerConditionId, RandomID, ScenarioID, " +
"FinalEncounterID, CountTank, CountHealer, CountDamage, MinCountTank, MinCountHealer, MinCountDamage, BonusReputationAmount, MentorItemLevel, " +
"MentorCharLevel, MaxPremadeGroupSize, ContentTuningID, Flags1, Flags2 FROM lfg_dungeons WHERE (`VerifiedBuild` > 0) = ?");
"FinalEncounterID, CountTank, CountHealer, CountDamage, MinCountTank, MinCountHealer, MinCountDamage, MaxPremadeCountTank, " +
"MaxPremadeCountHealer, MaxPremadeCountDamage, BonusReputationAmount, MentorItemLevel, MentorCharLevel, MaxPremadeGroupSize, ContentTuningID, " +
"Flags1, Flags2 FROM lfg_dungeons WHERE (`VerifiedBuild` > 0) = ?");
PrepareStatement(HotfixStatements.SEL_LFG_DUNGEONS_LOCALE, "SELECT ID, Name_lang, Description_lang FROM lfg_dungeons_locale WHERE (`VerifiedBuild` > 0) = ?" +
" AND locale = ?");
@@ -940,7 +941,7 @@ namespace Framework.Database
" AND locale = ?");
// MapDifficulty.db2
PrepareStatement(HotfixStatements.SEL_MAP_DIFFICULTY, "SELECT ID, Message, DifficultyID, LockID, ResetInterval, MaxPlayers, ItemContext, " +
PrepareStatement(HotfixStatements.SEL_MAP_DIFFICULTY, "SELECT Message, ID, DifficultyID, LockID, ResetInterval, MaxPlayers, ItemContext, " +
"ItemContextPickerID, Flags, ContentTuningID, WorldStateExpressionID, MapID FROM map_difficulty WHERE (`VerifiedBuild` > 0) = ?");
PrepareStatement(HotfixStatements.SEL_MAP_DIFFICULTY_LOCALE, "SELECT ID, Message_lang FROM map_difficulty_locale WHERE (`VerifiedBuild` > 0) = ? AND locale = ?");
@@ -1028,8 +1029,8 @@ namespace Framework.Database
PrepareStatement(HotfixStatements.SEL_PHASE_X_PHASE_GROUP, "SELECT ID, PhaseID, PhaseGroupID FROM phase_x_phase_group WHERE (`VerifiedBuild` > 0) = ?");
// PlayerCondition.db2
PrepareStatement(HotfixStatements.SEL_PLAYER_CONDITION, "SELECT ID, RaceMask, FailureDescription, ClassMask, SkillLogic, LanguageID, MinLanguage, " +
"MaxLanguage, MaxFactionID, MaxReputation, ReputationLogic, CurrentPvpFaction, PvpMedal, PrevQuestLogic, CurrQuestLogic, " +
PrepareStatement(HotfixStatements.SEL_PLAYER_CONDITION, "SELECT ID, RaceMask, FailureDescription, MinLevel, MaxLevel, ClassMask, SkillLogic, LanguageID, " +
"MinLanguage, MaxLanguage, MaxFactionID, MaxReputation, ReputationLogic, CurrentPvpFaction, PvpMedal, PrevQuestLogic, CurrQuestLogic, " +
"CurrentCompletedQuestLogic, SpellLogic, ItemLogic, ItemFlags, AuraSpellLogic, WorldStateExpressionID, WeatherID, PartyStatus, " +
"LifetimeMaxPVPRank, AchievementLogic, Gender, NativeGender, AreaLogic, LfgLogic, CurrencyLogic, QuestKillID, QuestKillLogic, " +
"MinExpansionLevel, MaxExpansionLevel, MinAvgItemLevel, MaxAvgItemLevel, MinAvgEquippedItemLevel, MaxAvgEquippedItemLevel, PhaseUseFlags, " +
@@ -1624,7 +1625,7 @@ namespace Framework.Database
// Vignette.db2
PrepareStatement(HotfixStatements.SEL_VIGNETTE, "SELECT ID, Name, PlayerConditionID, VisibleTrackingQuestID, QuestFeedbackEffectID, Flags, MaxHeight, " +
"MinHeight, VignetteType, RewardQuestID, UiWidgetSetID FROM vignette WHERE (`VerifiedBuild` > 0) = ?");
"MinHeight, VignetteType, RewardQuestID, UiWidgetSetID, UiMapPinInfoID, ObjectiveType FROM vignette WHERE (`VerifiedBuild` > 0) = ?");
PrepareStatement(HotfixStatements.SEL_VIGNETTE_LOCALE, "SELECT ID, Name_lang FROM vignette_locale WHERE (`VerifiedBuild` > 0) = ? AND locale = ?");
// WmoAreaTable.db2
+7 -7
View File
@@ -452,14 +452,14 @@ namespace Game.DataStorage
}
// Check loaded DB2 files proper version
if (!AreaTableStorage.ContainsKey(15913) || // last area added in 11.0.5 (57171)
!CharTitlesStorage.ContainsKey(871) || // last char title added in 11.0.5 (57171)
if (!AreaTableStorage.ContainsKey(16108) || // last area added in 11.0.7 (58162)
!CharTitlesStorage.ContainsKey(876) || // last char title added in 11.0.7 (58162)
!FlightCapabilityStorage.ContainsKey(1) || // default flight capability (required)
!GemPropertiesStorage.ContainsKey(4251) || // last gem property added in 11.0.5 (57171)
!ItemStorage.ContainsKey(233014) || // last item added in 11.0.5 (57171)
!ItemExtendedCostStorage.ContainsKey(9647) || // last item extended cost added in 11.0.5 (57171)
!MapStorage.ContainsKey(2792) || // last map added in 11.0.5 (57171)
!SpellNameStorage.ContainsKey(474722)) // last spell added in 11.0.5 (57171)
!GemPropertiesStorage.ContainsKey(4266) || // last gem property added in 11.0.7 (58162)
!ItemStorage.ContainsKey(235551) || // last item added in 11.0.7 (58162)
!ItemExtendedCostStorage.ContainsKey(9918) || // last item extended cost added in 11.0.7 (58162)
!MapStorage.ContainsKey(2829) || // last map added in 11.0.7 (58162)
!SpellNameStorage.ContainsKey(1218101)) // last spell added in 11.0.7 (58162)
{
Log.outFatal(LogFilter.ServerLoading, "You have _outdated_ DB2 files. Please extract correct versions from current using client.");
Environment.Exit(1);
+1 -1
View File
@@ -111,7 +111,7 @@ namespace Game.DataStorage
public int LanguageID;
public int ConditionID;
public ushort EmotesID;
public byte Flags;
public ushort Flags;
public uint ChatBubbleDurationMs;
public int VoiceOverPriorityID;
public uint[] SoundKitID = new uint[2];
@@ -50,6 +50,9 @@ namespace Game.DataStorage
public byte MinCountTank;
public byte MinCountHealer;
public byte MinCountDamage;
public byte MaxPremadeCountTank;
public byte MaxPremadeCountHealer;
public byte MaxPremadeCountDamage;
public ushort BonusReputationAmount;
public ushort MentorItemLevel;
public byte MentorCharLevel;
+1 -1
View File
@@ -122,8 +122,8 @@ namespace Game.DataStorage
public sealed class MapDifficultyRecord
{
public uint Id;
public LocalizedString Message; // m_message_lang (text showed when transfer to map failed)
public uint Id;
public uint DifficultyID;
public int LockID;
public MapDifficultyResetInterval ResetInterval;
@@ -63,6 +63,8 @@ namespace Game.DataStorage
public uint Id;
public long RaceMask;
public string FailureDescription;
public ushort MinLevel;
public ushort MaxLevel;
public int ClassMask;
public uint SkillLogic;
public int LanguageID;
@@ -129,6 +129,8 @@ namespace Game.DataStorage
public sbyte VignetteType;
public int RewardQuestID;
public int UiWidgetSetID;
public int UiMapPinInfoID;
public sbyte ObjectiveType;
public bool HasFlag(VignetteFlags vignetteFlags) { return (Flags & (int)vignetteFlags) != 0; }
public bool IsInfiniteAOI()
+4 -4
View File
@@ -2576,10 +2576,10 @@ namespace Game.Entities
public void SetItemFlag(ItemFieldFlags flags) { SetUpdateFieldFlagValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.DynamicFlags), (uint)flags); }
public void RemoveItemFlag(ItemFieldFlags flags) { RemoveUpdateFieldFlagValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.DynamicFlags), (uint)flags); }
public void ReplaceAllItemFlags(ItemFieldFlags flags) { SetUpdateFieldValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.DynamicFlags), (uint)flags); }
public bool HasItemFlag2(ItemFieldFlags2 flag) { return (m_itemData.DynamicFlags2 & (uint)flag) != 0; }
public void SetItemFlag2(ItemFieldFlags2 flags) { SetUpdateFieldFlagValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.DynamicFlags2), (uint)flags); }
public void RemoveItemFlag2(ItemFieldFlags2 flags) { RemoveUpdateFieldFlagValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.DynamicFlags2), (uint)flags); }
public void ReplaceAllItemFlags2(ItemFieldFlags2 flags) { SetUpdateFieldValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.DynamicFlags2), (uint)flags); }
public bool HasItemZoneFlag(ItemZoneFlags flag) { return (m_itemData.ZoneFlags & (uint)flag) != 0; }
public void SetItemZoneFlag(ItemZoneFlags flags) { SetUpdateFieldFlagValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.ZoneFlags), (uint)flags); }
public void RemoveItemZoneFlag(ItemZoneFlags flags) { RemoveUpdateFieldFlagValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.ZoneFlags), (uint)flags); }
public void ReplaceAllItemZoneFlags(ItemZoneFlags flags) { SetUpdateFieldValue(m_values.ModifyValue(m_itemData).ModifyValue(m_itemData.ZoneFlags), (uint)flags); }
public Bag ToBag() { return IsBag() ? this as Bag : null; }
public AzeriteItem ToAzeriteItem() { return IsAzeriteItem() ? this as AzeriteItem : null; }
@@ -396,7 +396,7 @@ namespace Game.Entities
public UpdateField<ulong> ArtifactXP = new(0, 15);
public UpdateField<byte> ItemAppearanceModID = new(0, 16);
public UpdateField<ItemModList> Modifiers = new(0, 17);
public UpdateField<uint> DynamicFlags2 = new(0, 18);
public UpdateField<uint> ZoneFlags = new(0, 18);
public UpdateField<ItemBonusKey> ItemBonusKey = new(0, 19);
public UpdateField<ushort> DEBUGItemLevel = new(0, 20);
public UpdateFieldArray<int> SpellCharges = new(5, 21, 22);
@@ -441,7 +441,7 @@ namespace Game.Entities
data.WriteInt32(Gems.Size());
if (fieldVisibilityFlags.HasFlag(UpdateFieldFlag.Owner))
{
data.WriteUInt32(DynamicFlags2);
data.WriteUInt32(ZoneFlags);
}
ItemBonusKey.GetValue().Write(data);
if (fieldVisibilityFlags.HasFlag(UpdateFieldFlag.Owner))
@@ -584,7 +584,7 @@ namespace Game.Entities
}
if (changesMask[18])
{
data.WriteUInt32(DynamicFlags2);
data.WriteUInt32(ZoneFlags);
}
if (changesMask[19])
{
@@ -640,7 +640,7 @@ namespace Game.Entities
ClearChangesMask(ArtifactXP);
ClearChangesMask(ItemAppearanceModID);
ClearChangesMask(Modifiers);
ClearChangesMask(DynamicFlags2);
ClearChangesMask(ZoneFlags);
ClearChangesMask(ItemBonusKey);
ClearChangesMask(DEBUGItemLevel);
ClearChangesMask(SpellCharges);
@@ -4208,17 +4208,14 @@ namespace Game.Entities
public class QuestSession : HasChangesMask
{
public UpdateField<ObjectGuid> Owner = new(0, 1);
public UpdateFieldArray<ulong> QuestCompleted = new(1000, 2, 3);
public UpdateField<BitVector> QuestCompleted = new(0, 2);
public QuestSession() : base(1003) { }
public QuestSession() : base(3) { }
public void WriteCreate(WorldPacket data, Player owner, Player receiver)
{
data.WritePackedGuid(Owner);
for (int i = 0; i < 1000; ++i)
{
data.WriteUInt64(QuestCompleted[i]);
}
QuestCompleted.GetValue().WriteCreate(data, owner, receiver);
}
public void WriteUpdate(WorldPacket data, bool ignoreChangesMask, Player owner, Player receiver)
@@ -4227,10 +4224,7 @@ namespace Game.Entities
if (ignoreChangesMask)
changesMask.SetAll();
data.WriteBits(changesMask.GetBlocksMask(0), 32);
for (uint i = 0; i < 32; ++i)
if (changesMask.GetBlock(i) != 0)
data.WriteBits(changesMask.GetBlock(i), 32);
data.WriteBits(changesMask.GetBlock(0), 3);
data.FlushBits();
if (changesMask[0])
@@ -4239,15 +4233,10 @@ namespace Game.Entities
{
data.WritePackedGuid(Owner);
}
}
if (changesMask[2])
{
for (int i = 0; i < 1000; ++i)
if (changesMask[2])
{
if (changesMask[3 + i])
{
data.WriteUInt64(QuestCompleted[i]);
}
QuestCompleted.GetValue().WriteUpdate(data, ignoreChangesMask, owner, receiver);
}
}
}
+3 -3
View File
@@ -1508,7 +1508,7 @@ namespace Game.Entities
}
}
pItem.SetItemFlag2(ItemFieldFlags2.Equipped);
pItem.SetItemZoneFlag(ItemZoneFlags.Equipped);
if (IsInWorld && update)
{
@@ -1681,7 +1681,7 @@ namespace Game.Entities
byte slot = (byte)(pos & 255);
VisualizeItem(slot, pItem);
pItem.SetItemFlag2(ItemFieldFlags2.Equipped);
pItem.SetItemZoneFlag(ItemZoneFlags.Equipped);
if (IsInWorld)
{
@@ -1792,7 +1792,7 @@ namespace Game.Entities
_ApplyItemMods(pItem, slot, false, update);
pItem.RemoveItemFlag2(ItemFieldFlags2.Equipped);
pItem.RemoveItemZoneFlag(ItemZoneFlags.Equipped);
// remove item dependent auras and casts (only weapon and armor slots)
if (slot < ProfessionSlots.End)
+17 -8
View File
@@ -2420,15 +2420,22 @@ namespace Game.Entities
if (questBit == 0)
return;
uint fieldOffset = (uint)((questBit - 1) / ActivePlayerData.QuestCompletedBitsPerBlock);
if (fieldOffset >= ActivePlayerData.QuestCompletedBitsSize)
return;
int fieldOffset = (int)((questBit - 1) / ActivePlayerData.QuestCompletedBitsPerBlock);
ulong flag = 1ul << (((int)questBit - 1) % ActivePlayerData.QuestCompletedBitsPerBlock);
if (fieldOffset < ActivePlayerData.QuestCompletedBitsSize)
{
if (completed)
SetUpdateFieldFlagValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.QuestCompleted,fieldOffset), flag);
else
RemoveUpdateFieldFlagValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.QuestCompleted, fieldOffset), flag);
}
BitVectors bitVectors = m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.BitVectors);
BitVector bitVector = bitVectors.ModifyValue(bitVectors.Values, (int)PlayerDataFlag.CharacterQuestCompletedIndex);
if (completed)
SetUpdateFieldFlagValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.QuestCompleted, (int)fieldOffset), flag);
SetUpdateFieldFlagValue(bitVector.ModifyValue(bitVector.Values, fieldOffset), flag);
else
RemoveUpdateFieldFlagValue(ref m_values.ModifyValue(m_activePlayerData).ModifyValue(m_activePlayerData.QuestCompleted, (int)fieldOffset), flag);
RemoveUpdateFieldFlagValue(bitVector.ModifyValue(bitVector.Values, fieldOffset), flag);
}
public void AreaExploredOrEventHappens(uint questId)
@@ -2857,7 +2864,8 @@ namespace Game.Entities
return objective;
}
return null;
};
}
;
QuestObjective objective = findObjectiveForItem((int)itemId);
if (objective != null)
@@ -2892,7 +2900,8 @@ namespace Game.Entities
return true;
return false;
};
}
;
bool hasObjectiveTypeForCurrency(QuestObjectiveType type) => m_questObjectiveStatus.LookupByKey((type, currencyId)).Any(isCompletableObjective);
if (hasObjectiveTypeForCurrency(QuestObjectiveType.Currency))
+13
View File
@@ -21,6 +21,11 @@ namespace Game.Entities
}
}
public static void UpdateHealth(VignetteData vignette, Unit owner)
{
vignette.HealthPercent = (float)(owner.GetHealth()) / (float)(owner.GetMaxHealth()); // converted to percentage in lua
}
public static void SendVignetteUpdate(VignetteData vignette, WorldObject owner)
{
if (!owner.IsInWorld)
@@ -72,6 +77,9 @@ namespace Game.Entities
vignette.Data = vignetteData;
vignette.ZoneID = owner.GetZoneId(); // not updateable
UpdatePosition(vignette, owner);
Unit unitOwner = owner.ToUnit();
if (unitOwner != null)
UpdateHealth(vignette, unitOwner);
if (vignetteData.IsInfiniteAOI())
owner.GetMap().AddInfiniteAOIVignette(vignette);
@@ -84,6 +92,9 @@ namespace Game.Entities
public static void Update(VignetteData vignette, WorldObject owner)
{
UpdatePosition(vignette, owner);
Unit unitOwner = owner.ToUnit();
if (unitOwner != null)
UpdateHealth(vignette, unitOwner);
if (vignette.Data.IsInfiniteAOI())
vignette.NeedUpdate = true;
@@ -129,6 +140,7 @@ namespace Game.Entities
public uint ZoneID;
public uint WMOGroupID;
public uint WMODoodadPlacementID;
public float HealthPercent = 1.0f;
public bool NeedUpdate;
public void FillPacket(VignetteDataSet dataSet)
@@ -142,6 +154,7 @@ namespace Game.Entities
data.ZoneID = ZoneID;
data.WMOGroupID = WMOGroupID;
data.WMODoodadPlacementID = WMODoodadPlacementID;
data.HealthPercent = HealthPercent;
dataSet.Data.Add(data);
}
@@ -53,7 +53,7 @@ namespace Game.Networking.Packets
_worldPacket.WriteUInt8(DosZeroBits);
}
public byte[] Challenge = new byte[16];
public byte[] Challenge = new byte[32];
public byte[] DosChallenge = new byte[32]; // Encryption seeds
public byte DosZeroBits;
}
@@ -83,7 +83,7 @@ namespace Game.Networking.Packets
public uint RegionID;
public uint BattlegroupID;
public uint RealmID;
public Array<byte> LocalChallenge = new(16);
public Array<byte> LocalChallenge = new(32);
public byte[] Digest = new byte[24];
public ulong DosResponse;
public string RealmJoinTicket;
@@ -288,7 +288,9 @@ namespace Game.Networking.Packets
hash.Process((uint)Payload.Where.Type);
hash.Finish(BitConverter.GetBytes(Payload.Port));
Payload.Signature = RsaCrypt.RSA.SignHash(hash.Digest, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1).Reverse().ToArray();
var signHash = RsaCrypt.RSA.SignHash(hash.Digest, HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
signHash.Reverse();
Payload.Signature = signHash;
_worldPacket.WriteBytes(Payload.Signature, (uint)Payload.Signature.Length);
_worldPacket.WriteBytes(whereBuffer);
@@ -341,7 +343,7 @@ namespace Game.Networking.Packets
public ulong DosResponse;
public ulong Key;
public byte[] LocalChallenge = new byte[16];
public byte[] LocalChallenge = new byte[32];
public byte[] Digest = new byte[24];
}
@@ -372,7 +374,8 @@ namespace Game.Networking.Packets
bool Enabled;
static byte[] expandedPrivateKey;
static byte[] EnableEncryptionSeed = { 0x90, 0x9C, 0xD0, 0x50, 0x5A, 0x2C, 0x14, 0xDD, 0x5C, 0x2C, 0xC0, 0x64, 0x14, 0xF3, 0xFE, 0xC9 };
static byte[] EnableEncryptionSeed = { 0x66, 0xBE, 0x29, 0x79, 0xEF, 0xF2, 0xD5, 0xB5, 0x61, 0x53, 0xF6, 0x5F, 0x45, 0xAE, 0x81, 0xCB,
0x32, 0xEC, 0x94, 0xEC, 0x75, 0xB3, 0x5F, 0x44, 0x6A, 0x63, 0x43, 0x67, 0x17, 0x20, 0x44, 0x34 };
static byte[] EnableEncryptionContext = { 0xA7, 0x1F, 0xB6, 0x9B, 0xC9, 0x7C, 0xDD, 0x96, 0xE9, 0xBB, 0xB8, 0x21, 0x39, 0x8D, 0x5A, 0xD4 };
static byte[] EnterEncryptedModePrivateKey =
@@ -396,7 +399,7 @@ namespace Game.Networking.Packets
public override void Write()
{
HmacSha256 toSign = new(EncryptionKey);
HmacSha512 toSign = new(EncryptionKey);
toSign.Process(BitConverter.GetBytes(Enabled), 1);
toSign.Finish(EnableEncryptionSeed, 16);
@@ -100,6 +100,7 @@ namespace Game.Networking.Packets
_worldPacket.WriteBits(Channel.GetByteCount(), 7);
_worldPacket.WriteBits(ChannelWelcomeMsg.GetByteCount(), 11);
_worldPacket.WriteUInt32((uint)ChannelFlags);
_worldPacket.WriteUInt8(Unknown1107);
_worldPacket.WriteInt32(ChatChannelID);
_worldPacket.WriteUInt64(InstanceID);
_worldPacket.WritePackedGuid(ChannelGUID);
@@ -113,6 +114,7 @@ namespace Game.Networking.Packets
public ChannelFlags ChannelFlags;
public string Channel = "";
public ObjectGuid ChannelGUID;
public byte Unknown1107;
}
public class ChannelNotifyLeft : ServerPacket
@@ -849,9 +849,18 @@ namespace Game.Networking.Packets
public class LogoutComplete : ServerPacket
{
SwitchGameModeData SwitchGameMode;
public LogoutComplete() : base(ServerOpcodes.LogoutComplete) { }
public override void Write() { }
public override void Write()
{
_worldPacket.WriteBit(SwitchGameMode != null);
_worldPacket.FlushBits();
if (SwitchGameMode != null)
SwitchGameMode.Write(_worldPacket);
}
}
public class LogoutCancel : ClientPacket
@@ -1323,4 +1332,56 @@ namespace Game.Networking.Packets
member.Write(data);
}
}
class GameModeData
{
public int Unknown_1107_0;
public ObjectGuid Guid;
public byte GameMode;
public int MapID = 0;
public byte Unknown_1107_1;
public byte Unknown_1107_2;
public byte Unknown_1107_3;
public Array<ChrCustomizationChoice> Customizations = new(250);
public Array<ChrCustomizationChoice> Unknown_1107_4 = new(250);
public void Write(WorldPacket data)
{
data.WriteInt32(Unknown_1107_0);
data.WritePackedGuid(Guid);
data.WriteUInt8(GameMode);
data.WriteInt32(MapID);
data.WriteUInt8(Unknown_1107_1);
data.WriteUInt8(Unknown_1107_2);
data.WriteUInt8(Unknown_1107_3);
data.WriteInt32(Customizations.Count);
data.WriteInt32(Unknown_1107_4.Count);
foreach (ChrCustomizationChoice customization in Customizations)
{
data.WriteUInt32(customization.ChrCustomizationOptionID);
data.WriteUInt32(customization.ChrCustomizationChoiceID);
}
foreach (ChrCustomizationChoice customization in Unknown_1107_4)
{
data.WriteUInt32(customization.ChrCustomizationOptionID);
data.WriteUInt32(customization.ChrCustomizationChoiceID);
}
}
}
class SwitchGameModeData
{
public bool IsFastLogin;
public GameModeData Current;
public GameModeData New;
public void Write(WorldPacket data)
{
data.WriteBits(IsFastLogin, 1);
Current.Write(data);
New.Write(data);
}
}
}
+1 -1
View File
@@ -704,7 +704,7 @@ namespace Game.Networking.Packets
data.WriteBit(VotePassed);
data.WriteBit(MyVoteCompleted);
data.WriteBit(MyVote);
data.WriteBits(Reason.GetByteCount(), 8);
data.WriteBits(Reason.GetByteCount(), 9);
data.WritePackedGuid(Target);
data.WriteUInt32(TotalVotes);
data.WriteUInt32(BootVotes);
+22 -22
View File
@@ -585,18 +585,21 @@ namespace Game.Networking.Packets
public class StandStateChange : ClientPacket
{
public UnitStandStateType StandState;
public StandStateChange(WorldPacket packet) : base(packet) { }
public override void Read()
{
StandState = (UnitStandStateType)_worldPacket.ReadUInt32();
StandState = (UnitStandStateType)_worldPacket.ReadUInt8();
}
public UnitStandStateType StandState;
}
public class StandStateUpdate : ServerPacket
{
uint AnimKitID;
UnitStandStateType State;
public StandStateUpdate(UnitStandStateType state, uint animKitId) : base(ServerOpcodes.StandStateUpdate)
{
State = state;
@@ -605,12 +608,9 @@ namespace Game.Networking.Packets
public override void Write()
{
_worldPacket.WriteUInt32(AnimKitID);
_worldPacket.WriteUInt8((byte)State);
_worldPacket.WriteUInt32(AnimKitID);
}
uint AnimKitID;
UnitStandStateType State;
}
public class SetAnimTier : ServerPacket
@@ -630,6 +630,13 @@ namespace Game.Networking.Packets
public class StartMirrorTimer : ServerPacket
{
public MirrorTimerType Timer;
public int Scale;
public int MaxValue;
public int SpellID;
public int Value;
public bool Paused;
public StartMirrorTimer(MirrorTimerType timer, int value, int maxValue, int scale, int spellID, bool paused) : base(ServerOpcodes.StartMirrorTimer)
{
Timer = timer;
@@ -642,7 +649,7 @@ namespace Game.Networking.Packets
public override void Write()
{
_worldPacket.WriteInt32((int)Timer);
_worldPacket.WriteUInt8((byte)Timer);
_worldPacket.WriteInt32(Value);
_worldPacket.WriteInt32(MaxValue);
_worldPacket.WriteInt32(Scale);
@@ -650,17 +657,13 @@ namespace Game.Networking.Packets
_worldPacket.WriteBit(Paused);
_worldPacket.FlushBits();
}
public int Scale;
public int MaxValue;
public MirrorTimerType Timer;
public int SpellID;
public int Value;
public bool Paused;
}
public class PauseMirrorTimer : ServerPacket
{
public MirrorTimerType Timer;
public bool Paused = true;
public PauseMirrorTimer(MirrorTimerType timer, bool paused) : base(ServerOpcodes.PauseMirrorTimer)
{
Timer = timer;
@@ -669,17 +672,16 @@ namespace Game.Networking.Packets
public override void Write()
{
_worldPacket.WriteInt32((int)Timer);
_worldPacket.WriteUInt8((byte)Timer);
_worldPacket.WriteBit(Paused);
_worldPacket.FlushBits();
}
public bool Paused = true;
public MirrorTimerType Timer;
}
public class StopMirrorTimer : ServerPacket
{
public MirrorTimerType Timer;
public StopMirrorTimer(MirrorTimerType timer) : base(ServerOpcodes.StopMirrorTimer)
{
Timer = timer;
@@ -687,10 +689,8 @@ namespace Game.Networking.Packets
public override void Write()
{
_worldPacket.WriteInt32((int)Timer);
_worldPacket.WriteUInt8((byte)Timer);
}
public MirrorTimerType Timer;
}
public class ExplorationExperience : ServerPacket
@@ -10,12 +10,13 @@ namespace Game.Networking.Packets
public int BattlePetSpeciesID;
public int TransmogSetID;
public int ItemModifiedAppearanceID;
public int Field_14;
public int Field_18;
public int TransmogIllusionID;
public int ToyID;
public int Price;
public int OriginalPrice;
public long AvailableUntil;
public bool Disabled;
public bool Field_41;
public bool DoesNotExpire;
public void Write(WorldPacket data)
{
@@ -24,12 +25,13 @@ namespace Game.Networking.Packets
data.WriteInt32(BattlePetSpeciesID);
data.WriteInt32(TransmogSetID);
data.WriteInt32(ItemModifiedAppearanceID);
data.WriteInt32(Field_14);
data.WriteInt32(Field_18);
data.WriteInt32(TransmogIllusionID);
data.WriteInt32(ToyID);
data.WriteInt32(Price);
data.WriteInt32(OriginalPrice);
data.WriteInt64(AvailableUntil);
data.WriteBit(Disabled);
data.WriteBit(Field_41);
data.WriteBit(DoesNotExpire);
data.FlushBits();
}
}
+4 -2
View File
@@ -90,7 +90,8 @@ namespace Game.Networking.Packets
_worldPacket.WriteUInt16(CreatureFamily);
_worldPacket.WriteUInt16(Specialization);
_worldPacket.WriteUInt32(TimeLimit);
_worldPacket.WriteUInt16((ushort)((byte)CommandState | (Flag << 16)));
_worldPacket.WriteUInt8((byte)CommandState);
_worldPacket.WriteUInt8(Flag);
_worldPacket.WriteUInt8((byte)ReactState);
foreach (uint actionButton in ActionButtons)
@@ -362,7 +363,8 @@ namespace Game.Networking.Packets
public override void Write()
{
_worldPacket.WritePackedGuid(PetGUID);
_worldPacket.WriteUInt16((ushort)((int)CommandState | Flag << 8));
_worldPacket.WriteUInt8((byte)CommandState);
_worldPacket.WriteUInt8(Flag);
_worldPacket.WriteUInt8((byte)ReactState);
}
}
@@ -297,11 +297,11 @@ namespace Game.Networking.Packets
data.WriteInt32(StaticType);
data.WriteUInt32(Muid);
data.WriteBits(Title.GetByteCount(), 7);
data.WriteBits(Title.GetByteCount(), 8);
data.WriteBits(BodyText.GetByteCount(), 12);
for (byte i = 0; i < Choicetext.Length; i++)
data.WriteBits(Choicetext[i].GetByteCount(), 6);
data.WriteBits(Choicetext[i].GetByteCount(), 7);
data.FlushBits();
@@ -95,20 +95,20 @@ namespace Game.Networking.Packets
_worldPacket.WriteBit(SellAllJunkEnabled);
_worldPacket.WriteBit(GroupFinderEnabled);
_worldPacket.WriteBit(LfdEnabled);
_worldPacket.WriteBit(LfrEnabled);
_worldPacket.WriteBit(IsPremadeGroupEnabled);
_worldPacket.WriteBit(PremadeGroupsEnabled);
_worldPacket.WriteBit(UseActivePlayerDataQuestCompleted);
_worldPacket.WriteBit(false); // unused 10.2.7
_worldPacket.WriteBit(GuildEventsEditsEnabled);
_worldPacket.WriteBit(GuildTradeSkillsEnabled);
_worldPacket.WriteBits(Unknown1027.GetByteCount(), 7);
_worldPacket.WriteBit(BNSendWhisperUseV2Services);
_worldPacket.WriteBit(BNSendGameDataUseV2Services);
_worldPacket.WriteBit(IsAccountCurrencyTransferEnabled);
_worldPacket.WriteBit(false); // unused 11.0.7
_worldPacket.WriteBit(LobbyMatchmakerQueueFromMainlineEnabled);
_worldPacket.WriteBit(CanSendLobbyMatchmakerPartyCustomizations);
_worldPacket.FlushBits();
{
@@ -207,15 +207,15 @@ namespace Game.Networking.Packets
public bool IsPlayerContentTrackingEnabled;
public bool SellAllJunkEnabled;
public bool GroupFinderEnabled = true; // classic only
public bool LfdEnabled = true; // classic only
public bool LfrEnabled = true; // classic only
public bool IsPremadeGroupEnabled = true; // classic only
public bool PremadeGroupsEnabled = true;
public bool UseActivePlayerDataQuestCompleted = false; ///< Uses ActivePlayerData::QuestCompleted (legacy) to store completed quest bits instead of ActivePlayerData::BitVectors[9]
public bool GuildEventsEditsEnabled = true;
public bool GuildTradeSkillsEnabled = true;
public bool BNSendWhisperUseV2Services = true; ///< BNSendWhisper will send to v2.WhisperService instead of v1.NotificationService
public bool BNSendGameDataUseV2Services = true; ///< BNSendGameData will send to v2.NotificationService instead of v1.NotificationService
public bool IsAccountCurrencyTransferEnabled;
public bool LobbyMatchmakerQueueFromMainlineEnabled;
public bool CanSendLobbyMatchmakerPartyCustomizations;
public SocialQueueConfig QuickJoinConfig;
public SquelchInfo Squelch;
@@ -487,11 +487,13 @@ namespace Game.Networking.Packets
{
public int Rule;
public int Value;
public float ValueF;
public void Write(WorldPacket data)
{
data.WriteInt32(Rule);
data.WriteInt32(Value);
data.WriteFloat(ValueF);
}
}
@@ -54,9 +54,13 @@ namespace Game.Networking.Packets
_worldPacket.WriteBits(c.Url.GetByteCount(), 11);
_worldPacket.WriteBits(c.WaitTimeOverrideMessage.GetByteCount(), 10);
_worldPacket.WriteBits(c.Title, 24);
_worldPacket.WriteBits(c.Description, 24);
_worldPacket.WriteString(c.Url);
_worldPacket.WriteString(c.WaitTimeOverrideMessage);
_worldPacket.WriteString(c.Title);
_worldPacket.WriteString(c.Description);
}
}
@@ -72,6 +76,8 @@ namespace Game.Networking.Packets
public int WaitTimeOverrideMinutes;
public string Url;
public string WaitTimeOverrideMessage;
public string Title;
public string Description;
}
}
@@ -16,6 +16,9 @@ namespace Game.Networking.Packets
public uint ZoneID;
public uint WMOGroupID;
public uint WMODoodadPlacementID;
public float HealthPercent = 1.0f;
public ushort RecommendedGroupSizeMin;
public ushort RecommendedGroupSizeMax;
public void Write(WorldPacket data)
{
@@ -25,6 +28,9 @@ namespace Game.Networking.Packets
data.WriteUInt32(ZoneID);
data.WriteUInt32(WMOGroupID);
data.WriteUInt32(WMODoodadPlacementID);
data.WriteFloat(HealthPercent);
data.WriteUInt16(RecommendedGroupSizeMin);
data.WriteUInt16(RecommendedGroupSizeMax);
}
}
+32 -28
View File
@@ -21,10 +21,14 @@ namespace Game.Networking
static readonly string ClientConnectionInitialize = "WORLD OF WARCRAFT CONNECTION - CLIENT TO SERVER - V2";
static readonly string ServerConnectionInitialize = "WORLD OF WARCRAFT CONNECTION - SERVER TO CLIENT - V2";
static readonly byte[] AuthCheckSeed = { 0xC5, 0xC6, 0x98, 0x95, 0x76, 0x3F, 0x1D, 0xCD, 0xB6, 0xA1, 0x37, 0x28, 0xB3, 0x12, 0xFF, 0x8A };
static readonly byte[] SessionKeySeed = { 0x58, 0xCB, 0xCF, 0x40, 0xFE, 0x2E, 0xCE, 0xA6, 0x5A, 0x90, 0xB8, 0x01, 0x68, 0x6C, 0x28, 0x0B };
static readonly byte[] ContinuedSessionSeed = { 0x16, 0xAD, 0x0C, 0xD4, 0x46, 0xF9, 0x4F, 0xB2, 0xEF, 0x7D, 0xEA, 0x2A, 0x17, 0x66, 0x4D, 0x2F };
static readonly byte[] EncryptionKeySeed = { 0xE9, 0x75, 0x3C, 0x50, 0x90, 0x93, 0x61, 0xDA, 0x3B, 0x07, 0xEE, 0xFA, 0xFF, 0x9D, 0x41, 0xB8 };
static readonly byte[] AuthCheckSeed = { 0xDE, 0x3A, 0x2A, 0x8E, 0x6B, 0x89, 0x52, 0x66, 0x88, 0x9D, 0x7E, 0x7A, 0x77, 0x1D, 0x5D, 0x1F,
0x4E, 0xD9, 0x0C, 0x23, 0x9B, 0xCD, 0x0E, 0xDC, 0xD2, 0xE8, 0x04, 0x3A, 0x68, 0x64, 0xC7, 0xB0 };
static readonly byte[] SessionKeySeed = { 0xE8, 0x1E, 0x8B, 0x59, 0x27, 0x62, 0x1E, 0xAA, 0x86, 0x15, 0x18, 0xEA, 0xC0, 0xBF, 0x66, 0x8C,
0x6D, 0xBF, 0x83, 0x93, 0xBC, 0xAA, 0x80, 0x52, 0x5B, 0x1E, 0xDC, 0x23, 0xA0, 0x12, 0xB7, 0x50 };
static readonly byte[] ContinuedSessionSeed = { 0x56, 0x5C, 0x61, 0x9C, 0x48, 0x3A, 0x52, 0x1F, 0x61, 0x5D, 0x05, 0x49, 0xB2, 0x9A, 0x39, 0xBF,
0x4B, 0x97, 0xB0, 0x1B, 0xF9, 0x6C, 0xDE, 0xD6, 0x80, 0x1D, 0xAB, 0x26, 0x02, 0xA9, 0x9B, 0x9D };
static readonly byte[] EncryptionKeySeed = { 0x71, 0xC9, 0xED, 0x5A, 0xA7, 0x0E, 0x4D, 0xFF, 0x4C, 0x36, 0xA6, 0x5A, 0x3E, 0x46, 0x8A, 0x4A,
0x5D, 0xA1, 0x48, 0xC8, 0x30, 0x47, 0x4A, 0xDE, 0xF6, 0x0D, 0x6C, 0xBE, 0x6F, 0xE4, 0x55, 0x73 };
static readonly int HeaderSize = 16;
@@ -53,10 +57,10 @@ namespace Game.Networking
public WorldSocket(Socket socket) : base(socket)
{
_connectType = ConnectionType.Realm;
_serverChallenge = Array.Empty<byte>().GenerateRandomKey(16);
_serverChallenge = Array.Empty<byte>().GenerateRandomKey(32);
_worldCrypt = new WorldCrypt();
_encryptKey = new byte[16];
_encryptKey = new byte[32];
_headerBuffer = new SocketBuffer(HeaderSize);
_packetBuffer = new SocketBuffer(0);
@@ -504,14 +508,14 @@ namespace Game.Networking
// For hook purposes, we get Remoteaddress at this point.
var address = GetRemoteIpAddress();
Sha256 digestKeyHash = new();
Sha512 digestKeyHash = new();
digestKeyHash.Process(account.game.KeyData, account.game.KeyData.Length);
digestKeyHash.Finish(clientBuildAuthKey.Key);
HmacSha256 hmac = new(digestKeyHash.Digest);
HmacSha512 hmac = new(digestKeyHash.Digest);
hmac.Process(authSession.LocalChallenge, authSession.LocalChallenge.Count);
hmac.Process(_serverChallenge, 16);
hmac.Finish(AuthCheckSeed, 16);
hmac.Process(_serverChallenge, 32);
hmac.Finish(AuthCheckSeed, AuthCheckSeed.Length);
// Check that Key and account name are the same on client and server
if (!hmac.Digest.Compare(authSession.Digest))
@@ -522,25 +526,25 @@ namespace Game.Networking
return;
}
Sha256 keyData = new();
Sha512 keyData = new();
keyData.Finish(account.game.KeyData);
HmacSha256 sessionKeyHmac = new(keyData.Digest);
sessionKeyHmac.Process(_serverChallenge, 16);
HmacSha512 sessionKeyHmac = new(keyData.Digest);
sessionKeyHmac.Process(_serverChallenge, 32);
sessionKeyHmac.Process(authSession.LocalChallenge, authSession.LocalChallenge.Count);
sessionKeyHmac.Finish(SessionKeySeed, 16);
sessionKeyHmac.Finish(SessionKeySeed, SessionKeySeed.Length);
_sessionKey = new byte[40];
var sessionKeyGenerator = new SessionKeyGenerator256(sessionKeyHmac.Digest, 32);
var sessionKeyGenerator = new SessionKeyGenerator512(sessionKeyHmac.Digest, 32);
sessionKeyGenerator.Generate(_sessionKey, 40);
HmacSha256 encryptKeyGen = new(_sessionKey);
HmacSha512 encryptKeyGen = new(_sessionKey);
encryptKeyGen.Process(authSession.LocalChallenge, authSession.LocalChallenge.Count);
encryptKeyGen.Process(_serverChallenge, 16);
encryptKeyGen.Finish(EncryptionKeySeed, 16);
encryptKeyGen.Process(_serverChallenge, 32);
encryptKeyGen.Finish(EncryptionKeySeed, EncryptionKeySeed.Length);
// only first 16 bytes of the hmac are used
Buffer.BlockCopy(encryptKeyGen.Digest, 0, _encryptKey, 0, 16);
// only first 32 bytes of the hmac are used
Buffer.BlockCopy(encryptKeyGen.Digest, 0, _encryptKey, 0, 32);
PreparedStatement stmt = null;
@@ -714,11 +718,11 @@ namespace Game.Networking
string login = result.Read<string>(0);
_sessionKey = result.Read<byte[]>(1);
HmacSha256 hmac = new(_sessionKey);
HmacSha512 hmac = new(_sessionKey);
hmac.Process(BitConverter.GetBytes(authSession.Key), 8);
hmac.Process(authSession.LocalChallenge, authSession.LocalChallenge.Length);
hmac.Process(_serverChallenge, 16);
hmac.Finish(ContinuedSessionSeed, 16);
hmac.Process(_serverChallenge, 32);
hmac.Finish(ContinuedSessionSeed, ContinuedSessionSeed.Length);
if (!hmac.Digest.Compare(authSession.Digest))
{
@@ -727,13 +731,13 @@ namespace Game.Networking
return;
}
HmacSha256 encryptKeyGen = new(_sessionKey);
HmacSha512 encryptKeyGen = new(_sessionKey);
encryptKeyGen.Process(authSession.LocalChallenge, authSession.LocalChallenge.Length);
encryptKeyGen.Process(_serverChallenge, 16);
encryptKeyGen.Finish(EncryptionKeySeed, 16);
encryptKeyGen.Process(_serverChallenge, 32);
encryptKeyGen.Finish(EncryptionKeySeed, EncryptionKeySeed.Length);
// only first 16 bytes of the hmac are used
Buffer.BlockCopy(encryptKeyGen.Digest, 0, _encryptKey, 0, 16);
// only first 32 bytes of the hmac are used
Buffer.BlockCopy(encryptKeyGen.Digest, 0, _encryptKey, 0, 32);
SendPacket(new EnterEncryptedMode(_encryptKey, true));
await AsyncRead();
+7
View File
@@ -4765,6 +4765,13 @@ namespace Game.Spells
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 331 SPELL_EFFECT_331
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 332 SPELL_EFFECT_332
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 333 SPELL_EFFECT_333
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 334 SPELL_EFFECT_334
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 335 SPELL_EFFECT_335
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 336 SPELL_EFFECT_336
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 337 SPELL_EFFECT_337
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 338 SPELL_EFFECT_338
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 339 SPELL_EFFECT_UI_ACTION
new StaticData(SpellEffectImplicitTargetTypes.None, SpellTargetObjectTypes.None), // 340 SPELL_EFFECT_340
};
#region Fields