|
@@ -12,6 +12,7 @@ import me.sargunvohra.mcmods.autoconfig1u.AutoConfig;
|
|
|
import monkey.lumpy.horse.stats.vanilla.config.ModConfig;
|
|
|
import monkey.lumpy.horse.stats.vanilla.gui.ToolTipGui;
|
|
|
import monkey.lumpy.horse.stats.vanilla.gui.Tooltip;
|
|
|
+import monkey.lumpy.horse.stats.vanilla.util.Converter;
|
|
|
import net.minecraft.client.MinecraftClient;
|
|
|
import net.minecraft.entity.EntityType;
|
|
|
import net.minecraft.entity.attribute.EntityAttributes;
|
|
@@ -43,7 +44,7 @@ public abstract class HorseEntityMixin extends HorseBaseEntity {
|
|
|
DecimalFormat df = new DecimalFormat("#.#");
|
|
|
String jumpstrength = df.format( 0.695 * (this.getJumpStrength() * 10) - 1.736);
|
|
|
String maxHealth = df.format(this.getMaxHealth());
|
|
|
- String speed = df.format( 0.42466 * (this.getAttributes().getValue(EntityAttributes.GENERIC_MOVEMENT_SPEED) * 100) + 0.112665);
|
|
|
+ String speed = df.format(Converter.genericSpeedToBlocPerSec(this.getAttributes().getValue(EntityAttributes.GENERIC_MOVEMENT_SPEED)));
|
|
|
|
|
|
double jumpValue = new BigDecimal(jumpstrength.replace(',', '.')).doubleValue();
|
|
|
double speedValue = new BigDecimal(speed.replace(',', '.')).doubleValue();
|