Merge branch 'proto_1.12.2' into world-loader-anvil
This commit is contained in:
@@ -3,6 +3,7 @@ package mc.core;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import org.springframework.lang.Nullable;
|
||||
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@@ -32,15 +33,15 @@ public class EntityLocation implements Cloneable {
|
||||
}
|
||||
|
||||
public int getBlockX() {
|
||||
return Double.valueOf(Math.floor(x)).intValue();
|
||||
return (int) Math.floor(x);
|
||||
}
|
||||
|
||||
public int getBlockY() {
|
||||
return Double.valueOf(Math.floor(y)).intValue();
|
||||
return (int) Math.floor(y);
|
||||
}
|
||||
|
||||
public int getBlockZ() {
|
||||
return Double.valueOf(Math.floor(z)).intValue();
|
||||
return (int) Math.floor(z);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -49,7 +50,7 @@ public class EntityLocation implements Cloneable {
|
||||
return (EntityLocation) super.clone();
|
||||
} catch (CloneNotSupportedException e) {
|
||||
e.printStackTrace();
|
||||
return null;
|
||||
return ZERO();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,12 +1,8 @@
|
||||
package mc.core.world.block;
|
||||
|
||||
import com.flowpowered.nbt.Tag;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
public abstract class AbstractBlock implements Block {
|
||||
@Getter
|
||||
@Setter
|
||||
@@ -15,7 +11,6 @@ public abstract class AbstractBlock implements Block {
|
||||
private int light = 0;
|
||||
@Getter
|
||||
private final BlockType blockType;
|
||||
private final Map<String, Tag<?>> nbtTagsMap = new HashMap<>();
|
||||
|
||||
protected AbstractBlock(BlockType type) {
|
||||
this.blockType = type;
|
||||
|
||||
@@ -43,7 +43,7 @@ public class BlockLocation implements Cloneable {
|
||||
return (BlockLocation) super.clone();
|
||||
} catch (CloneNotSupportedException e) {
|
||||
e.printStackTrace();
|
||||
return null;
|
||||
return ZERO();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user