Skills which used to unlock at level 5 now unlock at level 1 and some

tweaks to  ranks of other skills, and length scaling for super
abilities. Early game boost has also been modified.
This commit is contained in:
nossr50 2019-06-24 20:17:35 -07:00
parent 764b4c20f5
commit 68ad507be3
10 changed files with 153 additions and 101 deletions

View File

@ -1,10 +1,50 @@
Version 2.1.89
Many changes were made to this version that affect default values in the config, read the notes carefully if you wish to apply these changes. They are optional.
mcMMO is compatible with the new 1.14.3, in addition to this it is still compatible with 1.14.2, 1.14.1, 1.14, and 1.13.2. This did not require any changes to be made to mcMMO, but I thought I'd add this to the notes for those wondering.
The default level for players has been changed back to 0 from 1 (you can change it back to 1 by editing 'Skills.General.StartingLevel' in advanced.yml) if you wish to apply this change read the notes
Super Abilities now scale in length up to level 100/1000 instead of 50/500 by default (you can edit this in advanced.yml under 'Skills.General.Ability.Length.xxx')
Early Game Boost now only applies when leveling from level 0 to level 1
Removed the config setting 'MaxLevelMultiplier' from experience.yml as it is no longer used.
Many skills which used to unlock at level 5/50 now unlock at level 1 instead
Arrow Retrieval now unlocks at level 1 in both Standard and RetroMode
Skill Shot now unlocks at level 1 in both Standard and RetroMode
Dodge now unlocks at level 1 in both Standard and RetroMode
Critical Strikes now unlocks at level 1 in both Standard and RetroMode
Armor Impact now unlocks at level 1 in both Standard and RetroMode
Beast Lore now unlocks at level 1 in both Standard and RetroMode
Call Of The Wild now unlocks at level 1 in both Standard and RetroMode
Scrap Collector now unlocks at level 1 in both Standard and RetroMode
Treasure Hunter now unlocks at level 1 in both Standard and RetroMode
Rupture now unlocks at level 1 in both Standard and RetroMode
Iron Arm Style now unlocks at level 1 in both Standard and RetroMode
Harvest Lumber now unlocks at level 1 in both Standard and RetroMode
Archaeology now unlocks at level 1 in both Standard and RetroMode
Repair Mastery now unlocks at level 1 in both Standard and RetroMode
Double Drops (Herbalism and Mining) now have ranks and unlock at level 1 in both Standard and RetroMode
Concoctions rank 2 now unlocks at Level 1 for both Standard and RetroMode
Serrated Strikes now unlocks at levels 5/50 instead of 10/100
Berserk now unlocks at levels 5/50 instead of 10/100
When using WorldGuard (WG) with mcMMO, mcMMO now examines WG more carefully to determine if it is a compatible version or not, see the notes. Keep in mind WG is optional and not needed to run mcMMO.
Fixed a bug that could result in Tree Feller failing to remove parts of a tree in snowy biomes. (This fix won't apply retroactively to old trees, see the notes)
Updated Japanese locale (thanks snake)
Tree Feller and other Super Abilities will damage tools with the Enchantment named 'Durability/Unbreaking' again, this does not apply to the NBT tag named Unbreaking (Unbreaking NBT tag is safe from damage however, try not to confuse them as they share the same name)
Added new setting 'ExploitFix.TreeFellerReducedXP' to experience.yml
Tree Feller will no longer give full XP for each block destroyed and instead give diminishing returns on XP for each block removed. You can turn this off by setting 'ExploitFix.TreeFellerReducedXP' in experience.yml to false
NOTES:
Editing your config files is not required for this patch (and never will be), however I would highly recommend it. Read the notes below this line carefully.
If you want to update to this patch easily and you don't mind default config values, delete skillranks.yml, advanced.yml, and experience.yml before starting your server with 2.1.89 of mcMMO applied.
Many skills now unlock at level 1 and the default starting level is back to 0. It is recommended you change this number from 1 to 0 manually by editing 'Skills.General.StartingLevel' in advanced.yml or deleting advanced.yml and generating a new file when 2.1.89 starts.
It is recommended you make the manual edits to skillranks.yml to apply this change or delete skillranks.yml and a new one will be generated once you start 2.1.89.
Early Game Boost was used to help players get to level 5 quickly by boosting their XP until they got there, this caused some confusion as they appeared to be 'learning a skill' for multiple levels, on RetroMode this lasted until level 50.
I have changed Early Game Boost to only last from level 0-1 on both RetroMode and Standard, and now important skills are unlocked at level 1.
I was going to wait until 2.2 was done to deploy this change, but 2.2 is some time away and the previous system was causing some confusion.
Early Game Boost gives players extra XP for skills that are level 0, you can turn this system off by setting 'EarlyGameBoost.Enabled' in experience.yml to false
Early Game Boost will show 'Learning a new skill...' if XP bars are enabled
https://mcmmo.org/wiki/World_guard - A list of WG flags supported by mcMMO.
It is not necessary to have WG installed, but if you do have WG installed mcMMO hooks into it to provide some additional features.
Previously mcMMO used to determine if WG was compatible just by checking to see if it was version 7 of WG, however version 7 of WG is not guaranteed to be compatible as necessary classes that mcMMO hooks into were added during its development and some users are still running early dev versions of WG7.
@ -14,6 +54,7 @@ Version 2.1.89
In a prior patch I removed damage on tools if they had Unbreaking NBT or Unbreaking Enchantment, at the time I made this change I did not realize they were different things and just shared the same name, this patch fixes this mistake. My intention was to prevent damage on tools with the NBT unbreaking tag which makes an item never suffer from durability loss.
mcMMO reduces damage to tools from super abilities if they have the "Durability/Unbreaking" enchantment already, this behaviour has been in mcMMO for a long time.
Tree Feller will now give reduced XP per block destroyed by Tree Feller and will never go below 1 XP per block, you can turn this off with 'ExploitFix.TreeFellerReducedXP' in experience.yml
There was a bug fixed in this patch that prevents an issue where Tree Feller was not removing all blocks left behind, unfortunately this will only affect new trees made in the world. The only trees that suffered from this bug were ones in snowy areas that had snow form on them.
Version 2.1.88

View File

@ -167,7 +167,7 @@
<dependency>
<groupId>org.spigotmc</groupId>
<artifactId>spigot-api</artifactId>
<version>1.14.2-R0.1-SNAPSHOT</version>
<version>1.14.3-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
<dependency>

View File

@ -138,7 +138,6 @@ public class ExperienceConfig extends AutoUpdateConfigLoader {
}
public boolean isEarlyGameBoostEnabled() { return config.getBoolean("EarlyGameBoost.Enabled", true); }
public double getEarlyGameBoostMultiplier() { return config.getDouble("EarlyGameBoost.MaxLevelMultiplier", 0.05D); }
/*
* FORMULA SETTINGS
@ -151,6 +150,7 @@ public class ExperienceConfig extends AutoUpdateConfigLoader {
public boolean isFishingExploitingPrevented() { return config.getBoolean("ExploitFix.Fishing", true); }
public boolean isAcrobaticsExploitingPrevented() { return config.getBoolean("ExploitFix.Acrobatics", true); }
public boolean isTreeFellerXPReduced() { return config.getBoolean("ExploitFix.TreeFellerReducedXP", true); }
/* Curve settings */
public FormulaType getFormulaType() { return FormulaType.getFormulaType(config.getString("Experience_Formula.Curve")); }

View File

@ -41,7 +41,7 @@ public enum SubSkillType {
FISHING_SHAKE(1),
/* Herbalism */
HERBALISM_DOUBLE_DROPS,
HERBALISM_DOUBLE_DROPS(1),
HERBALISM_FARMERS_DIET(5),
HERBALISM_GREEN_TERRA(1),
HERBALISM_GREEN_THUMB(4),
@ -52,7 +52,7 @@ public enum SubSkillType {
MINING_BIGGER_BOMBS(1),
MINING_BLAST_MINING(8),
MINING_DEMOLITIONS_EXPERTISE(1),
MINING_DOUBLE_DROPS,
MINING_DOUBLE_DROPS(1),
MINING_SUPER_BREAKER(1),
/* Repair */

View File

@ -10,7 +10,6 @@ import com.gmail.nossr50.util.skills.SkillUtils;
import org.bukkit.Material;
import org.bukkit.block.BlockFace;
import org.bukkit.block.BlockState;
import org.bukkit.enchantments.Enchantment;
import org.bukkit.inventory.ItemStack;
import java.util.ArrayList;
@ -19,25 +18,17 @@ import java.util.Set;
public final class Woodcutting {
public static int treeFellerThreshold = Config.getInstance().getTreeFellerThreshold();
protected static boolean treeFellerReachedThreshold = false;
protected enum ExperienceGainMethod {
DEFAULT,
TREE_FELLER,
}
private Woodcutting() {}
/**
* Retrieves the experience reward from a log
*
* @param blockState Log being broken
* @param experienceGainMethod How the log is being broken
* @return Amount of experience
*/
protected static int getExperienceFromLog(BlockState blockState, ExperienceGainMethod experienceGainMethod) {
protected static int getExperienceFromLog(BlockState blockState) {
if (mcMMO.getModManager().isCustomLog(blockState)) {
return mcMMO.getModManager().getBlock(blockState).getXpGain();
}
@ -45,6 +36,33 @@ public final class Woodcutting {
return ExperienceConfig.getInstance().getXp(PrimarySkillType.WOODCUTTING, blockState.getType());
}
/**
* Retrieves the experience reward from logging via Tree Feller
* Experience is reduced per log processed so far
* Experience is only reduced if the config option to reduce Tree Feller XP is set
* Experience per log will not fall below 1 unless the experience for that log is set to 0 in the config
*
* @param blockState Log being broken
* @param woodCount how many logs have given out XP for this tree feller so far
* @return Amount of experience
*/
protected static int processTreeFellerXPGains(BlockState blockState, int woodCount) {
int rawXP = ExperienceConfig.getInstance().getXp(PrimarySkillType.WOODCUTTING, blockState.getType());
if(rawXP <= 0)
return 0;
if(ExperienceConfig.getInstance().isTreeFellerXPReduced()) {
int reducedXP = 1 + (woodCount * 5);
rawXP = Math.max(1, rawXP - reducedXP);
return rawXP;
} else {
return ExperienceConfig.getInstance().getXp(PrimarySkillType.WOODCUTTING, blockState.getType());
}
}
/**
* Checks for double drops
*

View File

@ -9,7 +9,6 @@ import com.gmail.nossr50.datatypes.skills.SubSkillType;
import com.gmail.nossr50.datatypes.skills.SuperAbilityType;
import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.skills.SkillManager;
import com.gmail.nossr50.skills.woodcutting.Woodcutting.ExperienceGainMethod;
import com.gmail.nossr50.util.*;
import com.gmail.nossr50.util.player.NotificationManager;
import com.gmail.nossr50.util.random.RandomChanceUtil;
@ -54,7 +53,7 @@ public class WoodcuttingManager extends SkillManager {
* @param blockState Block being broken
*/
public void woodcuttingBlockCheck(BlockState blockState) {
int xp = Woodcutting.getExperienceFromLog(blockState, ExperienceGainMethod.DEFAULT);
int xp = Woodcutting.getExperienceFromLog(blockState);
switch (blockState.getType()) {
case BROWN_MUSHROOM_BLOCK:
@ -116,6 +115,7 @@ public class WoodcuttingManager extends SkillManager {
private void dropBlocks(Set<BlockState> treeFellerBlocks) {
Player player = getPlayer();
int xp = 0;
int processedLogCount = 0;
for (BlockState blockState : treeFellerBlocks) {
Block block = blockState.getBlock();
@ -126,30 +126,18 @@ public class WoodcuttingManager extends SkillManager {
Material material = blockState.getType();
//TODO: Update this to drop the correct items/blocks via NMS
if (material == Material.BROWN_MUSHROOM_BLOCK || material == Material.RED_MUSHROOM_BLOCK) {
xp += Woodcutting.getExperienceFromLog(blockState, ExperienceGainMethod.TREE_FELLER);
xp += Woodcutting.processTreeFellerXPGains(blockState, processedLogCount);
Misc.dropItems(Misc.getBlockCenter(blockState), block.getDrops());
}
else if (mcMMO.getModManager().isCustomLog(blockState)) {
if (canGetDoubleDrops()) {
Woodcutting.checkForDoubleDrop(blockState);
}
CustomBlock customBlock = mcMMO.getModManager().getBlock(blockState);
xp = customBlock.getXpGain();
} else if (mcMMO.getModManager().isCustomLeaf(blockState)) {
Misc.dropItems(Misc.getBlockCenter(blockState), block.getDrops());
}
else if (mcMMO.getModManager().isCustomLeaf(blockState)) {
Misc.dropItems(Misc.getBlockCenter(blockState), block.getDrops());
}
else {
} else {
if (BlockUtils.isLog(blockState)) {
if (canGetDoubleDrops()) {
Woodcutting.checkForDoubleDrop(blockState);
}
xp += Woodcutting.getExperienceFromLog(blockState, ExperienceGainMethod.TREE_FELLER);
xp += Woodcutting.processTreeFellerXPGains(blockState, processedLogCount);
Misc.dropItems(Misc.getBlockCenter(blockState), block.getDrops());
}
if (BlockUtils.isLeaves(blockState)) {
@ -159,6 +147,7 @@ public class WoodcuttingManager extends SkillManager {
blockState.setType(Material.AIR);
blockState.update(true);
processedLogCount+=1;
}
applyXpGain(xp, XPGainReason.PVE);

View File

@ -1,43 +1,38 @@
package com.gmail.nossr50.util.player;
import com.gmail.nossr50.config.Config;
import com.gmail.nossr50.config.experience.ExperienceConfig;
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
import com.gmail.nossr50.datatypes.skills.PrimarySkillType;
import com.gmail.nossr50.mcMMO;
import java.util.HashMap;
public class PlayerLevelUtils {
HashMap<PrimarySkillType, Integer> earlyGameBoostCutoffs;
public PlayerLevelUtils()
{
earlyGameBoostCutoffs = new HashMap<>();
calculateEarlyGameBoostCutoffs();
}
private void calculateEarlyGameBoostCutoffs()
{
for(PrimarySkillType primarySkillType : PrimarySkillType.values())
{
int levelCap = Config.getInstance().getLevelCap(primarySkillType);
int cap;
if(levelCap == Integer.MAX_VALUE || levelCap <= 0)
{
cap = Config.getInstance().getIsRetroMode() ? 50 : 5;
} else {
cap = (int) (levelCap * ExperienceConfig.getInstance().getEarlyGameBoostMultiplier());
}
earlyGameBoostCutoffs.put(primarySkillType, cap);
}
}
// HashMap<PrimarySkillType, Integer> earlyGameBoostCutoffs;
//
// public PlayerLevelUtils()
// {
// earlyGameBoostCutoffs = new HashMap<>();
// calculateEarlyGameBoostCutoffs();
// }
// private void calculateEarlyGameBoostCutoffs()
// {
// for(PrimarySkillType primarySkillType : PrimarySkillType.values())
// {
// int levelCap = Config.getInstance().getLevelCap(primarySkillType);
// int cap;
//
// if(levelCap == Integer.MAX_VALUE || levelCap <= 0)
// {
// cap = Config.getInstance().getIsRetroMode() ? 50 : 5;
// } else {
// cap = (int) (levelCap * ExperienceConfig.getInstance().getEarlyGameBoostMultiplier());
// }
//
// earlyGameBoostCutoffs.put(primarySkillType, cap);
// }
// }
public int getEarlyGameCutoff(PrimarySkillType primarySkillType)
{
return earlyGameBoostCutoffs.get(primarySkillType);
return 1;
}
/**

View File

@ -77,14 +77,14 @@ Feedback:
SendCopyOfMessageToChat: true
Skills:
General:
StartingLevel: 1
StartingLevel: 0
Ability:
Length:
Standard:
CapLevel: 50
CapLevel: 100
IncreaseLevel: 5
RetroMode:
CapLevel: 500
CapLevel: 1000
IncreaseLevel: 50
EnchantBuff: 5
# IncreaseLevel: This setting will determine when the length of every ability gets longer with 1 second

View File

@ -24,8 +24,6 @@
# The bar is one solid piece
EarlyGameBoost:
Enabled: true
#Used to determine the cap of the max boot, with default level cap it will be 5 on standard, and 50 on retro
MaxLevelMultiplier: 0.05
ExploitFix:
UnsafeEnchantments: false
# Prevent many exploits related to fishing
@ -33,6 +31,7 @@ ExploitFix:
EndermanEndermiteFarms: true
Acrobatics: true
LavaStoneAndCobbleFarming: true
TreeFellerReducedXP: true
Experience_Bars:
# Turn this to false if you wanna disable XP bars
Enable: true

View File

@ -14,7 +14,7 @@ Alchemy:
Concoctions:
Standard:
Rank_1: 0
Rank_2: 25
Rank_2: 1
Rank_3: 35
Rank_4: 50
Rank_5: 65
@ -23,7 +23,7 @@ Alchemy:
Rank_8: 100
RetroMode:
Rank_1: 0
Rank_2: 250
Rank_2: 1
Rank_3: 350
Rank_4: 500
Rank_5: 650
@ -56,12 +56,12 @@ Archery:
Rank_10: 1000
ArrowRetrieval:
Standard:
Rank_1: 2
Rank_1: 1
RetroMode:
Rank_1: 20
Rank_1: 1
SkillShot:
Standard:
Rank_1: 5
Rank_1: 1
Rank_2: 10
Rank_3: 15
Rank_4: 20
@ -82,7 +82,7 @@ Archery:
Rank_19: 95
Rank_20: 100
RetroMode:
Rank_1: 50
Rank_1: 1
Rank_2: 100
Rank_3: 150
Rank_4: 200
@ -105,9 +105,9 @@ Archery:
Acrobatics:
Dodge:
Standard:
Rank_1: 2
Rank_1: 1
RetroMode:
Rank_1: 20
Rank_1: 1
Axes:
AxesLimitBreak:
Standard:
@ -139,9 +139,9 @@ Axes:
Rank_1: 50
CriticalStrikes:
Standard:
Rank_1: 2
Rank_1: 1
RetroMode:
Rank_1: 20
Rank_1: 1
GreaterImpact:
Standard:
Rank_1: 25
@ -149,7 +149,7 @@ Axes:
Rank_1: 250
ArmorImpact:
Standard:
Rank_1: 5
Rank_1: 1
Rank_2: 10
Rank_3: 15
Rank_4: 20
@ -170,7 +170,7 @@ Axes:
Rank_19: 95
Rank_20: 100
RetroMode:
Rank_1: 50
Rank_1: 1
Rank_2: 100
Rank_3: 150
Rank_4: 200
@ -204,9 +204,9 @@ Axes:
Taming:
BeastLore:
Standard:
Rank_1: 2
Rank_1: 1
RetroMode:
Rank_1: 20
Rank_1: 1
Gore:
Standard:
Rank_1: 15
@ -214,9 +214,9 @@ Taming:
Rank_1: 150
CallOfTheWild:
Standard:
Rank_1: 5
Rank_1: 1
RetroMode:
Rank_1: 50
Rank_1: 1
Pummel:
Standard:
Rank_1: 20
@ -284,7 +284,7 @@ Smelting:
Salvage:
ScrapCollector:
Standard:
Rank_1: 2
Rank_1: 1
Rank_2: 10
Rank_3: 15
Rank_4: 20
@ -293,7 +293,7 @@ Salvage:
Rank_7: 35
Rank_8: 40
RetroMode:
Rank_1: 20
Rank_1: 1
Rank_2: 100
Rank_3: 150
Rank_4: 200
@ -321,6 +321,11 @@ Salvage:
Rank_7: 850
Rank_8: 1000
Mining:
DoubleDrops:
Standard:
Rank_1: 1
RetroMode:
Rank_1: 1
SuperBreaker:
Standard:
Rank_1: 5
@ -358,6 +363,11 @@ Mining:
Rank_7: 850
Rank_8: 1000
Herbalism:
DoubleDrops:
Standard:
Rank_1: 1
RetroMode:
Rank_1: 1
GreenTerra:
Standard:
Rank_1: 5
@ -423,7 +433,7 @@ Fishing:
Rank_5: 1000
TreasureHunter:
Standard:
Rank_1: 10
Rank_1: 1
Rank_2: 25
Rank_3: 35
Rank_4: 50
@ -432,7 +442,7 @@ Fishing:
Rank_7: 85
Rank_8: 100
RetroMode:
Rank_1: 100
Rank_1: 1
Rank_2: 250
Rank_3: 350
Rank_4: 500
@ -478,20 +488,20 @@ Swords:
Rank_1: 200
Rupture:
Standard:
Rank_1: 5
Rank_1: 1
Rank_2: 15
Rank_3: 75
Rank_4: 90
RetroMode:
Rank_1: 50
Rank_1: 1
Rank_2: 150
Rank_3: 750
Rank_4: 900
SerratedStrikes:
Standard:
Rank_1: 10
Rank_1: 5
RetroMode:
Rank_1: 100
Rank_1: 50
Unarmed:
UnarmedLimitBreak:
Standard:
@ -518,9 +528,9 @@ Unarmed:
Rank_10: 1000
Berserk:
Standard:
Rank_1: 10
Rank_1: 5
RetroMode:
Rank_1: 100
Rank_1: 50
ArrowDeflect:
Standard:
Rank_1: 20
@ -538,13 +548,13 @@ Unarmed:
Rank_1: 600
IronArmStyle:
Standard:
Rank_1: 2
Rank_1: 1
Rank_2: 25
Rank_3: 50
Rank_4: 75
Rank_5: 100
RetroMode:
Rank_1: 20
Rank_1: 1
Rank_2: 250
Rank_3: 500
Rank_4: 750
@ -595,7 +605,7 @@ Woodcutting:
Standard:
Rank_1: 1
RetroMode:
Rank_1: 10
Rank_1: 1
LeafBlower:
Standard:
Rank_1: 15
@ -613,7 +623,7 @@ Excavation:
Rank_1: 50
Archaeology:
Standard:
Rank_1: 5
Rank_1: 1
Rank_2: 25
Rank_3: 35
Rank_4: 50
@ -622,7 +632,7 @@ Excavation:
Rank_7: 85
Rank_8: 100
RetroMode:
Rank_1: 50
Rank_1: 1
Rank_2: 250
Rank_3: 350
Rank_4: 500
@ -633,9 +643,9 @@ Excavation:
Repair:
RepairMastery:
Standard:
Rank_1: 20
Rank_1: 1
RetroMode:
Rank_1: 200
Rank_1: 1
SuperRepair:
Standard:
Rank_1: 40