Skip to content

Commit

Permalink
fix(Modules/ILU): correct give player level
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrey committed May 26, 2024
1 parent 3b132d3 commit f00b946
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion modules/mod-item-level-up/src/ItemLevelUp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,9 @@ bool ItemLevelUpMgr::OnPlayerItemUse(Player* player, Item* item)
if (newLevel == 1)
newLevel = playerLevel + 1;

if (newLevel > _maxConfigLevel)
newLevel = _maxConfigLevel;

player->GiveLevel(newLevel);

if (!_isSaveExpEnable)
Expand Down Expand Up @@ -180,4 +183,4 @@ void ItemLevelUpMgr::SetMaxWeaponSkills(Player* player)

player->SaveToDB(false, false);
player->UpdateSkillsToMaxSkillsForLevel();
}
}

0 comments on commit f00b946

Please sign in to comment.