Upload files to "src/openonyx/protocol/internal/internal/internal"

This commit is contained in:
winterflyt committed 2026-11-30 06:07:03 +02:00
1 parent aa1b27bc7b
commit 04c2945c63
3 files changed
+50

No files matched your search

@@ -0,0 +1,13 @@
package openonyx.protocol.internal.internal.internal;
import openonyx.history.ModeOption;
import openonyx.protocol.group_m.Angles;
import openonyx.protocol.internal.internal.RotationSmoother;
public abstract class SmoothingMode extends ModeOption implements RotationSmoother {
protected SmoothingMode(String string) {
super(string);
}
public abstract int L(Angles angles, Angles angles1);
}
@@ -0,0 +1,33 @@
package openonyx.protocol.internal.internal.internal;
import openonyx.protocol.RotationRequest;
import openonyx.protocol.group_m.Angles;
public abstract class TurnSpeedSmoothing extends SmoothingMode {
@Override
public Angles L(RotationRequest rotationRequest, Angles angles, Angles angles1) {
Vec2 vec2 = this.L(rotationRequest, angles, angles1);
return angles.L(angles1, vec2.x(), vec2.y());
}
@Override
public int L(Angles angles, Angles angles1) {
angles = angles;
int i = -1;
do {
Vec2 vec2 = this.L(null, angles, angles1);
float f = vec2.x();
i++;
angles = angles.L(angles1, f, vec2.y());
} while (!angles.L(angles1) && i < 80);
return i;
}
protected TurnSpeedSmoothing(String string) {
super(string);
}
public abstract Vec2 L(RotationRequest rotationRequest, Angles angles, Angles angles1);
}
@@ -0,0 +1,4 @@
package openonyx.protocol.internal.internal.internal;
public record Vec2(float x, float y) {
}