Optimising Stat()::class.

This commit is contained in:
2024-01-16 09:13:15 +02:00
parent 68ef35d14a
commit 7dc27047b6
9 changed files with 43 additions and 65 deletions
+4 -3
View File
@@ -27,7 +27,8 @@ $c['inf'] = true;
include_once('_incl_data/class/__db_connect.php');
$u = User::start();
$bonusstatnames = (new Stat())->getBonusNames();
$statnames = new Stat();
$statnames->getBonus();
const LOWERCASE = 3;
const UPPERCASE = 1;
@@ -349,7 +350,7 @@ if (isset($uer)) {
<small>
<?php
foreach (array_keys($bonusstatnames) as $stat) {
foreach ($statnames->sysBonusNames as $stat) {
if (empty($st[$stat]) || empty($u->is[$stat])) {
continue;
}
@@ -357,7 +358,7 @@ if (isset($uer)) {
$st[$stat] = '+' . $st[$stat];
}
echo '&bull; ' . $bonusstatnames[$stat] . ': ' . $st[$stat] . ' <br>';
echo '&bull; ' . $statnames->bonusNames[$stat] . ': ' . $st[$stat] . ' <br>';
}
?>
</small>