mirror of
https://github.com/Zrips/Jobs.git
synced 2025-01-02 14:29:07 +01:00
Added option to ignore boosted items in offhand
This commit is contained in:
parent
396604924d
commit
b42e1002e5
@ -10,3 +10,5 @@
|
||||
- Fixed issue when the player gliding is not valid in 1.9.1 version
|
||||
- Fixed signs updating
|
||||
- Level, exp adding and taking amounts now correctly calculating.
|
||||
- New placeholder %jobsr_user_job_(jname/number)% to show the player job.
|
||||
- Added option to ignore the boosted items usage in off hand.
|
||||
|
@ -882,7 +882,7 @@ public class PlayerManager {
|
||||
data.add(jitem.getBoost(this.getJobsPlayer(player).getJobProgression(prog)));
|
||||
|
||||
// Lets check offhand
|
||||
if (Version.isCurrentEqualOrHigher(Version.v1_9_R1)) {
|
||||
if (Version.isCurrentEqualOrHigher(Version.v1_9_R1) && Jobs.getGCManager().boostedItemsInOffHand) {
|
||||
iih = ItemReflection.getItemInOffHand(player);
|
||||
if (iih != null) {
|
||||
jitem = getJobsItemByNbt(iih);
|
||||
|
@ -52,6 +52,7 @@ public class GeneralConfigManager {
|
||||
public boolean payExploringWhenGliding;
|
||||
public boolean disablePaymentIfRiding;
|
||||
protected boolean addXpPlayer;
|
||||
public boolean boostedItemsInOffHand;
|
||||
public boolean payItemDurabilityLoss;
|
||||
public List<String> WhiteListedItems = new ArrayList<>();
|
||||
protected boolean hideJobsWithoutPermission;
|
||||
@ -570,6 +571,11 @@ public class GeneralConfigManager {
|
||||
c.addComment("add-xp-player", "Adds the Jobs xp received to the player's Minecraft XP bar");
|
||||
addXpPlayer = c.get("add-xp-player", false);
|
||||
|
||||
if (Version.isCurrentEqualOrHigher(Version.v1_9_R1)) {
|
||||
c.addComment("enable-boosted-items-in-offhand", "Do the jobs boost ignore the boosted items usage in off hand?");
|
||||
boostedItemsInOffHand = c.get("enable-boosted-items-in-offhand", true);
|
||||
}
|
||||
|
||||
c.addComment("allow-pay-for-durability-loss", "Allows, when losing maximum durability of item then it does not pay the player until it is repaired.",
|
||||
"E.g. the player wants to enchant a item with enchanting table and the item has durability loss then not paying.");
|
||||
c.addComment("allow-pay-for-durability-loss.Use", "Do not disable this if you don't know what mean this option.");
|
||||
|
Loading…
Reference in New Issue
Block a user