mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2026-02-16 10:30:42 +00:00
fix typo
This commit is contained in:
@@ -38,7 +38,8 @@ public class TerraWorld {
|
||||
String partName = template.getGrids().get(i);
|
||||
try {
|
||||
BiomeGridBuilder g = config.getBiomeGrid(partName);
|
||||
definedGrids[i] = g.build(w, worldConfig);
|
||||
BiomeGrid b = g.build(w, worldConfig);
|
||||
definedGrids[i] = b;
|
||||
} catch(NullPointerException e) {
|
||||
safe = false;
|
||||
Debug.stack(e);
|
||||
@@ -53,7 +54,8 @@ public class TerraWorld {
|
||||
if(template.isErode()) {
|
||||
try {
|
||||
BiomeGridBuilder g = Objects.requireNonNull(config.getBiomeGrid(erosionName));
|
||||
erosion = g.build(w, worldConfig);
|
||||
BiomeGrid b = g.build(w, worldConfig);
|
||||
erosion = b;
|
||||
} catch(NullPointerException e) {
|
||||
safe = false;
|
||||
Debug.stack(e);
|
||||
|
||||
@@ -5,6 +5,7 @@ import com.dfsek.tectonic.exception.ConfigException;
|
||||
import com.dfsek.tectonic.exception.LoadException;
|
||||
import com.dfsek.tectonic.loading.ConfigLoader;
|
||||
import com.dfsek.tectonic.loading.TypeLoader;
|
||||
import com.dfsek.terra.Debug;
|
||||
import com.dfsek.terra.generation.config.NoiseBuilder;
|
||||
import org.polydev.gaea.math.FastNoiseLite;
|
||||
|
||||
@@ -28,10 +29,14 @@ public class NoiseBuilderLoader implements TypeLoader<NoiseBuilder> {
|
||||
public NoiseBuilder load(Type type, Object o, ConfigLoader configLoader) throws LoadException {
|
||||
NoiseBuilder builder = new NoiseBuilder();
|
||||
try {
|
||||
Debug.info(o + "");
|
||||
LOADER.load(builder, new Configuration((Map<String, Object>) o));
|
||||
} catch(ConfigException e) {
|
||||
throw new LoadException("Could not load noise", e);
|
||||
}
|
||||
Debug.info("FREQ: " + builder.getFrequency());
|
||||
Debug.info("FRAC: " + builder.getFractalType());
|
||||
Debug.info("OCT:" + builder.getOctaves());
|
||||
return builder;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@ public class NoiseBuilder implements ConfigTemplate {
|
||||
@Default
|
||||
private FastNoiseLite.NoiseType type = FastNoiseLite.NoiseType.OpenSimplex2;
|
||||
|
||||
@Value("octaves")
|
||||
@Value("fractal.octaves")
|
||||
@Default
|
||||
private int octaves = 1;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user