Structure#generateDirect -> #generate

This commit is contained in:
dfsek 2021-07-22 18:44:51 -07:00
parent 9d687208c9
commit 169ed64568
4 changed files with 4 additions and 4 deletions

View File

@ -81,7 +81,7 @@ public class StructureLoadCommand implements CommandTemplate {
if(this.chunk) { if(this.chunk) {
script.generate(player.position(), player.world(), player.world().getChunkAt(player.position()), random, r); script.generate(player.position(), player.world(), player.world().getChunkAt(player.position()), random, r);
} else { } else {
script.generateDirect(player.position(), player.world(), random, r); script.generate(player.position(), player.world(), random, r);
} }
long l = System.nanoTime() - t; long l = System.nanoTime() - t;

View File

@ -35,7 +35,7 @@ public class FeatureGenerationStage implements GenerationStage {
.getSuitableCoordinates(column) .getSuitableCoordinates(column)
.forEach(y -> .forEach(y ->
feature.getStructure(world, tx, y, tz) feature.getStructure(world, tx, y, tz)
.generateDirect(new Vector3(tx, y, tz), world, PopulationUtil.getRandom(chunk), Rotation.NONE) .generate(new Vector3(tx, y, tz), world, PopulationUtil.getRandom(chunk), Rotation.NONE)
); );
} }
}); });

View File

@ -152,7 +152,7 @@ public class StructureScript implements Structure {
@Override @Override
@SuppressWarnings("try") @SuppressWarnings("try")
public boolean generateDirect(Vector3 location, World world, Random random, Rotation rotation) { public boolean generate(Vector3 location, World world, Random random, Rotation rotation) {
try(ProfileFrame ignore = main.getProfiler().profile("terrascript_direct:" + id)) { try(ProfileFrame ignore = main.getProfiler().profile("terrascript_direct:" + id)) {
DirectBuffer buffer = new DirectBuffer(location, world); DirectBuffer buffer = new DirectBuffer(location, world);
return applyBlock(new TerraImplementationArguments(buffer, rotation, random, world, 0)); return applyBlock(new TerraImplementationArguments(buffer, rotation, random, world, 0));

View File

@ -14,5 +14,5 @@ public interface Structure extends StringIdentifiable {
boolean generate(Buffer buffer, World world, Random random, Rotation rotation, int recursions); boolean generate(Buffer buffer, World world, Random random, Rotation rotation, int recursions);
boolean generateDirect(Vector3 location, World world, Random random, Rotation rotation); boolean generate(Vector3 location, World world, Random random, Rotation rotation);
} }