mirror of
https://github.com/MineLittlePony/MineLittlePony.git
synced 2024-11-29 07:27:59 +01:00
Delegating this to original developers. Texture offsets are final, so at least half of the wings code has to be adjusted to get actual metadata about bags and stuff.
This commit is contained in:
parent
b6242902f6
commit
951cd84f20
5 changed files with 9 additions and 14 deletions
|
@ -1,3 +1,3 @@
|
||||||
#Build Number for ANT. Do not edit!
|
#Build Number for ANT. Do not edit!
|
||||||
#Tue Apr 10 14:03:42 CAT 2018
|
#Mon Jun 04 04:49:51 MSK 2018
|
||||||
build.number=497
|
build.number=498
|
||||||
|
|
|
@ -51,13 +51,11 @@ public class ModelWing {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void render(boolean hasBags, boolean extend, float scale) {
|
public void render(boolean extend, float scale) {
|
||||||
extended.rotationPointX = (mirror ? -1 : 1) * LEFT_WING_EXT_RP_X;
|
extended.rotationPointX = (mirror ? -1 : 1) * LEFT_WING_EXT_RP_X;
|
||||||
extended.rotationPointY = LEFT_WING_EXT_RP_Y + (hasBags ? -1f : 0f);
|
extended.rotationPointY = LEFT_WING_EXT_RP_Y;
|
||||||
extended.rotationPointZ = LEFT_WING_EXT_RP_Z + (hasBags ? 1f : 0f);
|
|
||||||
extended.rotateAngleY = 3;
|
|
||||||
|
|
||||||
folded.offset((hasBags ? (mirror ? -0.5f : 0.5f) : 0f), (hasBags ? -0.5f : 0f), (hasBags ? -1.5f : 0f));
|
extended.rotateAngleY = 3;
|
||||||
if (extend) {
|
if (extend) {
|
||||||
extended.render(scale);
|
extended.render(scale);
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -68,11 +68,10 @@ public class PegasusWings implements IModelPart {
|
||||||
@Override
|
@Override
|
||||||
public void render(float scale) {
|
public void render(float scale) {
|
||||||
AbstractPonyModel model = ((AbstractPonyModel) pegasus);
|
AbstractPonyModel model = ((AbstractPonyModel) pegasus);
|
||||||
boolean hasBags = model.metadata.hasBags();
|
if (!model.metadata.hasBags() || model.textureHeight == 64) {
|
||||||
if (!hasBags || model.textureHeight == 64) {
|
|
||||||
boolean standing = pegasus.wingsAreOpen();
|
boolean standing = pegasus.wingsAreOpen();
|
||||||
leftWing.render(hasBags, standing, scale);
|
leftWing.render(standing, scale);
|
||||||
rightWing.render(hasBags, standing, scale);
|
rightWing.render(standing, scale);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,8 +3,6 @@ package com.minelittlepony.model.components;
|
||||||
import com.minelittlepony.model.AbstractPonyModel;
|
import com.minelittlepony.model.AbstractPonyModel;
|
||||||
import com.minelittlepony.model.capabilities.IModelPart;
|
import com.minelittlepony.model.capabilities.IModelPart;
|
||||||
import com.minelittlepony.render.plane.PlaneRenderer;
|
import com.minelittlepony.render.plane.PlaneRenderer;
|
||||||
import net.minecraft.entity.Entity;
|
|
||||||
import net.minecraft.util.math.MathHelper;
|
|
||||||
|
|
||||||
import static com.minelittlepony.model.PonyModelConstants.*;
|
import static com.minelittlepony.model.PonyModelConstants.*;
|
||||||
|
|
||||||
|
|
|
@ -37,7 +37,7 @@ public interface IPonyData extends IMetadataSection {
|
||||||
boolean hasMagic();
|
boolean hasMagic();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns true if and only if this metadata represents a pony that has bags.
|
* Returns true if and only if this metadata represents a pony that has accessories.
|
||||||
*/
|
*/
|
||||||
boolean hasAccessory();
|
boolean hasAccessory();
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue