当前位置: 首页>>代码示例>>Java>>正文


Java BakedQuad.getTintIndex方法代码示例

本文整理汇总了Java中net.minecraft.client.renderer.block.model.BakedQuad.getTintIndex方法的典型用法代码示例。如果您正苦于以下问题:Java BakedQuad.getTintIndex方法的具体用法?Java BakedQuad.getTintIndex怎么用?Java BakedQuad.getTintIndex使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在net.minecraft.client.renderer.block.model.BakedQuad的用法示例。


在下文中一共展示了BakedQuad.getTintIndex方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: makeQuad

import net.minecraft.client.renderer.block.model.BakedQuad; //导入方法依赖的package包/类
private BakedQuad makeQuad(BakedQuad p_makeQuad_1_, int p_makeQuad_2_, boolean p_makeQuad_3_)
{
    int[] aint = p_makeQuad_1_.getVertexData();
    int i = p_makeQuad_1_.getTintIndex();
    EnumFacing enumfacing = p_makeQuad_1_.getFace();
    TextureAtlasSprite textureatlassprite = p_makeQuad_1_.getSprite();

    if (!this.isFullSprite(p_makeQuad_1_))
    {
        return p_makeQuad_1_;
    }
    else
    {
        aint = this.transformVertexData(aint, p_makeQuad_2_, p_makeQuad_3_);
        BakedQuad bakedquad = new BakedQuad(aint, i, enumfacing, textureatlassprite);
        return bakedquad;
    }
}
 
开发者ID:SkidJava,项目名称:BaseClient,代码行数:19,代码来源:NaturalProperties.java

示例2: makeQuad

