diff options
author | Shauren <shauren.trinity@gmail.com> | 2018-09-16 17:04:44 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2018-09-16 17:04:44 +0200 |
commit | 0c38fa1cf4dbec41452b851f214e8dc81f960bf6 (patch) | |
tree | 5a806537529718c9680da952b1c6a908e8f14936 | |
parent | 8901e1d45e4fef64a9d34ffcd16ffa2b42efd445 (diff) |
Core/DataStores: Renamed sandbox scaling to content tuning
-rw-r--r-- | src/server/game/DataStores/DB2Stores.cpp | 4 | ||||
-rw-r--r-- | src/server/game/DataStores/DB2Stores.h | 2 | ||||
-rw-r--r-- | src/server/game/Entities/Item/Item.cpp | 16 | ||||
-rw-r--r-- | src/server/game/Entities/Item/Item.h | 2 |
4 files changed, 12 insertions, 12 deletions
diff --git a/src/server/game/DataStores/DB2Stores.cpp b/src/server/game/DataStores/DB2Stores.cpp index 82bacdf7839..82fc12559c8 100644 --- a/src/server/game/DataStores/DB2Stores.cpp +++ b/src/server/game/DataStores/DB2Stores.cpp @@ -75,6 +75,7 @@ DB2Storage<ChrRacesEntry> sChrRacesStore("ChrRaces.db2", C DB2Storage<ChrSpecializationEntry> sChrSpecializationStore("ChrSpecialization.db2", ChrSpecializationLoadInfo::Instance()); DB2Storage<CinematicCameraEntry> sCinematicCameraStore("CinematicCamera.db2", CinematicCameraLoadInfo::Instance()); DB2Storage<CinematicSequencesEntry> sCinematicSequencesStore("CinematicSequences.db2", CinematicSequencesLoadInfo::Instance()); +DB2Storage<ContentTuningEntry> sContentTuningStore("ContentTuning.db2", ContentTuningLoadInfo::Instance()); DB2Storage<ConversationLineEntry> sConversationLineStore("ConversationLine.db2", ConversationLineLoadInfo::Instance()); DB2Storage<CreatureDisplayInfoEntry> sCreatureDisplayInfoStore("CreatureDisplayInfo.db2", CreatureDisplayInfoLoadInfo::Instance()); DB2Storage<CreatureDisplayInfoExtraEntry> sCreatureDisplayInfoExtraStore("CreatureDisplayInfoExtra.db2", CreatureDisplayInfoExtraLoadInfo::Instance()); @@ -201,7 +202,6 @@ DB2Storage<RewardPackEntry> sRewardPackStore("RewardPack.db2 DB2Storage<RewardPackXCurrencyTypeEntry> sRewardPackXCurrencyTypeStore("RewardPackXCurrencyType.db2", RewardPackXCurrencyTypeLoadInfo::Instance()); DB2Storage<RewardPackXItemEntry> sRewardPackXItemStore("RewardPackXItem.db2", RewardPackXItemLoadInfo::Instance()); DB2Storage<RulesetItemUpgradeEntry> sRulesetItemUpgradeStore("RulesetItemUpgrade.db2", RulesetItemUpgradeLoadInfo::Instance()); -DB2Storage<SandboxScalingEntry> sSandboxScalingStore("SandboxScaling.db2", SandboxScalingLoadInfo::Instance()); DB2Storage<ScalingStatDistributionEntry> sScalingStatDistributionStore("ScalingStatDistribution.db2", ScalingStatDistributionLoadInfo::Instance()); DB2Storage<ScenarioEntry> sScenarioStore("Scenario.db2", ScenarioLoadInfo::Instance()); DB2Storage<ScenarioStepEntry> sScenarioStepStore("ScenarioStep.db2", ScenarioStepLoadInfo::Instance()); @@ -513,6 +513,7 @@ void DB2Manager::LoadStores(std::string const& dataPath, uint32 defaultLocale) LOAD_DB2(sChrSpecializationStore); LOAD_DB2(sCinematicCameraStore); LOAD_DB2(sCinematicSequencesStore); + LOAD_DB2(sContentTuningStore); LOAD_DB2(sConversationLineStore); LOAD_DB2(sCreatureDisplayInfoStore); LOAD_DB2(sCreatureDisplayInfoExtraStore); @@ -639,7 +640,6 @@ void DB2Manager::LoadStores(std::string const& dataPath, uint32 defaultLocale) LOAD_DB2(sRewardPackXCurrencyTypeStore); LOAD_DB2(sRewardPackXItemStore); LOAD_DB2(sRulesetItemUpgradeStore); - LOAD_DB2(sSandboxScalingStore); LOAD_DB2(sScalingStatDistributionStore); LOAD_DB2(sScenarioStore); LOAD_DB2(sScenarioStepStore); diff --git a/src/server/game/DataStores/DB2Stores.h b/src/server/game/DataStores/DB2Stores.h index d5f0af253a0..50853a52947 100644 --- a/src/server/game/DataStores/DB2Stores.h +++ b/src/server/game/DataStores/DB2Stores.h @@ -65,6 +65,7 @@ TC_GAME_API extern DB2Storage<ChrRacesEntry> sChrRacesSto TC_GAME_API extern DB2Storage<ChrSpecializationEntry> sChrSpecializationStore; TC_GAME_API extern DB2Storage<CinematicCameraEntry> sCinematicCameraStore; TC_GAME_API extern DB2Storage<CinematicSequencesEntry> sCinematicSequencesStore; +TC_GAME_API extern DB2Storage<ContentTuningEntry> sContentTuningStore; TC_GAME_API extern DB2Storage<ConversationLineEntry> sConversationLineStore; TC_GAME_API extern DB2Storage<CreatureDisplayInfoEntry> sCreatureDisplayInfoStore; TC_GAME_API extern DB2Storage<CreatureDisplayInfoExtraEntry> sCreatureDisplayInfoExtraStore; @@ -155,7 +156,6 @@ TC_GAME_API extern DB2Storage<QuestSortEntry> sQuestSortSt TC_GAME_API extern DB2Storage<QuestXPEntry> sQuestXPStore; TC_GAME_API extern DB2Storage<RandPropPointsEntry> sRandPropPointsStore; TC_GAME_API extern DB2Storage<RewardPackEntry> sRewardPackStore; -TC_GAME_API extern DB2Storage<SandboxScalingEntry> sSandboxScalingStore; TC_GAME_API extern DB2Storage<ScalingStatDistributionEntry> sScalingStatDistributionStore; TC_GAME_API extern DB2Storage<ScenarioEntry> sScenarioStore; TC_GAME_API extern DB2Storage<ScenarioStepEntry> sScenarioStepStore; diff --git a/src/server/game/Entities/Item/Item.cpp b/src/server/game/Entities/Item/Item.cpp index ed7ff103531..a73541e4992 100644 --- a/src/server/game/Entities/Item/Item.cpp +++ b/src/server/game/Entities/Item/Item.cpp @@ -2231,9 +2231,9 @@ uint32 Item::GetItemLevel(ItemTemplate const* itemTemplate, BonusData const& bon else level = std::min(std::max(int32(level), ssd->MinLevel), ssd->MaxLevel); - if (SandboxScalingEntry const* sandbox = sSandboxScalingStore.LookupEntry(bonusData.SandboxScalingId)) - if ((sandbox->Flags & 2 || sandbox->MinLevel || sandbox->MaxLevel) && !(sandbox->Flags & 4)) - level = std::min(std::max(int32(level), sandbox->MinLevel), sandbox->MaxLevel); + if (ContentTuningEntry const* contentTuning = sContentTuningStore.LookupEntry(bonusData.ContentTuningId)) + if ((contentTuning->Flags & 2 || contentTuning->MinLevel || contentTuning->MaxLevel) && !(contentTuning->Flags & 4)) + level = std::min(std::max(int32(level), contentTuning->MinLevel), contentTuning->MaxLevel); if (uint32 heirloomIlvl = uint32(sDB2Manager.GetCurveValueAt(ssd->PlayerLevelToItemLevelCurveID, level))) itemLevel = heirloomIlvl; @@ -2598,9 +2598,9 @@ void Item::SetFixedLevel(uint8 level) { level = std::min(std::max(int32(level), ssd->MinLevel), ssd->MaxLevel); - if (SandboxScalingEntry const* sandbox = sSandboxScalingStore.LookupEntry(_bonusData.SandboxScalingId)) - if ((sandbox->Flags & 2 || sandbox->MinLevel || sandbox->MaxLevel) && !(sandbox->Flags & 4)) - level = std::min(std::max(int32(level), sandbox->MinLevel), sandbox->MaxLevel); + if (ContentTuningEntry const* contentTuning = sContentTuningStore.LookupEntry(_bonusData.ContentTuningId)) + if ((contentTuning->Flags & 2 || contentTuning->MinLevel || contentTuning->MaxLevel) && !(contentTuning->Flags & 4)) + level = std::min(std::max(int32(level), contentTuning->MinLevel), contentTuning->MaxLevel); SetModifier(ITEM_MODIFIER_SCALING_STAT_DISTRIBUTION_FIXED_LEVEL, level); } @@ -2643,7 +2643,7 @@ void BonusData::Initialize(ItemTemplate const* proto) AppearanceModID = 0; RepairCostMultiplier = 1.0f; ScalingStatDistribution = proto->GetScalingStatDistribution(); - SandboxScalingId = 0; + ContentTuningId = 0; RelicType = -1; HasItemLevelBonus = false; HasFixedLevel = false; @@ -2731,7 +2731,7 @@ void BonusData::AddBonus(uint32 type, int32 const (&values)[3]) if (values[1] < _state.ScalingStatDistributionPriority) { ScalingStatDistribution = static_cast<uint32>(values[0]); - SandboxScalingId = static_cast<uint32>(values[2]); + ContentTuningId = static_cast<uint32>(values[2]); _state.ScalingStatDistributionPriority = values[1]; HasFixedLevel = type == ITEM_BONUS_SCALING_STAT_DISTRIBUTION_FIXED; } diff --git a/src/server/game/Entities/Item/Item.h b/src/server/game/Entities/Item/Item.h index 83e229b7076..6ee784c8d7d 100644 --- a/src/server/game/Entities/Item/Item.h +++ b/src/server/game/Entities/Item/Item.h @@ -85,7 +85,7 @@ struct BonusData uint32 AppearanceModID; float RepairCostMultiplier; uint32 ScalingStatDistribution; - uint32 SandboxScalingId; + uint32 ContentTuningId; uint32 DisenchantLootId; uint32 GemItemLevelBonus[MAX_ITEM_PROTO_SOCKETS]; int32 GemRelicType[MAX_ITEM_PROTO_SOCKETS]; |