mirror of
https://github.com/MineLittlePony/MineLittlePony.git
synced 2025-03-23 04:07:11 +01:00
Fix #165 and backport other seapony model fixes
This commit is contained in:
parent
ece8e81c0d
commit
5f0594c44b
3 changed files with 31 additions and 11 deletions
|
@ -40,7 +40,7 @@ public class SeaponyTail implements IModelPart {
|
|||
@Override
|
||||
public void init(float yOffset, float stretch) {
|
||||
tailBase.rotate(TAIL_ROTX, 0, 0)
|
||||
.offset(0, -4, -2)
|
||||
.offset(0, -1, 0)
|
||||
.around(-2, 10, 8)
|
||||
.box( 0, 0, 0, 4, 6, 4, stretch)
|
||||
.flip();
|
||||
|
|
|
@ -40,6 +40,7 @@ public class ModelSeapony extends ModelUnicorn {
|
|||
|
||||
// Seaponies can't sneak, silly
|
||||
isSneak = false;
|
||||
isCrouching = false;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -106,6 +107,15 @@ public class ModelSeapony extends ModelUnicorn {
|
|||
if (!isSleeping()) {
|
||||
centerFin.rotateAngleZ = flapMotion;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void rotateLegs(float move, float swing, float ticks, Entity entity) {
|
||||
super.rotateLegs(move, swing, ticks, entity);
|
||||
bipedLeftArm.rotateAngleX -= 1.4F;
|
||||
bipedLeftArm.rotateAngleY -= 0.3F;
|
||||
bipedRightArm.rotateAngleX -= 1.4F;
|
||||
bipedRightArm.rotateAngleY += 0.3F;
|
||||
|
||||
if (!entity.isInWater()) {
|
||||
bipedLeftArm.rotateAngleX -= 0.5F;
|
||||
|
@ -118,15 +128,6 @@ public class ModelSeapony extends ModelUnicorn {
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void rotateLegs(float move, float swing, float ticks, Entity entity) {
|
||||
super.rotateLegs(move, swing, ticks, entity);
|
||||
bipedLeftArm.rotateAngleX -= 1.4F;
|
||||
bipedLeftArm.rotateAngleY -= 0.3F;
|
||||
bipedRightArm.rotateAngleX -= 1.4F;
|
||||
bipedRightArm.rotateAngleY += 0.3F;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void rotateLegsSwimming(float move, float swing, float ticks, Entity entity) {
|
||||
super.rotateLegsOnGround(move, swing, ticks, entity);
|
||||
|
@ -197,6 +198,26 @@ public class ModelSeapony extends ModelUnicorn {
|
|||
|
||||
// Seaponies can't sneak, silly
|
||||
isSneak = false;
|
||||
isCrouching = false;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void rotateLegs(float move, float swing, float ticks, Entity entity) {
|
||||
super.rotateLegs(move, swing, ticks, entity);
|
||||
bipedLeftArm.rotateAngleX -= 1.4F;
|
||||
bipedLeftArm.rotateAngleY -= 0.3F;
|
||||
bipedRightArm.rotateAngleX -= 1.4F;
|
||||
bipedRightArm.rotateAngleY += 0.3F;
|
||||
|
||||
if (!entity.isInWater()) {
|
||||
bipedLeftArm.rotateAngleX -= 0.5F;
|
||||
bipedRightArm.rotateAngleX -= 0.5F;
|
||||
}
|
||||
|
||||
if (!entity.isInWater() || entity.onGround) {
|
||||
bipedLeftArm.rotateAngleY -= 0.5F;
|
||||
bipedRightArm.rotateAngleY += 0.5F;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -78,7 +78,6 @@ public class RenderPony<T extends EntityLivingBase> {
|
|||
// negate vanilla translations so the rider begins at the ridees feet.
|
||||
GlStateManager.translate(0, -ridingEntity.height, 0);
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
IPony riderPony = renderer.getEntityPony((EntityLivingBase)ridingEntity);
|
||||
|
||||
renderer.translateRider((EntityLivingBase)ridingEntity, riderPony, entity, pony, ticks);
|
||||
|
|
Loading…
Add table
Reference in a new issue