Merge branch 'develop' into feature/ots-player-rewrite

This commit is contained in:
slawkens
2026-01-04 13:22:17 +01:00
77 changed files with 853 additions and 3226 deletions

View File

@@ -673,13 +673,7 @@ class OTS_Player extends OTS_Row_DAO
throw new E_OTS_NotLoaded();
}
if(isset($this->data['promotion'])) {
global $config;
if((int)$this->data['promotion'] > 0)
return ($this->data['vocation'] + ($this->data['promotion'] * $config['vocations_amount']));
}
return $this->data['vocation'];
return \OTS_Toolbox::getVocationFromPromotion($this->data['vocation'], $this->data['promotion'] ?? 0);
}