mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-21 04:32:15 +00:00
Fix items in ground being too small, we were applying perspectives twice.
Restore forge patch and fix a tiny mistake in it.
This commit is contained in:
1 parent
eaac0c17a4
commit
599a754b60
4 files changed
+14
-45
No files matched your search
@@ -811,11 +811,9 @@ public class ForgeHooksClient
|
||||
@SuppressWarnings("deprecation")
|
||||
public static IBakedModel handlePerspective(IBakedModel model, ItemCameraTransforms.TransformType type, MatrixStack stack)
|
||||
{
|
||||
if (!model.getItemCameraTransforms().getTransform(type).equals(ItemTransformVec3f.DEFAULT))
|
||||
{
|
||||
// Push to the matrix to make it not empty and indicate that we want to transform things
|
||||
stack.func_227860_a_();
|
||||
model.getItemCameraTransforms().getTransform(type).func_228830_a_(false, stack);
|
||||
TransformationMatrix tr = TransformationHelper.toTransformation(model.getItemCameraTransforms().getTransform(type));
|
||||
if(!tr.isIdentity()) {
|
||||
tr.push(stack);
|
||||
}
|
||||
return model;
|
||||
}
|
||||
|
||||
@@ -42,12 +42,17 @@ public interface IForgeTransformationMatrix
|
||||
default void push(MatrixStack stack)
|
||||
{
|
||||
stack.func_227860_a_();
|
||||
stack.func_227863_a_(getTransformaion().func_227989_d_());
|
||||
|
||||
Vector3f trans = getTransformaion().getTranslation();
|
||||
stack.func_227861_a_(trans.getX(), trans.getY(), trans.getZ());
|
||||
stack.func_227863_a_(getTransformaion().getRightRot());
|
||||
|
||||
stack.func_227863_a_(getTransformaion().func_227989_d_());
|
||||
|
||||
Vector3f scale = getTransformaion().getScale();
|
||||
stack.func_227861_a_(scale.getX(), scale.getY(), scale.getZ());
|
||||
stack.func_227862_a_(scale.getX(), scale.getY(), scale.getZ());
|
||||
|
||||
stack.func_227863_a_(getTransformaion().getRightRot());
|
||||
|
||||
}
|
||||
|
||||
default TransformationMatrix compose(TransformationMatrix other)
|
||||
|
||||
Reference in new issue
Block a user