Dealing with more minor typecasting issues.

This commit is contained in:
Glitchfinder 2012-11-26 12:20:44 -08:00
parent 0037524cfd
commit cc044fe41b
8 changed files with 8 additions and 8 deletions

View File

@ -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);

View File

@ -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

View File

@ -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);

View File

@ -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);

View File

@ -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);

View File

@ -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);

View File

@ -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);
}