mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2025-07-09 09:04:44 +02:00
More work on end game skills
This commit is contained in:
@ -35,6 +35,7 @@ public class HerbalismCommand extends SkillCommand {
|
||||
private boolean canGreenThumbBlocks;
|
||||
private boolean canFarmersDiet;
|
||||
private boolean canDoubleDrop;
|
||||
private boolean canTripleDrop;
|
||||
private boolean canShroomThumb;
|
||||
|
||||
public HerbalismCommand() {
|
||||
@ -50,6 +51,12 @@ public class HerbalismCommand extends SkillCommand {
|
||||
doubleDropChance = doubleDropStrings[0];
|
||||
doubleDropChanceLucky = doubleDropStrings[1];
|
||||
}
|
||||
|
||||
if (canTripleDrop) {
|
||||
String[] tripleDropStrings = ProbabilityUtil.getRNGDisplayValues(player, SubSkillType.HERBALISM_VERDANT_BOUNTY);
|
||||
doubleDropChance = tripleDropStrings[0];
|
||||
doubleDropChanceLucky = tripleDropStrings[1];
|
||||
}
|
||||
|
||||
// FARMERS DIET
|
||||
if (canFarmersDiet) {
|
||||
|
@ -32,7 +32,7 @@ public class MiningCommand extends SkillCommand {
|
||||
|
||||
private boolean canSuperBreaker;
|
||||
private boolean canDoubleDrop;
|
||||
private boolean canMotherLode;
|
||||
private boolean canTripleDrop;
|
||||
private boolean canBlast;
|
||||
private boolean canBiggerBombs;
|
||||
private boolean canDemoExpert;
|
||||
@ -56,7 +56,7 @@ public class MiningCommand extends SkillCommand {
|
||||
}
|
||||
|
||||
// Mastery TRIPLE DROPS
|
||||
if (canMotherLode) {
|
||||
if (canTripleDrop) {
|
||||
String[] masteryTripleDropStrings = ProbabilityUtil.getRNGDisplayValues(player, SubSkillType.MINING_MOTHER_LODE);
|
||||
tripleDropChance = masteryTripleDropStrings[0];
|
||||
tripleDropChanceLucky = masteryTripleDropStrings[1];
|
||||
@ -83,7 +83,7 @@ public class MiningCommand extends SkillCommand {
|
||||
canBlast = RankUtils.hasUnlockedSubskill(player, SubSkillType.MINING_BLAST_MINING) && Permissions.remoteDetonation(player);
|
||||
canDemoExpert = RankUtils.hasUnlockedSubskill(player, SubSkillType.MINING_DEMOLITIONS_EXPERTISE) && Permissions.demolitionsExpertise(player);
|
||||
canDoubleDrop = Permissions.canUseSubSkill(player, SubSkillType.MINING_DOUBLE_DROPS);
|
||||
canMotherLode = Permissions.canUseSubSkill(player, SubSkillType.MINING_MOTHER_LODE);
|
||||
canTripleDrop = Permissions.canUseSubSkill(player, SubSkillType.MINING_MOTHER_LODE);
|
||||
canSuperBreaker = RankUtils.hasUnlockedSubskill(player, SubSkillType.MINING_SUPER_BREAKER) && Permissions.superBreaker(player);
|
||||
}
|
||||
|
||||
@ -112,12 +112,11 @@ public class MiningCommand extends SkillCommand {
|
||||
//messages.add(LocaleLoader.getString("Mining.Effect.DropChance", doubleDropChance) + (isLucky ? LocaleLoader.getString("Perks.Lucky.Bonus", doubleDropChanceLucky) : ""));
|
||||
}
|
||||
|
||||
if(canMotherLode) {
|
||||
if(canTripleDrop) {
|
||||
messages.add(getStatMessage(SubSkillType.MINING_MOTHER_LODE, tripleDropChance)
|
||||
+ (isLucky ? LocaleLoader.getString("Perks.Lucky.Bonus", tripleDropChanceLucky) : ""));
|
||||
}
|
||||
|
||||
|
||||
if (canSuperBreaker) {
|
||||
messages.add(getStatMessage(SubSkillType.MINING_SUPER_BREAKER, superBreakerLength)
|
||||
+ (hasEndurance ? LocaleLoader.getString("Perks.ActivationTime.Bonus", superBreakerLengthEndurance) : ""));
|
||||
|
@ -38,7 +38,6 @@ public enum SubSkillType {
|
||||
/* Excavation */
|
||||
EXCAVATION_ARCHAEOLOGY(8),
|
||||
EXCAVATION_GIGA_DRILL_BREAKER(1),
|
||||
EXCAVATION_MASTERY(1),
|
||||
|
||||
/* Fishing */
|
||||
FISHING_FISHERMANS_DIET(5),
|
||||
@ -51,6 +50,7 @@ public enum SubSkillType {
|
||||
|
||||
/* Herbalism */
|
||||
HERBALISM_DOUBLE_DROPS(1),
|
||||
HERBALISM_VERDANT_BOUNTY(1),
|
||||
HERBALISM_FARMERS_DIET(5),
|
||||
HERBALISM_GREEN_TERRA(1),
|
||||
HERBALISM_GREEN_THUMB(4),
|
||||
@ -147,7 +147,7 @@ public enum SubSkillType {
|
||||
/**
|
||||
* !!! This relies on the immutable lists in PrimarySkillType being populated !!!
|
||||
* If we add skills, those immutable lists need to be updated
|
||||
* @return
|
||||
* @return the parent skill of this subskill
|
||||
*/
|
||||
public PrimarySkillType getParentSkill() { return mcMMO.p.getSkillTools().getPrimarySkillBySubSkill(this); }
|
||||
|
||||
|
@ -35,7 +35,7 @@ public class MiningManager extends SkillManager {
|
||||
|
||||
public static final String BUDDING_AMETHYST = "budding_amethyst";
|
||||
|
||||
public MiningManager(McMMOPlayer mcMMOPlayer) {
|
||||
public MiningManager(@NotNull McMMOPlayer mcMMOPlayer) {
|
||||
super(mcMMOPlayer, PrimarySkillType.MINING);
|
||||
}
|
||||
|
||||
|
@ -24,7 +24,7 @@ public class RankUtils {
|
||||
*
|
||||
* @param plugin plugin instance ref
|
||||
* @param mcMMOPlayer target player
|
||||
* @param primarySkillType
|
||||
* @param primarySkillType the skill to check
|
||||
* @param newLevel the new level of this skill
|
||||
*/
|
||||
public static void executeSkillUnlockNotifications(Plugin plugin, McMMOPlayer mcMMOPlayer, PrimarySkillType primarySkillType, int newLevel)
|
||||
@ -55,6 +55,9 @@ public class RankUtils {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Reset the interval between skill unlock notifications
|
||||
*/
|
||||
public static void resetUnlockDelayTimer()
|
||||
{
|
||||
count = 0;
|
||||
|
@ -257,6 +257,11 @@ Skills:
|
||||
MaxBonusLevel:
|
||||
Standard: 100
|
||||
RetroMode: 1000
|
||||
VerdantBounty:
|
||||
ChanceMax: 15.0
|
||||
MaxBonusLevel:
|
||||
Standard: 1000
|
||||
RetroMode: 10000
|
||||
|
||||
HylianLuck:
|
||||
# ChanceMax: Maximum chance of Hylian Luck when on <MaxBonusLevel> or higher
|
||||
@ -281,7 +286,7 @@ Skills:
|
||||
MaxBonusLevel:
|
||||
Standard: 1000
|
||||
RetroMode: 10000
|
||||
ChanceMax: 10.0
|
||||
ChanceMax: 15.0
|
||||
SuperBreaker:
|
||||
AllowTripleDrops: true
|
||||
DoubleDrops:
|
||||
@ -606,9 +611,9 @@ Skills:
|
||||
|
||||
# Triple Drops
|
||||
CleanCuts:
|
||||
# ChanceMax: Maximum chance of receiving double drops (100 = 100%)
|
||||
# ChanceMax: Maximum chance of receiving triple drops (100 = 100%)
|
||||
# MaxBonusLevel: Level when the maximum chance of receiving double drops is reached
|
||||
ChanceMax: 10.0
|
||||
ChanceMax: 15.0
|
||||
MaxBonusLevel:
|
||||
Standard: 1000
|
||||
RetroMode: 10000
|
||||
|
@ -285,8 +285,11 @@ Herbalism.SubSkill.FarmersDiet.Name=Farmer's Diet
|
||||
Herbalism.SubSkill.FarmersDiet.Description=Improves hunger restored from farmed foods
|
||||
Herbalism.SubSkill.FarmersDiet.Stat=Farmer's Diet: &aRank {0}
|
||||
Herbalism.SubSkill.DoubleDrops.Name=Double Drops
|
||||
Herbalism.SubSkill.DoubleDrops.Description=Double the normal loot
|
||||
Herbalism.SubSkill.DoubleDrops.Description=Skillfully harvest double the loot
|
||||
Herbalism.SubSkill.DoubleDrops.Stat=Double Drop Chance
|
||||
Herbalism.SubSkill.VerdantBounty.Name=Verdant Bounty
|
||||
Herbalism.SubSkill.VerdantBounty.Description=Masterfully harvest triple the loot
|
||||
Herbalism.SubSkill.VerdantBounty.Stat=Triple Drop Chance
|
||||
Herbalism.SubSkill.HylianLuck.Name=Hylian Luck
|
||||
Herbalism.SubSkill.HylianLuck.Description=Gives a small chance of finding rare items
|
||||
Herbalism.SubSkill.HylianLuck.Stat=Hylian Luck Chance
|
||||
@ -311,10 +314,10 @@ Mining.SubSkill.SuperBreaker.Name=Super Breaker
|
||||
Mining.SubSkill.SuperBreaker.Description=Speed+, Triple Drop Chance
|
||||
Mining.SubSkill.SuperBreaker.Stat=Super Breaker Length
|
||||
Mining.SubSkill.DoubleDrops.Name=Double Drops
|
||||
Mining.SubSkill.DoubleDrops.Description=Double the normal loot
|
||||
Mining.SubSkill.DoubleDrops.Description=Skillfully mine double the loot
|
||||
Mining.SubSkill.DoubleDrops.Stat=Double Drop Chance
|
||||
Mining.SubSkill.MotherLode.Name=Mother Lode
|
||||
Mining.SubSkill.MotherLode.Description=Triple the normal loot
|
||||
Mining.SubSkill.MotherLode.Description=Masterfully mine triple the loot
|
||||
Mining.SubSkill.MotherLode.Stat=Triple Drop Chance
|
||||
Mining.SubSkill.BlastMining.Name=Blast Mining
|
||||
Mining.SubSkill.BlastMining.Description=Bonuses to mining with TNT
|
||||
|
@ -397,8 +397,8 @@ permissions:
|
||||
mcmmo.ability.herbalism.greenthumb.all: true
|
||||
mcmmo.ability.herbalism.hylianluck: true
|
||||
mcmmo.ability.herbalism.shroomthumb: true
|
||||
mcmmo.ability.herbalism.mastery: true
|
||||
mcmmo.ability.herbalism.mastery:
|
||||
mcmmo.ability.herbalism.verdantbounty: true
|
||||
mcmmo.ability.herbalism.verdantbounty:
|
||||
description: Allows access to end game progression for Herbalism
|
||||
mcmmo.ability.herbalism.doubledrops:
|
||||
description: Allows double drop chance from Herbalism
|
||||
|
@ -413,6 +413,11 @@ Herbalism:
|
||||
Rank_1: 1
|
||||
RetroMode:
|
||||
Rank_1: 1
|
||||
VerdantBounty:
|
||||
Standard:
|
||||
Rank_1: 100
|
||||
RetroMode:
|
||||
Rank_1: 1000
|
||||
GreenTerra:
|
||||
Standard:
|
||||
Rank_1: 5
|
||||
@ -688,6 +693,11 @@ Woodcutting:
|
||||
Rank_1: 1
|
||||
RetroMode:
|
||||
Rank_1: 1
|
||||
CleanCuts:
|
||||
Standard:
|
||||
Rank_1: 100
|
||||
RetroMode:
|
||||
Rank_1: 1000
|
||||
KnockOnWood:
|
||||
Standard:
|
||||
Rank_1: 30
|
||||
|
Reference in New Issue
Block a user