import net.minecraft.client.renderer.block.model.BakedQuad; //导入方法依赖的package包/类
private BakedQuad makeQuad(BakedQuad p_makeQuad_1_, int p_makeQuad_2_, boolean p_makeQuad_3_)
{
    int[] aint = p_makeQuad_1_.getVertexData();
    int i = p_makeQuad_1_.getTintIndex();
    EnumFacing enumfacing = p_makeQuad_1_.getFace();
    TextureAtlasSprite textureatlassprite = p_makeQuad_1_.getSprite();

    if (!this.isFullSprite(p_makeQuad_1_))
    {
        p_makeQuad_2_ = 0;
    }

    aint = this.transformVertexData(aint, p_makeQuad_2_, p_makeQuad_3_);
    BakedQuad bakedquad = new BakedQuad(aint, i, enumfacing, textureatlassprite);
    return bakedquad;
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:17,代码来源:NaturalProperties.java

示例3: makeSpriteQuad

import net.minecraft.client.renderer.block.model.BakedQuad; //导入方法依赖的package包/类
private static BakedQuad makeSpriteQuad(BakedQuad p_makeSpriteQuad_0_, TextureAtlasSprite p_makeSpriteQuad_1_)
{
    int[] aint = (int[])p_makeSpriteQuad_0_.getVertexData().clone();
    TextureAtlasSprite textureatlassprite = p_makeSpriteQuad_0_.getSprite();

    for (int i = 0; i < 4; ++i)
    {
        fixVertex(aint, i, textureatlassprite, p_makeSpriteQuad_1_);
    }

    BakedQuad bakedquad = new BakedQuad(aint, p_makeSpriteQuad_0_.getTintIndex(), p_makeSpriteQuad_0_.getFace(), p_makeSpriteQuad_1_);
    return bakedquad;
}
 
开发者ID:SkidJava,项目名称:BaseClient,代码行数:14,代码来源:ConnectedTextures.java

示例4: makeQuad

import net.minecraft.client.renderer.block.model.BakedQuad; //导入方法依赖的package包/类
private BakedQuad makeQuad(BakedQuad p_makeQuad_1_, int p_makeQuad_2_, boolean p_makeQuad_3_)
{
    int[] aint = p_makeQuad_1_.getVertexData();
    int i = p_makeQuad_1_.getTintIndex();
    EnumFacing enumfacing = p_makeQuad_1_.getFace();
    TextureAtlasSprite textureatlassprite = p_makeQuad_1_.getSprite();
    aint = this.fixVertexData(aint, p_makeQuad_2_, p_makeQuad_3_);
    BakedQuad bakedquad = new BakedQuad(aint, i, enumfacing, textureatlassprite);
    return bakedquad;
}
 
开发者ID:SkidJava,项目名称:BaseClient,代码行数:11,代码来源:NaturalProperties.java

示例5: makeSpriteQuadCompact

import net.minecraft.client.renderer.block.model.BakedQuad; //导入方法依赖的package包/类
private static BakedQuad makeSpriteQuadCompact(BakedQuad p_makeSpriteQuadCompact_0_, TextureAtlasSprite p_makeSpriteQuadCompact_1_, int p_makeSpriteQuadCompact_2_, int p_makeSpriteQuadCompact_3_, int p_makeSpriteQuadCompact_4_, int p_makeSpriteQuadCompact_5_, int p_makeSpriteQuadCompact_6_)
{
    int[] aint = (int[])p_makeSpriteQuadCompact_0_.getVertexData().clone();
    TextureAtlasSprite textureatlassprite = p_makeSpriteQuadCompact_0_.getSprite();

    for (int i = 0; i < 4; ++i)
    {
        fixVertexCompact(aint, i, textureatlassprite, p_makeSpriteQuadCompact_1_, p_makeSpriteQuadCompact_2_, p_makeSpriteQuadCompact_3_, p_makeSpriteQuadCompact_4_, p_makeSpriteQuadCompact_5_, p_makeSpriteQuadCompact_6_);
    }

    BakedQuad bakedquad = new BakedQuad(aint, p_makeSpriteQuadCompact_0_.getTintIndex(), p_makeSpriteQuadCompact_0_.getFace(), p_makeSpriteQuadCompact_1_);
    return bakedquad;
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:14,代码来源:ConnectedTexturesCompact.java

示例6: duplicateQuad

import net.minecraft.client.renderer.block.model.BakedQuad; //导入方法依赖的package包/类
public static BakedQuad duplicateQuad(BakedQuad p_duplicateQuad_0_)
{
    BakedQuad bakedquad = new BakedQuad((int[])p_duplicateQuad_0_.getVertexData().clone(), p_duplicateQuad_0_.getTintIndex(), p_duplicateQuad_0_.getFace(), p_duplicateQuad_0_.getSprite());
    return bakedquad;
}
 
开发者ID:SkidJava,项目名称:BaseClient,代码行数:6,代码来源:ModelUtils.java

示例7: getModelDoubleFace

import net.minecraft.client.renderer.block.model.BakedQuad; //导入方法依赖的package包/类
private static IBakedModel getModelDoubleFace(IBakedModel p_getModelDoubleFace_0_)
{
    if (p_getModelDoubleFace_0_ == null)
    {
        return null;
    }
    else if (p_getModelDoubleFace_0_.getGeneralQuads().size() > 0)
    {
        Config.warn("SmartLeaves: Model is not cube, general quads: " + p_getModelDoubleFace_0_.getGeneralQuads().size() + ", model: " + p_getModelDoubleFace_0_);
        return p_getModelDoubleFace_0_;
    }
    else
    {
        EnumFacing[] aenumfacing = EnumFacing.VALUES;

        for (int i = 0; i < aenumfacing.length; ++i)
        {
            EnumFacing enumfacing = aenumfacing[i];
            List<BakedQuad> list = p_getModelDoubleFace_0_.getFaceQuads(enumfacing);

            if (list.size() != 1)
            {
                Config.warn("SmartLeaves: Model is not cube, side: " + enumfacing + ", quads: " + list.size() + ", model: " + p_getModelDoubleFace_0_);
                return p_getModelDoubleFace_0_;
            }
        }

        IBakedModel ibakedmodel = ModelUtils.duplicateModel(p_getModelDoubleFace_0_);
        List[] alist = new List[aenumfacing.length];

        for (int k = 0; k < aenumfacing.length; ++k)
        {
            EnumFacing enumfacing1 = aenumfacing[k];
            List<BakedQuad> list1 = ibakedmodel.getFaceQuads(enumfacing1);
            BakedQuad bakedquad = (BakedQuad)list1.get(0);
            BakedQuad bakedquad1 = new BakedQuad((int[])bakedquad.getVertexData().clone(), bakedquad.getTintIndex(), bakedquad.getFace(), bakedquad.getSprite());
            int[] aint = bakedquad1.getVertexData();
            int[] aint1 = (int[])aint.clone();
            int j = aint.length / 4;
            System.arraycopy(aint, 0 * j, aint1, 3 * j, j);
            System.arraycopy(aint, 1 * j, aint1, 2 * j, j);
            System.arraycopy(aint, 2 * j, aint1, 1 * j, j);
            System.arraycopy(aint, 3 * j, aint1, 0 * j, j);
            System.arraycopy(aint1, 0, aint, 0, aint1.length);
            list1.add(bakedquad1);
        }

        return ibakedmodel;
    }
}
 
开发者ID:SkidJava,项目名称:BaseClient,代码行数:51,代码来源:SmartLeaves.java

示例8: getModelDoubleFace

import net.minecraft.client.renderer.block.model.BakedQuad; //导入方法依赖的package包/类
private static IBakedModel getModelDoubleFace(IBakedModel p_getModelDoubleFace_0_)
{
    if (p_getModelDoubleFace_0_ == null)
    {
        return null;
    }
    else if (p_getModelDoubleFace_0_.getQuads((IBlockState)null, (EnumFacing)null, 0L).size() > 0)
    {
        Config.warn("SmartLeaves: Model is not cube, general quads: " + p_getModelDoubleFace_0_.getQuads((IBlockState)null, (EnumFacing)null, 0L).size() + ", model: " + p_getModelDoubleFace_0_);
        return p_getModelDoubleFace_0_;
    }
    else
    {
        EnumFacing[] aenumfacing = EnumFacing.VALUES;

        for (int i = 0; i < aenumfacing.length; ++i)
        {
            EnumFacing enumfacing = aenumfacing[i];
            List<BakedQuad> list = p_getModelDoubleFace_0_.getQuads((IBlockState)null, enumfacing, 0L);

            if (list.size() != 1)
            {
                Config.warn("SmartLeaves: Model is not cube, side: " + enumfacing + ", quads: " + list.size() + ", model: " + p_getModelDoubleFace_0_);
                return p_getModelDoubleFace_0_;
            }
        }

        IBakedModel ibakedmodel = ModelUtils.duplicateModel(p_getModelDoubleFace_0_);
        List[] alist = new List[aenumfacing.length];

        for (int k = 0; k < aenumfacing.length; ++k)
        {
            EnumFacing enumfacing1 = aenumfacing[k];
            List<BakedQuad> list1 = ibakedmodel.getQuads((IBlockState)null, enumfacing1, 0L);
            BakedQuad bakedquad = (BakedQuad)list1.get(0);
            BakedQuad bakedquad1 = new BakedQuad((int[])bakedquad.getVertexData().clone(), bakedquad.getTintIndex(), bakedquad.getFace(), bakedquad.getSprite());
            int[] aint = bakedquad1.getVertexData();
            int[] aint1 = (int[])aint.clone();
            int j = aint.length / 4;
            System.arraycopy(aint, 0 * j, aint1, 3 * j, j);
            System.arraycopy(aint, 1 * j, aint1, 2 * j, j);
            System.arraycopy(aint, 2 * j, aint1, 1 * j, j);
            System.arraycopy(aint, 3 * j, aint1, 0 * j, j);
            System.arraycopy(aint1, 0, aint, 0, aint1.length);
            list1.add(bakedquad1);
        }

        return ibakedmodel;
    }
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:51,代码来源:SmartLeaves.java


注:本文中的net.minecraft.client.renderer.block.model.BakedQuad.getTintIndex方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。