當前位置: 首頁>>代碼示例>>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;未經允許,請勿轉載。