mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 05:06:45 +01:00
Magic Hunter requires treasure hunter and has ranks now
This commit is contained in:
parent
7e34e87bc0
commit
c7ed3ee2a0
@ -17,6 +17,8 @@ Version 2.1.2
|
||||
(Skills) Tree Feller now works on Mushroom Stems
|
||||
(Skills) Fixed a bug where magic chance would show as null
|
||||
(Skills) Fixed a bug where Trap percentages were added to Fishing even though they no longer exist
|
||||
(Skills) Magic Hunter now uses a rank system
|
||||
(Skills) Fixed a bug where Magic Hunter would work without treasure hunter
|
||||
(Experience) Wood blocks now give XP and are affected by Tree Feller (6 sided bark blocks)
|
||||
(API) Moved XPGainReason from skills to experience package
|
||||
(API) Added XpGainSource for tracking sources of XP
|
||||
|
@ -33,7 +33,7 @@ public enum SubSkillType {
|
||||
/* Fishing */
|
||||
FISHING_FISHERMANS_DIET(5),
|
||||
FISHING_ICE_FISHING(1),
|
||||
FISHING_MAGIC_HUNTER,
|
||||
FISHING_MAGIC_HUNTER(1),
|
||||
FISHING_MASTER_ANGLER(1),
|
||||
FISHING_TREASURE_HUNTER(8),
|
||||
FISHING_SHAKE(1),
|
||||
|
@ -179,6 +179,13 @@ public class FishingManager extends SkillManager {
|
||||
hook.setBiteChance(Math.min(biteChance, 1.0));
|
||||
}
|
||||
|
||||
public boolean isMagicHunterEnabled()
|
||||
{
|
||||
return RankUtils.hasUnlockedSubskill(getPlayer(), SubSkillType.FISHING_MAGIC_HUNTER)
|
||||
&& RankUtils.hasUnlockedSubskill(getPlayer(), SubSkillType.FISHING_TREASURE_HUNTER)
|
||||
&& Permissions.isSubSkillEnabled(getPlayer(), SubSkillType.FISHING_TREASURE_HUNTER);
|
||||
}
|
||||
|
||||
/**
|
||||
* Process the results from a successful fishing trip
|
||||
*
|
||||
@ -200,7 +207,8 @@ public class FishingManager extends SkillManager {
|
||||
ItemStack treasureDrop = treasure.getDrop().clone(); // Not cloning is bad, m'kay?
|
||||
Map<Enchantment, Integer> enchants = new HashMap<Enchantment, Integer>();
|
||||
|
||||
if (Permissions.isSubSkillEnabled(player, SubSkillType.FISHING_MAGIC_HUNTER) && ItemUtils.isEnchantable(treasureDrop)) {
|
||||
if (isMagicHunterEnabled()
|
||||
&& ItemUtils.isEnchantable(treasureDrop)) {
|
||||
enchants = handleMagicHunter(treasureDrop);
|
||||
}
|
||||
|
||||
|
@ -319,6 +319,11 @@ Herbalism:
|
||||
Rank_4: 800
|
||||
Rank_5: 1000
|
||||
Fishing:
|
||||
MagicHunter:
|
||||
Standard:
|
||||
Rank_1: 20
|
||||
RetroMode:
|
||||
Rank_1: 200
|
||||
Shake:
|
||||
Standard:
|
||||
Rank_1: 15
|
||||
|
Loading…
Reference in New Issue
Block a user