This commit is contained in:
aozhiwei 2022-06-14 15:47:04 +08:00
parent fdd75b3f1f
commit 74d96cee1b

View File

@ -394,6 +394,22 @@ class HeroController extends BaseAuthedController {
return;
}
}
{
$idx = 0;
$found = false;
for ($i = 0; $i < kMaxHeroUpQualityNum; ++$i) {
$upHeroUniId = $this->_getV(TN_HERO_QUALITY_UP, $i);
if ($upHeroUniId == $heroUniId) {
$idx = $i;
$found = true;
break;
}
}
if (!$found) {
$this->_rspErr(1, 'hero already upgrade');
return;
}
}
if (!$heroDb) {
$this->_rspErr(1, 'hero does not exist');
return;