mirror of
https://github.com/EQEmu/Server.git
synced 2026-06-11 11:48:37 +00:00
[Feature] Add Data Bucket support for scaling of Heroic Stats. (#3058)
* [Feature] Add Data Bucket support for scaling of Heroic Stats. * update * fixes, still reworking logic * fixes, still reworking logic * logic done * logic done * fixes * Cleanup * Cleanup * Cleanup naming, verify behaviors * formatting * formatting * fix issue with endurance and mana. * update rule desc * cleanup * DataBucket Struct * Cleanup data_bucket.cpp and add constants * cleanup * changes * formatting * fix from merge * escape keyword `key` * Add `key` to generator, run repository-generator.pl * fix for change to key * cleanup * formatting * formatting * typo
This commit is contained in:
@@ -845,18 +845,16 @@ void Client::BulkSendMerchantInventory(int merchant_id, int npcid) {
|
||||
}
|
||||
}
|
||||
|
||||
auto client_data_buckets = GetMerchantDataBuckets();
|
||||
|
||||
auto temporary_merchant_list = zone->tmpmerchanttable[npcid];
|
||||
uint32 slot_id = 1;
|
||||
uint8 handy_chance = 0;
|
||||
for (auto ml : merchant_list) {
|
||||
for (const auto& ml : merchant_list) {
|
||||
if (slot_id > merchant_slots) {
|
||||
break;
|
||||
}
|
||||
|
||||
auto bucket_name = ml.bucket_name;
|
||||
auto bucket_value = ml.bucket_value;
|
||||
auto const& bucket_value = ml.bucket_value;
|
||||
if (!bucket_name.empty() && !bucket_value.empty()) {
|
||||
auto full_name = fmt::format(
|
||||
"{}-{}",
|
||||
@@ -864,12 +862,12 @@ void Client::BulkSendMerchantInventory(int merchant_id, int npcid) {
|
||||
bucket_name
|
||||
);
|
||||
|
||||
auto player_value = client_data_buckets[full_name];
|
||||
auto const& player_value = DataBucket::CheckBucketKey(this, full_name);
|
||||
if (player_value.empty()) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!zone->CheckDataBucket(ml.bucket_comparison, bucket_value, player_value)) {
|
||||
if (!zone->CompareDataBucket(ml.bucket_comparison, bucket_value, player_value)) {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user