mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 13:16:45 +01:00
Add comment about power level cap issue
This commit is contained in:
parent
71d1f42cf4
commit
317dc814a4
@ -775,7 +775,9 @@ public class McMMOPlayer implements Identified {
|
||||
* @return Modified experience
|
||||
*/
|
||||
private float modifyXpGain(PrimarySkillType primarySkillType, float xp) {
|
||||
if ((primarySkillType.getMaxLevel() <= getSkillLevel(primarySkillType)) || (Config.getInstance().getPowerLevelCap() <= getPowerLevel())) {
|
||||
//TODO: A rare situation can occur where the default Power Level cap can prevent a player with one skill edited to something silly like Integer.MAX_VALUE from gaining XP in any skill, we may need to represent power level with another data type
|
||||
if ((primarySkillType.getMaxLevel() <= getSkillLevel(primarySkillType))
|
||||
|| (Config.getInstance().getPowerLevelCap() <= getPowerLevel())) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user