From 1566deb84a082176b8c683fda205d828bc38fbcc Mon Sep 17 00:00:00 2001 From: slawkens Date: Sat, 19 Jul 2025 15:46:51 +0200 Subject: [PATCH] Add getExperienceForLevel (level) --- system/functions.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/system/functions.php b/system/functions.php index d1351f35..8859d36f 100644 --- a/system/functions.php +++ b/system/functions.php @@ -774,6 +774,10 @@ function formatExperience($exp, $color = true) return $ret; } +function getExperienceForLevel($level): float|int { + return ( 50 / 3 ) * pow( $level, 3 ) - ( 100 * pow( $level, 2 ) ) + ( ( 850 / 3 ) * $level ) - 200; +} + function get_locales() { $ret = array();