From 3ab501e3f332f12ebef4fd1a58aad3c6b5aaf8b0 Mon Sep 17 00:00:00 2001 From: Sollace Date: Fri, 2 Jun 2023 21:04:49 +0100 Subject: [PATCH] Fixed horn positioning --- .../unicopia/client/render/HornFeatureRenderer.java | 4 ++-- .../unicopia/client/render/PlayerPoser.java | 8 +++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/HornFeatureRenderer.java b/src/main/java/com/minelittlepony/unicopia/client/render/HornFeatureRenderer.java index 73835bd1..4e1214ec 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/HornFeatureRenderer.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/HornFeatureRenderer.java @@ -81,10 +81,10 @@ public class HornFeatureRenderer implements AccessoryFea .cuboid(-4, -8, -4, 8, 8, 8, dilation), ModelTransform.NONE); head.addChild("horn", ModelPartBuilder.create() .uv(0, 3) - .cuboid(-0.5F, -11, -3.5F, 1, 4, 1, dilation), ModelTransform.rotation(29 * MathHelper.RADIANS_PER_DEGREE, 0, 0)); + .cuboid(-0.5F, -12, -0.5F, 1, 4, 1, dilation), ModelTransform.rotation(29 * MathHelper.RADIANS_PER_DEGREE, 0, 0)); head.addChild("magic", ModelPartBuilder.create() .uv(0, 3) - .cuboid(-0.5F, -11, -3.5F, 1, 4, 1, dilation.add(0.5F)), ModelTransform.rotation(29 * MathHelper.RADIANS_PER_DEGREE, 0, 0)); + .cuboid(-0.5F, -12, -0.5F, 1, 4, 1, dilation.add(0.5F)), ModelTransform.rotation(29 * MathHelper.RADIANS_PER_DEGREE, 0, 0)); return TexturedModelData.of(data, 64, 64); } diff --git a/src/main/java/com/minelittlepony/unicopia/client/render/PlayerPoser.java b/src/main/java/com/minelittlepony/unicopia/client/render/PlayerPoser.java index d277a690..ace33461 100644 --- a/src/main/java/com/minelittlepony/unicopia/client/render/PlayerPoser.java +++ b/src/main/java/com/minelittlepony/unicopia/client/render/PlayerPoser.java @@ -59,6 +59,11 @@ public class PlayerPoser { } switch (animation) { + case NECK_SNAP: { + head.yaw += 3F; + head.pitch *= -1; + break; + } case WOLOLO: { float roll = MathHelper.sin(player.age / 10F); float yaw = MathHelper.cos(player.age / 10F); @@ -237,7 +242,8 @@ public class PlayerPoser { KICK(USounds.ENTITY_PLAYER_KICK, 5), STOMP(5), WIGGLE_NOSE(6), - SPREAD_WINGS(6); + SPREAD_WINGS(6), + NECK_SNAP(50); private final int duration; private final Optional sound;