mirror of
https://github.com/Shadowss/TravianZ.git
synced 2026-08-09 21:01:00 +00:00
Restore level 119 for hero
Restore level 119 for hero
This commit is contained in:
@@ -227,7 +227,7 @@ function go_url(url){ location=url; return false; }
|
||||
<div class="body">
|
||||
<?php if($isMax):?>
|
||||
<div style="text-align:center;padding:8px;background:#fef3c7;border:1px solid #fde68a;border-radius:6px;color:#92400e;font-size:12px;margin-bottom:10px;">
|
||||
⚠ Hero is at the maximum level (<?php echo isset($hero_levels) ? max(array_keys($hero_levels)) - 1 : 120; ?>) — no more points can be added.
|
||||
⚠ Hero is at the maximum level (<?php echo isset($hero_levels) ? max(array_keys($hero_levels)) - 1 : 119; ?>) — no more points can be added.
|
||||
</div>
|
||||
<?php endif;?>
|
||||
<table class="stat-table">
|
||||
|
||||
@@ -150,7 +150,7 @@ if ($hero !== false) {
|
||||
+ (int)$h['defencebonus'] + (int)$h['regeneration'] + (int)($h['resources'] ?? 0);
|
||||
|
||||
// totalul de puncte vine din tabelul de niveluri: 5 initiale + 5 per nivel
|
||||
$hMaxLevel = isset($hero_levels) ? max(array_keys($hero_levels)) - 1 : 120;
|
||||
$hMaxLevel = isset($hero_levels) ? max(array_keys($hero_levels)) - 1 : 119;
|
||||
$hMaxPoints = 5 + ($hMaxLevel * 5);
|
||||
$count_level_exp = max(0, $hMaxPoints - $used);
|
||||
if ($h['points'] > $count_level_exp) $h['points'] = $count_level_exp;
|
||||
|
||||
Reference in New Issue
Block a user