mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-25 22:56:45 +01:00
Adresses issue #364
This commit is contained in:
parent
2c8bfd6573
commit
e13ba010bf
@ -33,7 +33,7 @@ public class AcrobaticsCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
// DODGE
|
||||
if(skillValue >= dodgeMaxBonusLevel) dodgeChance = df.format(dodgeChanceMax);
|
||||
else dodgeChance = df.format(((double) dodgeChanceMax / (double) dodgeMaxBonusLevel) * skillValue);
|
||||
|
@ -37,7 +37,7 @@ public class ArcheryCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
// SkillShot
|
||||
double bonus = (int)((double) skillValue / (double) skillShotIncreaseLevel) * skillShotIncreasePercentage;
|
||||
if (bonus > skillShotBonusMax) skillShotBonus = percent.format(skillShotBonusMax);
|
||||
|
@ -39,7 +39,7 @@ public class AxesCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
int skillCheck = Misc.skillCheck((int)skillValue, critMaxBonusLevel);
|
||||
|
||||
impactDamage = String.valueOf(1 + ((double) skillValue / (double) greaterImpactIncreaseLevel));
|
||||
|
@ -42,7 +42,7 @@ public class HerbalismCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
greenTerraLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
//FARMERS DIET
|
||||
if(skillValue >= farmersDietMaxLevel) farmersDietRank = "5";
|
||||
@ -53,7 +53,7 @@ public class HerbalismCommand extends SkillCommand {
|
||||
|
||||
|
||||
if(skillValue >= greenThumbMaxLevel) greenThumbChance = String.valueOf(greenThumbMaxBonus);
|
||||
else greenThumbChance = String.valueOf((greenThumbMaxBonus / greenThumbMaxLevel) * skillValue);
|
||||
else greenThumbChance = df.format((greenThumbMaxBonus / greenThumbMaxLevel) * skillValue);
|
||||
//DOUBLE DROPS
|
||||
if(skillValue >= doubleDropsMaxLevel) doubleDropChance = df.format(doubleDropsMaxBonus);
|
||||
else doubleDropChance = df.format((doubleDropsMaxBonus / doubleDropsMaxLevel) * skillValue);
|
||||
|
@ -45,7 +45,7 @@ public class MiningCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
superBreakerLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
if(skillValue >= doubleDropsMaxLevel) doubleDropChance = df.format(doubleDropsMaxBonus);
|
||||
else doubleDropChance = df.format((doubleDropsMaxBonus / doubleDropsMaxLevel) * skillValue);
|
||||
|
@ -49,7 +49,7 @@ public class RepairCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
// We're using pickaxes here, not the best but it works
|
||||
Repairable diamondRepairable = mcMMO.repairManager.getRepairable(278);
|
||||
Repairable goldRepairable = mcMMO.repairManager.getRepairable(285);
|
||||
|
@ -36,7 +36,7 @@ public class SwordsCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
serratedStrikesLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
|
||||
if (skillValue >= bleedMaxLevel) bleedLength = String.valueOf(bleedMaxTicks);
|
||||
|
@ -38,7 +38,7 @@ public class TamingCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
if(skillValue >= goreMaxLevel) goreChance = df.format(goreChanceMax);
|
||||
else goreChance = df.format(((double) goreChanceMax / (double) goreMaxLevel) * skillValue);
|
||||
}
|
||||
|
@ -35,7 +35,7 @@ public class UnarmedCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
berserkLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
|
||||
if(skillValue >= disarmMaxLevel) disarmChance = df.format(disarmChanceMax);
|
||||
|
Loading…
Reference in New Issue
Block a user