We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent afe2d21 commit 368d496Copy full SHA for 368d496
src/main/java/ca/atlasengine/models/ModelManager.java
@@ -39,13 +39,19 @@ public static void updateRotation(double i) {
39
ClientPlayNetworking.send(animationIdentifier, buf);
40
}
41
42
+ private static long lastUpdate = 0;
43
public static void changeLookDirection(float headYaw, float pitch) {
44
+ if (System.currentTimeMillis() - lastUpdate < 100) {
45
+ return;
46
+ }
47
+
48
PacketByteBuf buf = PacketByteBufs.create();
49
buf.writeByte(2);
50
buf.writeFloat(headYaw);
51
buf.writeFloat(pitch);
52
53
54
+ lastUpdate = System.currentTimeMillis();
55
56
57
public static void setAnimation(UUID uuid, String animation) {
0 commit comments