Converting some remaining float literals to double literals

This commit is contained in:
nossr50 2019-06-04 21:18:51 -07:00
parent fc6c6ed2c4
commit 94df19bdb4
7 changed files with 11 additions and 11 deletions

View File

@ -12,7 +12,7 @@ import java.util.HashMap;
@ConfigSerializable
public class ConfigExperience {
private static final double GLOBAL_XP_MULT_DEFAULT = 1.0F;
private static final double GLOBAL_XP_MULT_DEFAULT = 1.0;
@Setting(value = "Global-XP-Multiplier", comment = "This multiplier is applied at the very end of every XP gain, you can use it as a shortcut to increase or decrease xp gains across the entire plugin" +
"\nThis value is temporarily overridden by xprate events." +

View File

@ -9,7 +9,7 @@ import java.util.HashMap;
public class ConfigExperienceAcrobatics {
private final static HashMap<String, Integer> ACROBATICS_DEFAULT_XP_MAP;
private static final double FEATHER_FALL_MULTIPLIER_DEFAULT = 2.0F;
private static final double FEATHER_FALL_MULTIPLIER_DEFAULT = 2.0;
static {
ACROBATICS_DEFAULT_XP_MAP = new HashMap<>();

View File

@ -6,7 +6,7 @@ import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable;
@ConfigSerializable
public class ConfigExperienceArchery {
public static final double DISTANCE_MULTIPLIER_DEFAULT = 0.025F;
public static final double DISTANCE_MULTIPLIER_DEFAULT = 0.025;
@Setting(value = "Distance-Multiplier", comment = "The distance multiplier is multiplied against the distance an " +
"arrow travels before hitting its target to determine final XP values awarded." +

View File

@ -9,7 +9,7 @@ import java.util.HashMap;
@ConfigSerializable
public class ConfigExperienceRepair {
private static final double REPAIR_XP_BASE_DEFAULT = 1000.0F;
private static final double REPAIR_XP_BASE_DEFAULT = 1000.0;
private static final HashMap<ItemMaterialCategory, Double> ITEM_MATERIAL_XP_MULTIPLIER_DEFAULT;

View File

@ -7,8 +7,8 @@ import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable;
public class ConfigExperienceFormulaExponential {
private static final int BASE_DEFAULT = 2000;
private static final double MULTIPLIER_DEFAULT = 0.1f;
private static final double EXPONENT_DEFAULT = 1.80f;
private static final double MULTIPLIER_DEFAULT = 0.1;
private static final double EXPONENT_DEFAULT = 1.80;
@Setting(value = "Base-Amount", comment = "Default value: " + BASE_DEFAULT)
private int baseModifier = BASE_DEFAULT;

View File

@ -7,7 +7,7 @@ import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable;
public class ConfigExperienceFormulaLinear {
private static final int BASE_DEFAULT = 1020;
private static final double MULTIPLIER_DEFAULT = 20.0F;
private static final double MULTIPLIER_DEFAULT = 20.0;
@Setting(value = "Base-Amount", comment = "Default value: " + BASE_DEFAULT)
private int baseModifier = BASE_DEFAULT;

View File

@ -12,7 +12,7 @@ import static com.gmail.nossr50.datatypes.skills.PrimarySkillType.*;
public class ConfigLevelingDiminishedReturns {
private static final HashMap<PrimarySkillType, Integer> SKILL_THRESHOLDS_DEFAULT;
private static final float GUARANTEED_MIN_DEFAULT = 0.05f;
private static final double GUARANTEED_MIN_DEFAULT = 0.05;
static {
SKILL_THRESHOLDS_DEFAULT = new HashMap<>();
@ -49,8 +49,8 @@ public class ConfigLevelingDiminishedReturns {
@Setting(value = "Guaranteed-Minimum", comment = "The multiplier applied to an XP gain when a player has reached diminishing returns to guarantee that some XP is still gained." +
"\nPlayers will gain (raw XP * guaranteedMinimum) if they are under sever enough diminishing return penalty (ie their XP would normally fall below this value)" +
"\nDefault value: ")
private float guaranteedMinimums = GUARANTEED_MIN_DEFAULT;
"\nDefault value: "+GUARANTEED_MIN_DEFAULT)
private double guaranteedMinimums = GUARANTEED_MIN_DEFAULT;
public int getSkillThreshold(PrimarySkillType primarySkillType) {
if (skillThresholds.get(primarySkillType) == null)
@ -59,7 +59,7 @@ public class ConfigLevelingDiminishedReturns {
return skillThresholds.get(primarySkillType);
}
public float getGuaranteedMinimums() {
public double getGuaranteedMinimums() {
return guaranteedMinimums;
}