diff --git a/src/main/java/com/minelittlepony/client/model/PonySkullModel.java b/src/main/java/com/minelittlepony/client/model/PonySkullModel.java deleted file mode 100644 index d66fa538..00000000 --- a/src/main/java/com/minelittlepony/client/model/PonySkullModel.java +++ /dev/null @@ -1,73 +0,0 @@ -package com.minelittlepony.client.model; - -import com.minelittlepony.api.config.PonyConfig; -import com.minelittlepony.api.model.ICapitated; -import com.minelittlepony.api.pony.IPonyData; -import com.minelittlepony.api.pony.meta.Race; -import com.minelittlepony.client.model.part.PonyEars; -import com.minelittlepony.client.model.part.PonySnout; -import com.minelittlepony.client.model.part.UnicornHorn; -import com.minelittlepony.client.pony.PonyData; -import com.minelittlepony.mson.api.ModelContext; -import com.minelittlepony.mson.api.MsonModel; - -import net.minecraft.client.model.ModelPart; -import net.minecraft.client.render.VertexConsumer; -import net.minecraft.client.render.entity.model.SkullEntityModel; -import net.minecraft.client.util.math.MatrixStack; - -public class PonySkullModel extends SkullEntityModel implements MsonModel, ICapitated { - - private PonySnout snout; - - private UnicornHorn horn; - - private PonyEars ears; - - private ModelPart hair; - - public IPonyData metadata = PonyData.NULL; - - public PonySkullModel(ModelPart tree) { - super(tree); - } - - @Override - public void init(ModelContext context) { - hair = context.findByName("hair"); - snout = context.findByName("snout"); - horn = context.findByName("horn"); - ears = context.findByName("ears"); - } - - @Override - public ModelPart getHead() { - return head; - } - - @Override - public void setHeadRotation(float animationProgress, float yaw, float pitch) { - super.setHeadRotation(animationProgress, yaw, pitch); - hair.yaw = head.yaw; - hair.pitch = head.pitch; - } - - @Override - public void render(MatrixStack stack, VertexConsumer vertices, int overlayUv, int lightUv, float red, float green, float blue, float alpha) { - - Race race = PonyConfig.getEffectiveRace(metadata.getRace()); - - snout.setVisible(!race.isHuman()); - ears.setVisible(!race.isHuman()); - - snout.setGender(metadata.getGender()); - - hair.render(stack, vertices, overlayUv, lightUv, red, green, blue, alpha); - head.render(stack, vertices, overlayUv, lightUv, red, green, blue, alpha); - - if (race.hasHorn()) { - getHead().rotate(stack); - horn.renderPart(stack, vertices, overlayUv, lightUv, red, green, blue, alpha, null); - } - } -}