This commit is contained in:
aozhiwei 2022-06-13 19:05:30 +08:00
parent cf3b270c20
commit 4b92288a45

View File

@ -401,20 +401,6 @@ class HeroController extends BaseAuthedController {
$this->_rspErr(3, $this->_getLackItemErrMsg($lackItem));
return;
}
$baseAttrs = mt\Hero::getHeroAttr($heroMeta);
mt\AttrHelper::mergeAttr($baseAttrs, Bag::getAttrs());
$attrs = emptyReplace(json_decode($heroDb['rand_attr'], true), array());
{
$obtainAttrs = mt\HeroQuality::getRandAttr($nextQualityMeta);
mt\AttrHelper::mergeAttr($attrs, $obtainAttrs);
}
{
$ret = mt\HeroLevel::addRandAttr($nextLevelMeta, $baseAttrs, $attrs);
if (!$ret) {
$this->_rspErr(2, 'server internal error');
return;
}
}
$this->_decItems($costItems);
Hero::update($heroUniId,
array(