mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2026-04-24 09:06:39 +00:00
fix imports
This commit is contained in:
@@ -16,7 +16,7 @@ import java.util.stream.Collectors;
|
||||
public class ForgeBlockData implements BlockData {
|
||||
private static final Function<Map.Entry<Property<?>, Comparable<?>>, String> PROPERTY_MAPPER = new Function<Map.Entry<Property<?>, Comparable<?>>, String>() {
|
||||
public String apply(@Nullable Map.Entry<Property<?>, Comparable<?>> entry) {
|
||||
if (entry == null) {
|
||||
if(entry == null) {
|
||||
return "<NULL>";
|
||||
} else {
|
||||
Property<?> property = entry.getKey();
|
||||
@@ -26,7 +26,7 @@ public class ForgeBlockData implements BlockData {
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
private <T extends Comparable<T>> String getName(Property<T> property, Comparable<?> comparable) {
|
||||
return property.getName((T)comparable);
|
||||
return property.getName((T) comparable);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -80,12 +80,14 @@ public class ForgeChunkGeneratorWrapper extends ChunkGenerator implements Genera
|
||||
}
|
||||
|
||||
@Override
|
||||
protected @NotNull Codec<? extends ChunkGenerator> codec() {
|
||||
protected @NotNull
|
||||
Codec<? extends ChunkGenerator> codec() {
|
||||
return CODEC;
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NotNull ChunkGenerator withSeed(long seed) {
|
||||
public @NotNull
|
||||
ChunkGenerator withSeed(long seed) {
|
||||
return new ForgeChunkGeneratorWrapper((TerraBiomeSource) this.biomeSource.withSeed(seed), seed, pack);
|
||||
}
|
||||
|
||||
@@ -153,7 +155,8 @@ public class ForgeChunkGeneratorWrapper extends ChunkGenerator implements Genera
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NotNull IBlockReader getBaseColumn(int x, int z) {
|
||||
public @NotNull
|
||||
IBlockReader getBaseColumn(int x, int z) {
|
||||
TerraWorld world = TerraForgePlugin.getInstance().getWorld(dimensionType);
|
||||
int height = getBaseHeight(x, z, Heightmap.Type.WORLD_SURFACE);
|
||||
BlockState[] array = new BlockState[256];
|
||||
|
||||
@@ -40,7 +40,8 @@ public class TerraBiomeSource extends net.minecraft.world.biome.provider.BiomePr
|
||||
}
|
||||
|
||||
@Override
|
||||
protected @NotNull Codec<? extends net.minecraft.world.biome.provider.BiomeProvider> codec() {
|
||||
protected @NotNull
|
||||
Codec<? extends net.minecraft.world.biome.provider.BiomeProvider> codec() {
|
||||
return CODEC;
|
||||
}
|
||||
|
||||
@@ -50,7 +51,8 @@ public class TerraBiomeSource extends net.minecraft.world.biome.provider.BiomePr
|
||||
}
|
||||
|
||||
@Override
|
||||
public @NotNull Biome getNoiseBiome(int biomeX, int biomeY, int biomeZ) {
|
||||
public @NotNull
|
||||
Biome getNoiseBiome(int biomeX, int biomeY, int biomeZ) {
|
||||
UserDefinedBiome biome = (UserDefinedBiome) grid.getBiome(biomeX << 2, biomeZ << 2);
|
||||
return Objects.requireNonNull(biomeRegistry.get(new ResourceLocation("terra", ForgeUtil.createBiomeID(pack, biome.getID()))));
|
||||
}
|
||||
|
||||
@@ -18,7 +18,8 @@ public class TerraGeneratorType extends BiomeGeneratorTypeScreens {
|
||||
}
|
||||
|
||||
@Override
|
||||
protected @NotNull ChunkGenerator generator(@NotNull Registry<Biome> biomeRegistry, @NotNull Registry<DimensionSettings> chunkGeneratorSettingsRegistry, long seed) {
|
||||
protected @NotNull
|
||||
ChunkGenerator generator(@NotNull Registry<Biome> biomeRegistry, @NotNull Registry<DimensionSettings> chunkGeneratorSettingsRegistry, long seed) {
|
||||
return new ForgeChunkGeneratorWrapper(new TerraBiomeSource(biomeRegistry, seed, pack), seed, pack);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,7 +22,8 @@ public abstract class SignTileEntityMixin {
|
||||
@Shadow
|
||||
public abstract void setMessage(int p_212365_1_, ITextComponent p_212365_2_);
|
||||
|
||||
public @NotNull String[] terra$getLines() {
|
||||
public @NotNull
|
||||
String[] terra$getLines() {
|
||||
String[] lines = new String[messages.length];
|
||||
for(int i = 0; i < messages.length; i++) {
|
||||
lines[i] = messages[i].getString();
|
||||
@@ -30,7 +31,8 @@ public abstract class SignTileEntityMixin {
|
||||
return lines;
|
||||
}
|
||||
|
||||
public @NotNull String terra$getLine(int index) throws IndexOutOfBoundsException {
|
||||
public @NotNull
|
||||
String terra$getLine(int index) throws IndexOutOfBoundsException {
|
||||
|
||||
return messages[index].getString();
|
||||
}
|
||||
|
||||
@@ -40,7 +40,8 @@ public abstract class ChunkMixin {
|
||||
return new ForgeBlock(pos, level);
|
||||
}
|
||||
|
||||
public @NotNull BlockData terra$getBlockData(int x, int y, int z) {
|
||||
public @NotNull
|
||||
BlockData terra$getBlockData(int x, int y, int z) {
|
||||
return terra$getBlock(x, y, z).getBlockData();
|
||||
}
|
||||
|
||||
|
||||
@@ -43,7 +43,8 @@ public abstract class WorldGenRegionMixin {
|
||||
return new ForgeBlock(pos, (WorldGenRegion) (Object) this);
|
||||
}
|
||||
|
||||
public @NotNull BlockData terra$getBlockData(int x, int y, int z) {
|
||||
public @NotNull
|
||||
BlockData terra$getBlockData(int x, int y, int z) {
|
||||
return terra$getBlock(x, y, z).getBlockData();
|
||||
}
|
||||
|
||||
|
||||
@@ -19,7 +19,8 @@ public abstract class ChunkPrimerMixin {
|
||||
@Shadow
|
||||
public abstract BlockState getBlockState(BlockPos pos);
|
||||
|
||||
public @NotNull BlockData terra$getBlockData(int x, int y, int z) {
|
||||
public @NotNull
|
||||
BlockData terra$getBlockData(int x, int y, int z) {
|
||||
return new ForgeBlockData(getBlockState(new BlockPos(x, y, z)));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user