Change boost xp penality on replacement to only apply if the head is changed

This commit is contained in:
Bernhard Bonigl committed 2014-07-31 13:12:43 +02:00
1 parent 1cef48a667
commit c5a5c3e6e2
2 files changed
+2 -2

No files matched your search

@@ -124,7 +124,7 @@ public class Config {
/** PartReplacement Module **/
partReplacementXpPenality = configfile.getInt("XpPenality", CATEGORY_PartReplacement, 0, 0, 100, "How much of the current XP% shall be removed when replacing parts (So if you had 50%, and penality is 10% it'll remove 5% xp, resulting in 45%). Does not remove Skill Levels.");
partReplacementBoostXpPenality = configfile.getInt("PickBoostXpPenality", CATEGORY_PartReplacement, 5, 0, 100, "How much of the current XP% to the next mining level shall be removed when replacing parts. Useful to remove the mining level boost on part replacement.");
partReplacementBoostXpPenality = configfile.getInt("PickBoostXpPenality", CATEGORY_PartReplacement, 5, 0, 100, "How much of the current XP% to the next mining level shall be removed when replacing the pickaxe head. Useful to remove the mining level boost on part replacement.");
/** MobHeads **/
// todo: implement
@@ -180,7 +180,7 @@ public abstract class ReplacementLogic {
xp *= newRequiredBoostXp / (float) oldRequiredBoostXp;
// xp penality?
if(Config.partReplacementBoostXpPenality > 0)
if(Config.partReplacementBoostXpPenality > 0 && type == HEAD)
{
if(LevelingLogic.isBoosted(tags)) {
tags.setBoolean(LevelingLogic.TAG_IS_BOOSTED, false);