Fishing drops are no longer random amounts

This commit is contained in:
nossr50 2019-08-23 20:51:32 -06:00
parent 77ffee2515
commit 52f9273fa8
3 changed files with 9 additions and 3 deletions

View File

@ -1,9 +1,14 @@
Version 2.1.103
Treasure item amount will default to 1 if not specified instead of breaking mcMMO
Fishing treasures will now return the amount defined in treasures config file, an option to randomize amounts will be coming in the future. See notes.
Fixed a bug where Tree Feller was only rewarding 1 XP per log broken no matter the circumstances
Fixed an issue with salvage checking the incorrect level requirement
Updated Italian locale (thanks Leomixer17)
Fixed grammar in one of the Salvage strings (thanks QuantumToasted)
NOTES:
Sometime in 2014 a decision was made that any fishing treasure over the amount of 1 will be randomized in its yield, while this is not necessarily a bad thing it means control over the drop is a bit random. I've removed this randomness temporarily, in the future you will be able to chose if the amount is randomized or static.
Version 2.1.102
Scoreboards will now be removed from players who teleport to a blacklisted world
Fixed a bug where Rupture could trigger itself

View File

@ -150,7 +150,7 @@ public class TreasureConfig extends ConfigLoader {
}
if (amount <= 0) {
reason.add("Amount of " + treasureName + " must be greater than 0! " + amount);
amount = 1;
}
if (material != null && material.isBlock() && (data > 127 || data < -128)) {

View File

@ -480,9 +480,10 @@ public class FishingManager extends SkillManager {
treasureDrop.setDurability((short) (Misc.getRandom().nextInt(maxDurability)));
}
if (treasureDrop.getAmount() > 1) {
//TODO: Add option to randomize the amount rewarded
/*if (treasureDrop.getAmount() > 1) {
treasureDrop.setAmount(Misc.getRandom().nextInt(treasureDrop.getAmount()) + 1);
}
}*/
treasure.setDrop(treasureDrop);