mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-25 22:56:45 +01:00
Added the possibility to not use a max level for Fishing
by using a negative number, changed default treasure.yml file accordingly
This commit is contained in:
parent
188ad359fe
commit
a0a52a3433
@ -25,13 +25,11 @@ Version 1.4.00-dev
|
||||
= Fixed Leaf Blower not respecting the unlock level set in advanced.yml
|
||||
= Fixed abilities activating with the wrong tool in hand
|
||||
= Fixed Experience.Gains.Mobspawners.Enabled not being used correctly (the check was inverted)
|
||||
<<<<<<< Upstream, based on origin/master
|
||||
= Fixed bug where Iron Grip was using the attacker's skill values rather than the defender's.
|
||||
= Fixed a bug where /party kick would trigger the PartyChangeEvent for the wrong player
|
||||
= Fixed a bug where party join messages weren't displayed
|
||||
=======
|
||||
! It is now possible to use a negative number for Max_Level in treasures.yml to not use a maximum level, changed default file accordingly
|
||||
! A Fishing catch will now always contains a fish even if a treasure is found
|
||||
>>>>>>> 1f7a94a Changed Fishing to always give a fish on a successful catch
|
||||
! Changed how Berserk handles not picking up items to avoid listening to PlayerPickupItemEvent
|
||||
! Moved Hylian Luck into a separate listener since it actually cancels the event and shouldn't just be on MONITOR.
|
||||
! Changed how Tree Feller is handled, it should now put less stress on the CPU
|
||||
|
@ -132,9 +132,7 @@ public class TreasuresConfig extends ConfigLoader{
|
||||
|
||||
int maxLevel = config.getInt("Treasures." + treasureName + ".Max_Level");
|
||||
|
||||
if (maxLevel < 0) {
|
||||
reason.add("Invalid Max_Level: " + maxLevel);
|
||||
}
|
||||
|
||||
|
||||
if (noErrorsInTreasure(reason)) {
|
||||
FishingTreasure fTreasure = new FishingTreasure(item, xp, dropChance, dropLevel, maxLevel);
|
||||
|
@ -111,7 +111,9 @@ public class Fishing {
|
||||
List<FishingTreasure> rewards = new ArrayList<FishingTreasure>();
|
||||
|
||||
for (FishingTreasure treasure : TreasuresConfig.getInstance().fishingRewards) {
|
||||
if (treasure.getDropLevel() <= skillLevel && treasure.getMaxLevel() >= skillLevel) {
|
||||
int maxLevel = treasure.getMaxLevel();
|
||||
|
||||
if (treasure.getDropLevel() <= skillLevel && (maxLevel >= skillLevel || maxLevel <= 0)) {
|
||||
rewards.add(treasure);
|
||||
}
|
||||
}
|
||||
|
@ -441,7 +441,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Shovel:
|
||||
@ -451,7 +451,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Pickaxe:
|
||||
@ -461,7 +461,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Axe:
|
||||
@ -471,7 +471,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Hoe:
|
||||
@ -481,7 +481,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Boots:
|
||||
@ -491,7 +491,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Helmet:
|
||||
@ -501,7 +501,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Leggings:
|
||||
@ -511,7 +511,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Chestplate:
|
||||
@ -521,7 +521,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Ender_Pearl:
|
||||
@ -531,7 +531,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 25.0
|
||||
Drop_Level: 200
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Sword:
|
||||
@ -541,7 +541,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Shovel:
|
||||
@ -551,7 +551,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Pickaxe:
|
||||
@ -561,7 +561,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Axe:
|
||||
@ -571,7 +571,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Hoe:
|
||||
@ -581,7 +581,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Boots:
|
||||
@ -591,7 +591,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Helmet:
|
||||
@ -601,7 +601,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Leggings:
|
||||
@ -611,7 +611,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Chestplate:
|
||||
@ -621,7 +621,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Blaze_Rod:
|
||||
@ -631,7 +631,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_3:
|
||||
@ -641,7 +641,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_4:
|
||||
@ -651,7 +651,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_5:
|
||||
@ -661,7 +661,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 30.0
|
||||
Drop_Level: 400
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Sword:
|
||||
@ -671,7 +671,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Shovel:
|
||||
@ -681,7 +681,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Pickaxe:
|
||||
@ -691,7 +691,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Axe:
|
||||
@ -701,7 +701,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Hoe:
|
||||
@ -711,7 +711,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Boots:
|
||||
@ -721,7 +721,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Helmet:
|
||||
@ -731,7 +731,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Leggings:
|
||||
@ -741,7 +741,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamond_Chestplate:
|
||||
@ -751,7 +751,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_6:
|
||||
@ -761,7 +761,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_7:
|
||||
@ -771,7 +771,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_8:
|
||||
@ -781,7 +781,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_9:
|
||||
@ -791,7 +791,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_10:
|
||||
@ -801,7 +801,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Record_11:
|
||||
@ -811,7 +811,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Ghast_Tear:
|
||||
@ -821,7 +821,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 35.0
|
||||
Drop_Level: 600
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Diamonds:
|
||||
@ -831,7 +831,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 40.0
|
||||
Drop_Level: 800
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Iron_Ingots:
|
||||
@ -841,7 +841,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 40.0
|
||||
Drop_Level: 800
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Gold_Ingots:
|
||||
@ -851,7 +851,7 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 40.0
|
||||
Drop_Level: 800
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
||||
Lapis_Lazuli:
|
||||
@ -861,6 +861,6 @@ Treasures:
|
||||
XP: 200
|
||||
Drop_Chance: 40.0
|
||||
Drop_Level: 800
|
||||
Max_Level: 1000
|
||||
Max_Level: -1
|
||||
Drops_From:
|
||||
Fishing: true
|
Loading…
Reference in New Issue
Block a user