Profiler/Fixup
* fix achievementpoint total being the sum of both factions
This commit is contained in:
parent
725686d1cd
commit
9fc6f7896e
2 changed files with 6 additions and 3 deletions
1
setup/sql/updates/1775758635_01.sql
Normal file
1
setup/sql/updates/1775758635_01.sql
Normal file
|
|
@ -0,0 +1 @@
|
|||
UPDATE `aowow_dbversion` SET `build` = CONCAT(IFNULL(`build`, ''), ' profiler');
|
||||
|
|
@ -329,7 +329,7 @@ CLISetup::registerSetup("build", new class extends SetupScript
|
|||
{
|
||||
$condition = array(
|
||||
[['cuFlags', CUSTOM_EXCLUDE_FOR_LISTVIEW, '&'], 0],
|
||||
[['flags', 1, '&'], 0], // no statistics
|
||||
[['flags', 1, '&'], 0], // no statistics
|
||||
);
|
||||
$achievez = new AchievementList($condition);
|
||||
|
||||
|
|
@ -343,8 +343,10 @@ CLISetup::registerSetup("build", new class extends SetupScript
|
|||
$buff = "var _ = g_achievements;\n";
|
||||
foreach ($achievez->getListviewData(ACHIEVEMENTINFO_PROFILE) as $id => $data)
|
||||
{
|
||||
$sumPoints += $data['points'];
|
||||
$buff .= '_['.$id.'] = '.Util::toJSON($data).";\n";
|
||||
if ($data['side'] & SIDE_ALLIANCE) // both sides have the same point total
|
||||
$sumPoints += $data['points'];
|
||||
|
||||
$buff .= '_['.$id.'] = '.Util::toJSON($data).";\n";
|
||||
}
|
||||
|
||||
// categories to sort by
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue