Replace float to double

This commit is contained in:
TheMode 2021-06-16 12:26:27 +02:00
parent 0bdc84558f
commit 84f22a6ed4
2 changed files with 13 additions and 13 deletions

View File

@ -563,7 +563,7 @@ public class Entity implements Viewable, Tickable, EventHandler<EntityEvent>, Da
this.velocity.multiply(tps); this.velocity.multiply(tps);
final Block block = finalChunk.getBlock(position.toBlockPosition()); final Block block = finalChunk.getBlock(position.toBlockPosition());
final float drag = block.registry().friction(); final double drag = block.registry().friction();
if (onGround) { if (onGround) {
// Stop player velocity // Stop player velocity
if (isNettyClient) { if (isNettyClient) {

View File

@ -53,24 +53,24 @@ public class Registry {
return getInt("stateId"); return getInt("stateId");
} }
public float destroySpeed() { public double destroySpeed() {
return getFloat("destroySpeed"); return getDouble("destroySpeed");
} }
public float explosionResistance() { public double explosionResistance() {
return getFloat("explosionResistance"); return getDouble("explosionResistance");
} }
public float friction() { public double friction() {
return getFloat("friction"); return getDouble("friction");
} }
public float speedFactor() { public double speedFactor() {
return getFloat("speedFactor"); return getDouble("speedFactor");
} }
public float jumpFactor() { public double jumpFactor() {
return getFloat("jumpFactor"); return getDouble("jumpFactor");
} }
public boolean isAir() { public boolean isAir() {
@ -98,8 +98,8 @@ public class Registry {
return element(name).getAsString(); return element(name).getAsString();
} }
public float getFloat(String name) { public double getDouble(String name) {
return element(name).getAsFloat(); return element(name).getAsDouble();
} }
public int getInt(String name) { public int getInt(String name) {