Calculate experience gain before processing green thumb.

This commit is contained in:
ProgrammingAtDawn 2018-01-15 22:47:41 +01:00
parent d4f2f0e11b
commit d64399df49

View File

@ -148,10 +148,6 @@ public class HerbalismManager extends SkillManager {
}
}
else {
if (Permissions.greenThumbPlant(player, material)) {
processGreenThumbPlants(blockState, greenTerra);
}
if(material == Material.CHORUS_FLOWER && blockState.getRawData() != 5) {
return;
}
@ -165,6 +161,10 @@ public class HerbalismManager extends SkillManager {
amount = Herbalism.calculateMultiBlockPlantDrops(blockState);
xp *= amount;
}
if (Permissions.greenThumbPlant(player, material)) {
processGreenThumbPlants(blockState, greenTerra);
}
}
applyXpGain(xp, XPGainReason.PVE);