ShapeMeshGenerator.java 文件源码

java
阅读 26 收藏 0 点赞 0 评论 0

项目:Hard-Science 作者:
/**
 * Find appropriate transformation assuming base model is oriented to Y orthogonalAxis, positive.
 * This is different than the Minecraft/Forge default because I brain that way.<br><br>
 * 
 * @see #getMatrixForAxisAndRotation(net.minecraft.util.EnumFacing.Axis, boolean, Rotation) for
 * more explanation.
 */
protected static Matrix4f getMatrix4f(ModelState modelState)
{
    if(modelState.hasAxis())
    {
        if(modelState.hasAxisRotation())
        {
            return getMatrixForAxisAndRotation(modelState.getAxis(), modelState.isAxisInverted(), modelState.getAxisRotation());
        }
        else
        {
            return getMatrixForAxis(modelState.getAxis(), modelState.isAxisInverted());
        }
    }
    else if(modelState.hasAxisRotation())
    {
        return getMatrixForRotation(modelState.getAxisRotation());
    }
    else
    {
        return ForgeHooksClient.getMatrix(ModelRotation.X0_Y0);
    }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号