SetHeroLevel
- Parameters
whichHero unitThe target hero unit.
level integerNew level of the hero.
showEyeCandy booleanFalse to hide level-up effects, true to show. The level-up effects include: floating experience gain text, sound and a visual effect.
- comment
Sets the hero to chosen level.
The level can only be increased; lowering the level does nothing. Further, the level will not exceed the hero's maximum level set in WorldEditor.
- bug
Making a hero level up using this function (or via other means) will reset the skillpoint modification caused by
UnitModifySkillPointsif the amount of skillpoints is beyond the amount of ability levels that can still be learned. SeeUnitModifySkillPoints.- patch
1.00
- Source
- common.j (suggest an edit or discuss on Github)
- return type
nothing- Source code
native SetHeroLevel takes unit whichHero, integer level, boolean showEyeCandy returns nothing