diff --git a/setup/tools/sqlgen/itemset.ss.php b/setup/tools/sqlgen/itemset.ss.php index b89d5839..edd9bceb 100644 --- a/setup/tools/sqlgen/itemset.ss.php +++ b/setup/tools/sqlgen/itemset.ss.php @@ -296,15 +296,17 @@ CLISetup::registerSetup("sql", new class extends SetupScript $sorted[$k][$data['slot']] = $data; } - foreach ($sorted as $i => $set) + $i = 0; + foreach ($sorted as $set) { ksort($set); $vRow = $row; $this->getDataFromSet($vRow, $set); - // is virtual set - if ($i) + // only assign a virtual setId to followup sets or the ItemSummary tool can't find the setboni + // is this the correct way..? + if ($i++) $vRow['id'] = --$virtualId; DB::Aowow()->query('INSERT INTO ?_itemset (?#) VALUES (?a)', array_keys($vRow), array_values($vRow)); diff --git a/setup/updates/1741361137_01.sql b/setup/updates/1741361137_01.sql new file mode 100644 index 00000000..92ad74d7 --- /dev/null +++ b/setup/updates/1741361137_01.sql @@ -0,0 +1 @@ +UPDATE `aowow_dbversion` SET `sql` = CONCAT(IFNULL(`sql`, ''), ' itemset'), `build` = CONCAT(IFNULL(`build`, ''), ' itemsets'); diff --git a/static/js/Summary.js b/static/js/Summary.js index e929b50c..429c9a86 100644 --- a/static/js/Summary.js +++ b/static/js/Summary.js @@ -2483,6 +2483,7 @@ Summary.prototype = { if (g_items[p]) { var s = g_items[p].jsonequip.itemset, + t = g_items[p].jsonequip.slot, _ = g_itemsets[s]; if (_) { @@ -2491,7 +2492,9 @@ Summary.prototype = { if (itemsetpcs[s] == null) { itemsetpcs[s] = {}; } - itemsetpcs[s][p] = 1; + // aowow: group by slot, not itemId, to avoid multiple items of the same slot activating boni + // itemsetpcs[s][p] = 1; + itemsetpcs[s][t] = 1; itemsetbak[s] = _; } }