mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-26 07:06:45 +01:00
Dealing with more minor typecasting issues.
This commit is contained in:
parent
0037524cfd
commit
cc044fe41b
@ -43,7 +43,7 @@ public class AxesCommand extends SkillCommand {
|
||||
int skillCheck = Misc.skillCheck((int)skillValue, critMaxBonusLevel);
|
||||
|
||||
impactDamage = String.valueOf(1 + ((double) skillValue / (double) greaterImpactIncreaseLevel));
|
||||
skullSplitterLength = String.valueOf(2 + ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
skullSplitterLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
greaterImpactDamage = "2";
|
||||
|
||||
if (skillValue >= critMaxBonusLevel) critChance = df.format(critMaxChance);
|
||||
|
@ -22,7 +22,7 @@ public class ExcavationCommand extends SkillCommand {
|
||||
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
gigaDrillBreakerLength = String.valueOf(2 + ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
gigaDrillBreakerLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -43,7 +43,7 @@ public class HerbalismCommand extends SkillCommand {
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
greenTerraLength = String.valueOf(2 + ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
greenTerraLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
//FARMERS DIET
|
||||
if(skillValue >= farmersDietMaxLevel) farmersDietRank = "5";
|
||||
else farmersDietRank = String.valueOf((double) skillValue / (double) farmersDietRankChange);
|
||||
|
@ -46,7 +46,7 @@ public class MiningCommand extends SkillCommand {
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
superBreakerLength = String.valueOf(2 + ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
superBreakerLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
if(skillValue >= doubleDropsMaxLevel) doubleDropChance = df.format(doubleDropsMaxBonus);
|
||||
else doubleDropChance = df.format(((double) doubleDropsMaxBonus / (double) doubleDropsMaxLevel) * (double) skillValue);
|
||||
|
||||
|
@ -37,7 +37,7 @@ public class SwordsCommand extends SkillCommand {
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
serratedStrikesLength = String.valueOf(2 + ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
serratedStrikesLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
|
||||
if (skillValue >= bleedMaxLevel) bleedLength = String.valueOf(bleedMaxTicks);
|
||||
else bleedLength = String.valueOf(bleedBaseTicks);
|
||||
|
@ -36,7 +36,7 @@ public class UnarmedCommand extends SkillCommand {
|
||||
@Override
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("#.0");
|
||||
berserkLength = String.valueOf(2 + ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
berserkLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
|
||||
if(skillValue >= disarmMaxLevel) disarmChance = df.format(disarmChanceMax);
|
||||
else disarmChance = df.format(((double) disarmChanceMax / (double) disarmMaxLevel) * (double) skillValue);
|
||||
|
@ -33,7 +33,7 @@ public class WoodcuttingCommand extends SkillCommand {
|
||||
protected void dataCalculations() {
|
||||
DecimalFormat df = new DecimalFormat("0.0");
|
||||
|
||||
treeFellerLength = String.valueOf(2 + ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
treeFellerLength = String.valueOf(2 + (int) ((double) skillValue / (double) abilityLengthIncreaseLevel));
|
||||
if(skillValue >= doubleDropsMaxLevel) doubleDropChance = df.format(doubleDropsMaxBonus);
|
||||
else doubleDropChance = df.format(((double) doubleDropsMaxBonus / (double) doubleDropsMaxLevel) * (double) skillValue);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user