reformat all code

This commit is contained in:
dfsek
2022-03-30 14:43:50 -07:00
parent d79c37fc49
commit 4a3c22a8d6
201 changed files with 925 additions and 1040 deletions
@@ -7,13 +7,13 @@
package com.dfsek.terra.addon.terrascript.check;
import com.dfsek.terra.addons.terrascript.parser.lang.Scope;
import net.jafama.FastMath;
import com.dfsek.terra.addons.chunkgenerator.generation.NoiseChunkGenerator3D;
import com.dfsek.terra.addons.chunkgenerator.generation.math.samplers.SamplerProvider;
import com.dfsek.terra.addons.terrascript.parser.lang.ImplementationArguments;
import com.dfsek.terra.addons.terrascript.parser.lang.Returnable;
import com.dfsek.terra.addons.terrascript.parser.lang.Scope;
import com.dfsek.terra.addons.terrascript.parser.lang.functions.Function;
import com.dfsek.terra.addons.terrascript.script.TerraImplementationArguments;
import com.dfsek.terra.addons.terrascript.tokenizer.Position;
@@ -44,13 +44,13 @@ public class CheckFunction implements Function<String> {
Vector2 xz = Vector2.of(x.apply(implementationArguments, scope).doubleValue(),
z.apply(implementationArguments, scope).doubleValue());
z.apply(implementationArguments, scope).doubleValue());
RotationUtil.rotateVector(xz, arguments.getRotation());
Vector3 location = arguments.getOrigin().toVector3Mutable().add(
Vector3.of(FastMath.roundToInt(xz.getX()), y.apply(implementationArguments, scope).doubleValue(),
FastMath.roundToInt(xz.getZ()))).immutable();
FastMath.roundToInt(xz.getZ()))).immutable();
return apply(location, arguments.getWorld());
}
@@ -23,7 +23,8 @@ public class TerraScriptCheckFunctionAddon implements AddonInitializer {
.register(addon, ConfigPackPreLoadEvent.class)
.priority(1)
.then(event -> {
event.getPack().getOrCreateRegistry(FunctionBuilder.class).register(addon.key("check"), new CheckFunctionBuilder(platform));
event.getPack().getOrCreateRegistry(FunctionBuilder.class).register(addon.key("check"),
new CheckFunctionBuilder(platform));
})
.failThrough();
}