This commit is contained in:
aozhiwei 2019-04-12 11:50:06 +08:00
parent 4ffcc3c77f
commit ad603e4485

View File

@ -193,7 +193,7 @@ void Player::UpdateAction()
if (inventory[item_meta->i->_inventory_slot()] > 0) {
float old_health = health;
health += item_meta->i->heal();
health = std::min(100.0f, GetMaxHP());
health = std::min(health, GetMaxHP());
stats.heal_amount += health - old_health;
--inventory[item_meta->i->_inventory_slot()];
need_sync_active_player = true;