Reworked Iron Arm Style into Steel Arm Style which scales over 20 ranks

This commit is contained in:
nossr50 2020-08-17 23:32:13 -07:00
parent dca2661ccb
commit c6b2cba007
10 changed files with 73 additions and 35 deletions

View File

@ -1,3 +1,12 @@
Version 2.1.142
Iron Arm Style renamed to Steel Arm Style
Steel Arm Style now scales over 20 ranks instead of 5
Added 'mcmmo.ability.unarmed.steelarmstyle' permission node
Removed 'mcmmo.ability.unarmed.ironarmstyle' permission node
Added locale entry 'Unarmed.SubSkill.SteelArmStyle.Name'
Added locale entry 'Unarmed.SubSkill.SteelArmStyle.Description'
Updated locale entry 'Unarmed.Ability.Bonus.0'
Version 2.1.141
Added some missing values for 1.16.2 compatibility modes

View File

@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.gmail.nossr50.mcMMO</groupId>
<artifactId>mcMMO</artifactId>
<version>2.1.141</version>
<version>2.1.142-SNAPSHOT</version>
<name>mcMMO</name>
<url>https://github.com/mcMMO-Dev/mcMMO</url>
<scm>

View File

@ -61,7 +61,7 @@ public class UnarmedCommand extends SkillCommand {
// IRON ARM
if (canIronArm) {
ironArmBonus = UserManager.getPlayer(player).getUnarmedManager().getIronArmDamage();
ironArmBonus = UserManager.getPlayer(player).getUnarmedManager().getSteelArmStyleDamage();
}
// IRON GRIP
@ -75,7 +75,7 @@ public class UnarmedCommand extends SkillCommand {
@Override
protected void permissionsCheck(Player player) {
canBerserk = RankUtils.hasUnlockedSubskill(player, SubSkillType.UNARMED_BERSERK) && Permissions.berserk(player);
canIronArm = canUseSubskill(player, SubSkillType.UNARMED_IRON_ARM_STYLE);
canIronArm = canUseSubskill(player, SubSkillType.UNARMED_STEEL_ARM_STYLE);
canDeflect = canUseSubskill(player, SubSkillType.UNARMED_ARROW_DEFLECT);
canDisarm = canUseSubskill(player, SubSkillType.UNARMED_DISARM);
canIronGrip = canUseSubskill(player, SubSkillType.UNARMED_IRON_GRIP);

View File

@ -61,7 +61,7 @@ public enum PrimarySkillType {
TAMING(TamingManager.class, Color.PURPLE,
ImmutableList.of(SubSkillType.TAMING_BEAST_LORE, SubSkillType.TAMING_CALL_OF_THE_WILD, SubSkillType.TAMING_ENVIRONMENTALLY_AWARE, SubSkillType.TAMING_FAST_FOOD_SERVICE, SubSkillType.TAMING_GORE, SubSkillType.TAMING_HOLY_HOUND, SubSkillType.TAMING_SHARPENED_CLAWS, SubSkillType.TAMING_SHOCK_PROOF, SubSkillType.TAMING_THICK_FUR, SubSkillType.TAMING_PUMMEL)),
UNARMED(UnarmedManager.class, Color.BLACK, SuperAbilityType.BERSERK, ToolType.FISTS,
ImmutableList.of(SubSkillType.UNARMED_BERSERK, SubSkillType.UNARMED_UNARMED_LIMIT_BREAK, SubSkillType.UNARMED_BLOCK_CRACKER, SubSkillType.UNARMED_ARROW_DEFLECT, SubSkillType.UNARMED_DISARM, SubSkillType.UNARMED_IRON_ARM_STYLE, SubSkillType.UNARMED_IRON_GRIP)),
ImmutableList.of(SubSkillType.UNARMED_BERSERK, SubSkillType.UNARMED_UNARMED_LIMIT_BREAK, SubSkillType.UNARMED_BLOCK_CRACKER, SubSkillType.UNARMED_ARROW_DEFLECT, SubSkillType.UNARMED_DISARM, SubSkillType.UNARMED_STEEL_ARM_STYLE, SubSkillType.UNARMED_IRON_GRIP)),
WOODCUTTING(WoodcuttingManager.class, Color.OLIVE, SuperAbilityType.TREE_FELLER, ToolType.AXE,
ImmutableList.of(SubSkillType.WOODCUTTING_LEAF_BLOWER, SubSkillType.WOODCUTTING_TREE_FELLER, SubSkillType.WOODCUTTING_HARVEST_LUMBER));

View File

@ -95,7 +95,7 @@ public enum SubSkillType {
UNARMED_BERSERK(1),
UNARMED_BLOCK_CRACKER,
UNARMED_DISARM(1),
UNARMED_IRON_ARM_STYLE(5),
UNARMED_STEEL_ARM_STYLE(20),
UNARMED_IRON_GRIP(1),
UNARMED_UNARMED_LIMIT_BREAK(10),

View File

@ -36,10 +36,10 @@ public class UnarmedManager extends SkillManager {
}
public boolean canUseIronArm() {
if(!RankUtils.hasUnlockedSubskill(getPlayer(), SubSkillType.UNARMED_IRON_ARM_STYLE))
if(!RankUtils.hasUnlockedSubskill(getPlayer(), SubSkillType.UNARMED_STEEL_ARM_STYLE))
return false;
return Permissions.isSubSkillEnabled(getPlayer(), SubSkillType.UNARMED_IRON_ARM_STYLE);
return Permissions.isSubSkillEnabled(getPlayer(), SubSkillType.UNARMED_STEEL_ARM_STYLE);
}
public boolean canUseBerserk() {
@ -146,23 +146,22 @@ public class UnarmedManager extends SkillManager {
/**
* Handle the effects of the Iron Arm ability
*/
public double calculateIronArmDamage() {
if (!RandomChanceUtil.isActivationSuccessful(SkillActivationType.ALWAYS_FIRES, SubSkillType.UNARMED_IRON_ARM_STYLE, getPlayer())) {
public double calculateSteelArmStyleDamage() {
if (!RandomChanceUtil.isActivationSuccessful(SkillActivationType.ALWAYS_FIRES, SubSkillType.UNARMED_STEEL_ARM_STYLE, getPlayer())) {
return 0;
}
return getIronArmDamage();
return getSteelArmStyleDamage();
}
public double getIronArmDamage() {
int rank = RankUtils.getRank(getPlayer(), SubSkillType.UNARMED_IRON_ARM_STYLE);
public double getSteelArmStyleDamage() {
double rank = RankUtils.getRank(getPlayer(), SubSkillType.UNARMED_STEEL_ARM_STYLE);
double bonus = 0;
if(rank == 1)
{
return 1.5;
} else {
return 3 + (rank * 2);
}
if(rank >= 18)
bonus = 1 + rank - 18;
return bonus + 0.5 + (rank / 2);
}
/**

View File

@ -188,7 +188,7 @@ public final class CombatUtils {
//Only execute bonuses if the player is not spamming
if (unarmedManager.canUseIronArm()) {
finalDamage+=(unarmedManager.calculateIronArmDamage() * mcMMOPlayer.getAttackStrength());
finalDamage+=(unarmedManager.calculateSteelArmStyleDamage() * mcMMOPlayer.getAttackStrength());
}
if (unarmedManager.canUseBerserk()) {

View File

@ -489,7 +489,7 @@ Taming.Summon.COTW.BreedingDisallowed=[[GREEN]](Call Of The Wild) [[RED]]You can
Taming.Summon.COTW.NeedMoreItems=[[GREEN]](Call Of The Wild) [[GRAY]]You need [[YELLOW]]{0}[[GRAY]] more [[DARK_AQUA]]{1}[[GRAY]](s)
Taming.Summon.Name.Format=[[GOLD]](COTW) [[WHITE]]{0}'s {1}
#UNARMED
Unarmed.Ability.Bonus.0=Iron Arm Style
Unarmed.Ability.Bonus.0=Steel Arm Style
Unarmed.Ability.Bonus.1=+{0} DMG Upgrade
Unarmed.Ability.IronGrip.Attacker=Your opponent has an iron grip!
Unarmed.Ability.IronGrip.Defender=[[GREEN]]Your iron grip kept you from being disarmed!
@ -504,8 +504,8 @@ Unarmed.SubSkill.Disarm.Stat=Disarm Chance
Unarmed.SubSkill.UnarmedLimitBreak.Name=Unarmed Limit Break
Unarmed.SubSkill.UnarmedLimitBreak.Description=Breaking your limits. Increased damage against tough opponents. Intended for PVP, up to server settings for whether or not it will boost damage in PVE.
Unarmed.SubSkill.UnarmedLimitBreak.Stat=Limit Break Max DMG
Unarmed.SubSkill.IronArmStyle.Name=Iron Arm Style
Unarmed.SubSkill.IronArmStyle.Description=Hardens your arm over time
Unarmed.SubSkill.SteelArmStyle.Name=Steel Arm Style
Unarmed.SubSkill.SteelArmStyle.Description=Hardens your arm over time
Unarmed.SubSkill.ArrowDeflect.Name=Arrow Deflect
Unarmed.SubSkill.ArrowDeflect.Description=Deflect arrows
Unarmed.SubSkill.ArrowDeflect.Stat=Arrow Deflect Chance
@ -947,7 +947,7 @@ Guides.Taming.Section.8=[[DARK_AQUA]]How does Fast Food Service work?\n[[YELLOW]
##Unarmed
Guides.Unarmed.Section.0=[[DARK_AQUA]]About Unarmed:\n[[YELLOW]]Unarmed will give players various combat bonuses when using\n[[YELLOW]]your fists as a weapon. \n\n[[DARK_AQUA]]XP GAIN:\n[[YELLOW]]XP is gained based on the amount of damage dealt to mobs \n[[YELLOW]]or other players when unarmed.
Guides.Unarmed.Section.1=[[DARK_AQUA]]How does Berserk work?\n[[YELLOW]]Beserk is an active ability that is activated by\n[[YELLOW]]right-clicking. While in Beserk mode, you deal 50% more\n[[YELLOW]]damage and you can break weak materials instantly, such as\n[[YELLOW]]Dirt and Grass.
Guides.Unarmed.Section.2=[[DARK_AQUA]]How does Iron Arm work?\n[[YELLOW]]Iron Arm increases the damage dealt when hitting mobs or\n[[YELLOW]]players with your fists.
Guides.Unarmed.Section.2=[[DARK_AQUA]]How does Steel Arm Style work?\n[[YELLOW]]Steel Arm Style increases the damage dealt when hitting mobs or\n[[YELLOW]]players with your fists.
Guides.Unarmed.Section.3=[[DARK_AQUA]]How does Arrow Deflect work?\n[[YELLOW]]Arrow Deflect is a passive ability that gives you a chance\n[[YELLOW]]to deflect arrows shot by Skeletons or other players.\n[[YELLOW]]The arrow will fall harmlessly to the ground.
Guides.Unarmed.Section.4=[[DARK_AQUA]]How does Iron Grip work?\n[[YELLOW]]Iron Grip is a passive ability that counters disarm. As your\n[[YELLOW]]unarmed level increases, the chance of preventing a disarm increases.
Guides.Unarmed.Section.5=[[DARK_AQUA]]How does Disarm work?\n[[YELLOW]]This passive ability allows players to disarm other players,\n[[YELLOW]]causing the target's equipped item to fall to the ground.

View File

@ -664,7 +664,7 @@ permissions:
children:
mcmmo.ability.unarmed.berserk: true
mcmmo.ability.unarmed.blockcracker: true
mcmmo.ability.unarmed.ironarmstyle: true
mcmmo.ability.unarmed.steelarmstyle: true
mcmmo.ability.unarmed.arrowdeflect: true
mcmmo.ability.unarmed.disarm: true
mcmmo.ability.unarmed.irongrip: true
@ -675,8 +675,8 @@ permissions:
description: Allows access to the Berserker ability
mcmmo.ability.unarmed.blockcracker:
description: Allows access to the Block Cracker ability
mcmmo.ability.unarmed.ironarmstyle:
description: Allows bonus damage from the Iron Arm ability
mcmmo.ability.unarmed.steelarmstyle:
description: Allows bonus damage from the Steel Arm Style ability
mcmmo.ability.unarmed.arrowdeflect:
description: Allows access to the Arrow Deflect ability
mcmmo.ability.unarmed.disarm:

View File

@ -546,19 +546,49 @@ Unarmed:
Rank_1: 60
RetroMode:
Rank_1: 600
IronArmStyle:
SteelArmStyle:
Standard:
Rank_1: 1
Rank_2: 25
Rank_3: 50
Rank_4: 75
Rank_5: 100
Rank_2: 10
Rank_3: 15
Rank_4: 20
Rank_5: 25
Rank_6: 30
Rank_7: 35
Rank_8: 40
Rank_9: 45
Rank_10: 50
Rank_11: 55
Rank_12: 60
Rank_13: 65
Rank_14: 70
Rank_15: 75
Rank_16: 80
Rank_17: 85
Rank_18: 90
Rank_19: 95
Rank_20: 100
RetroMode:
Rank_1: 1
Rank_2: 250
Rank_3: 500
Rank_4: 750
Rank_5: 1000
Rank_2: 100
Rank_3: 150
Rank_4: 200
Rank_5: 250
Rank_6: 300
Rank_7: 350
Rank_8: 400
Rank_9: 450
Rank_10: 500
Rank_11: 550
Rank_12: 600
Rank_13: 650
Rank_14: 700
Rank_15: 750
Rank_16: 800
Rank_17: 850
Rank_18: 900
Rank_19: 950
Rank_20: 1000
Woodcutting:
Splinter: