本文整理汇总了Java中net.minecraft.world.ColorizerFoliage.getFoliageColorPine方法的典型用法代码示例。如果您正苦于以下问题:Java ColorizerFoliage.getFoliageColorPine方法的具体用法?Java ColorizerFoliage.getFoliageColorPine怎么用?Java ColorizerFoliage.getFoliageColorPine使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类net.minecraft.world.ColorizerFoliage
的用法示例。
在下文中一共展示了ColorizerFoliage.getFoliageColorPine方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: colorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
public int colorMultiplier(IBlockAccess worldIn, BlockPos pos, int renderPass)
{
IBlockState iblockstate = worldIn.getBlockState(pos);
if (iblockstate.getBlock() == this)
{
BlockPlanks.EnumType blockplanks$enumtype = (BlockPlanks.EnumType)iblockstate.getValue(VARIANT);
if (blockplanks$enumtype == BlockPlanks.EnumType.SPRUCE)
{
return ColorizerFoliage.getFoliageColorPine();
}
if (blockplanks$enumtype == BlockPlanks.EnumType.BIRCH)
{
return ColorizerFoliage.getFoliageColorBirch();
}
}
return super.colorMultiplier(worldIn, pos, renderPass);
}
示例2: getRenderColor
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
public int getRenderColor(IBlockState state)
{
if (state.getBlock() != this)
{
return super.getRenderColor(state);
}
else
{
BlockPlanks.EnumType blockplanks$enumtype = (BlockPlanks.EnumType)state.getValue(VARIANT);
return blockplanks$enumtype == BlockPlanks.EnumType.SPRUCE ? ColorizerFoliage.getFoliageColorPine() : (blockplanks$enumtype == BlockPlanks.EnumType.BIRCH ? ColorizerFoliage.getFoliageColorBirch() : super.getRenderColor(state));
}
}
示例3: getRenderColor
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@SideOnly(Side.CLIENT)
public int getRenderColor(IBlockState state)
{
switch (variant)
{
case BIRCH:
return ColorizerFoliage.getFoliageColorBirch();
case SPRUCE:
return ColorizerFoliage.getFoliageColorPine();
}
return ColorizerFoliage.getFoliageColorBasic();
}
示例4: colorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@SideOnly(Side.CLIENT)
/**
* Returns a integer with hex for 0xrrggbb with this color multiplied against the blocks color. Note only called
* when first determining what to render.
*/
public int colorMultiplier(IBlockAccess world, int x, int y, int z)
{
int l = world.getBlockMetadata(x, y, z);
if ((l & 3) == 1)
{
return ColorizerFoliage.getFoliageColorPine();
}
else if ((l & 3) == 2)
{
return ColorizerFoliage.getFoliageColorBirch();
}
else
{
int i1 = 0;
int j1 = 0;
int k1 = 0;
for (int l1 = -1; l1 <= 1; ++l1)
{
for (int i2 = -1; i2 <= 1; ++i2)
{
int j2 = world.getBiomeGenForCoords(x + i2, z + l1).getBiomeFoliageColor();
i1 += (j2 & 16711680) >> 16;
j1 += (j2 & 65280) >> 8;
k1 += j2 & 255;
}
}
return (i1 / 9 & 255) << 16 | (j1 / 9 & 255) << 8 | k1 / 9 & 255;
}
}
示例5: colorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
public int colorMultiplier(IBlockAccess par1IBlockAccess, int par2, int par3, int par4)
{
int l = par1IBlockAccess.getBlockMetadata(par2, par3, par4);
if ((l & 3) == 1)
{
return ColorizerFoliage.getFoliageColorPine();
}
else if ((l & 3) == 2)
{
return ColorizerFoliage.getFoliageColorBirch();
}
else
{
int i1 = 0;
int j1 = 0;
int k1 = 0;
for (int l1 = -1; l1 <= 1; ++l1)
{
for (int i2 = -1; i2 <= 1; ++i2)
{
int j2 = par1IBlockAccess.getBiomeGenForCoords(par2 + i2, par4 + l1).getBiomeFoliageColor();
i1 += (j2 & 16711680) >> 16;
j1 += (j2 & 65280) >> 8;
k1 += j2 & 255;
}
}
return (i1 / 9 & 255) << 16 | (j1 / 9 & 255) << 8 | k1 / 9 & 255;
}
}
示例6: getRenderColor
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@Override
@SideOnly(Side.CLIENT)
/**
* Returns the color this block should be rendered. Used by leaves.
*/
public int getRenderColor(int par1) {
return (par1 & 3) == 1 ? ColorizerFoliage.getFoliageColorPine() : ((par1 & 3) == 2 ? ColorizerFoliage.getFoliageColorBirch() : ColorizerFoliage.getFoliageColorBasic());
}
示例7: colorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@Override
@SideOnly(Side.CLIENT)
/**
* Returns a integer with hex for 0xrrggbb with this color multiplied against the blocks color. Note only called
* when first determining what to render.
*/
public int colorMultiplier(IBlockAccess par1IBlockAccess, int par2, int par3, int par4) {
int l = par1IBlockAccess.getBlockMetadata(par2, par3, par4);
if ((l & 3) == 1) {
return ColorizerFoliage.getFoliageColorPine();
} else if ((l & 3) == 2) {
return ColorizerFoliage.getFoliageColorBirch();
} else {
int i1 = 0;
int j1 = 0;
int k1 = 0;
for (int l1 = -1; l1 <= 1; ++l1) {
for (int i2 = -1; i2 <= 1; ++i2) {
int j2 = par1IBlockAccess.getBiomeGenForCoords(par2 + i2, par4 + l1).getBiomeFoliageColor(j1, l1, i1);
i1 += (j2 & 16711680) >> 16;
j1 += (j2 & 65280) >> 8;
k1 += j2 & 255;
}
}
return (i1 / 9 & 255) << 16 | (j1 / 9 & 255) << 8 | k1 / 9 & 255;
}
}
示例8: getRenderColor
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@SideOnly(Side.CLIENT)
/**
* Returns the color this block should be rendered. Used by leaves.
*/
public int getRenderColor(int par1)
{
return (par1 & 3) == 1 ? ColorizerFoliage.getFoliageColorPine() : ((par1 & 3) == 2 ? ColorizerFoliage.getFoliageColorBirch() : ColorizerFoliage.getFoliageColorBasic());
}
示例9: colorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@SideOnly(Side.CLIENT)
/**
* Returns a integer with hex for 0xrrggbb with this color multiplied against the blocks color. Note only called
* when first determining what to render.
*/
public int colorMultiplier(IBlockAccess par1IBlockAccess, int par2, int par3, int par4)
{
int l = par1IBlockAccess.getBlockMetadata(par2, par3, par4);
if ((l & 3) == 1)
{
return ColorizerFoliage.getFoliageColorPine();
}
else if ((l & 3) == 2)
{
return ColorizerFoliage.getFoliageColorBirch();
}
else
{
int i1 = 0;
int j1 = 0;
int k1 = 0;
for (int l1 = -1; l1 <= 1; ++l1)
{
for (int i2 = -1; i2 <= 1; ++i2)
{
int j2 = par1IBlockAccess.getBiomeGenForCoords(par2 + i2, par4 + l1).getBiomeFoliageColor();
i1 += (j2 & 16711680) >> 16;
j1 += (j2 & 65280) >> 8;
k1 += j2 & 255;
}
}
return (i1 / 9 & 255) << 16 | (j1 / 9 & 255) << 8 | k1 / 9 & 255;
}
}
示例10: colorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@SideOnly(Side.CLIENT)
/** Returns a integer with hex for 0xrrggbb with this color multiplied against the blocks color.
* Note only called when first determining what to render. */
public int colorMultiplier(IBlockAccess par1IBlockAccess, int par2, int par3, int par4) {
int var5 = par1IBlockAccess.getBlockMetadata(par2, par3, par4);
if ((var5 & 3) == 1) {
return ColorizerFoliage.getFoliageColorPine();
} else if ((var5 & 3) == 2) {
return ColorizerFoliage.getFoliageColorBirch();
} else {
int var6 = 0;
int var7 = 0;
int var8 = 0;
for (int var9 = -1; var9 <= 1; ++var9) {
for (int var10 = -1; var10 <= 1; ++var10) {
int var11 = par1IBlockAccess.getBiomeGenForCoords(par2 + var10, par4 + var9).getBiomeFoliageColor();
var6 += (var11 & 16711680) >> 16;
var7 += (var11 & 65280) >> 8;
var8 += var11 & 255;
}
}
return (var6 / 9 & 255) << 16 | (var7 / 9 & 255) << 8 | var8 / 9 & 255;
}
}
示例11: getRenderColor
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@SideOnly(Side.CLIENT)
/**
* Returns the color this block should be rendered. Used by leaves.
*/
public int getRenderColor(int par1){
return (par1&3)==1 ? ColorizerFoliage.getFoliageColorPine() : ((par1&3)==2 ? ColorizerFoliage.getFoliageColorBirch() : ColorizerFoliage.getFoliageColorBasic());
}
示例12: colorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
@SideOnly(Side.CLIENT)
/**
* Returns a integer with hex for 0xrrggbb with this color multiplied against the blocks color. Note only called
* when first determining what to render.
*/
public int colorMultiplier(IBlockAccess par1IBlockAccess,int par2,int par3,int par4){
int l=par1IBlockAccess.getBlockMetadata(par2,par3,par4);
if((l&3)==1){
return ColorizerFoliage.getFoliageColorPine();
}
else
if((l&3)==2){
return ColorizerFoliage.getFoliageColorBirch();
}
else{
int i1=0;
int j1=0;
int k1=0;
for(int l1=-1;l1<=1;++l1){
for(int i2=-1;i2<=1;++i2){
int j2=par1IBlockAccess.getBiomeGenForCoords(par2+i2,par4+l1).getBiomeFoliageColor();
i1+=(j2&16711680)>>16;
j1+=(j2&65280)>>8;
k1+=j2&255;
}
}
return (i1/9&255)<<16|(j1/9&255)<<8|k1/9&255;
}
}
示例13: getColor
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
public int getColor(IBlockAccess p_getColor_1_, BlockPos p_getColor_2_)
{
return CustomColors.foliagePineColors != null ? CustomColors.foliagePineColors.getColor(p_getColor_1_, p_getColor_2_) : ColorizerFoliage.getFoliageColorPine();
}
示例14: getSmoothColorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
private static int getSmoothColorMultiplier(Block p_getSmoothColorMultiplier_0_, IBlockAccess p_getSmoothColorMultiplier_1_, BlockPos p_getSmoothColorMultiplier_2_, int[] p_getSmoothColorMultiplier_3_, int[] p_getSmoothColorMultiplier_4_, int p_getSmoothColorMultiplier_5_, int p_getSmoothColorMultiplier_6_, RenderEnv p_getSmoothColorMultiplier_7_)
{
int i = 0;
int j = 0;
int k = 0;
int l = p_getSmoothColorMultiplier_2_.getX();
int i1 = p_getSmoothColorMultiplier_2_.getY();
int j1 = p_getSmoothColorMultiplier_2_.getZ();
BlockPosM blockposm = p_getSmoothColorMultiplier_7_.getColorizerBlockPosM();
for (int k1 = l - 1; k1 <= l + 1; ++k1)
{
for (int l1 = j1 - 1; l1 <= j1 + 1; ++l1)
{
blockposm.setXyz(k1, i1, l1);
int[] aint = p_getSmoothColorMultiplier_3_;
if (p_getSmoothColorMultiplier_4_ != p_getSmoothColorMultiplier_3_ && p_getSmoothColorMultiplier_1_.getBiomeGenForCoords(blockposm) == BiomeGenBase.swampland)
{
aint = p_getSmoothColorMultiplier_4_;
}
int i2 = 0;
if (aint == null)
{
switch (p_getSmoothColorMultiplier_5_)
{
case 1:
i2 = p_getSmoothColorMultiplier_1_.getBiomeGenForCoords(blockposm).getGrassColorAtPos(blockposm);
break;
case 2:
if ((p_getSmoothColorMultiplier_6_ & 3) == 1)
{
i2 = ColorizerFoliage.getFoliageColorPine();
}
else if ((p_getSmoothColorMultiplier_6_ & 3) == 2)
{
i2 = ColorizerFoliage.getFoliageColorBirch();
}
else
{
i2 = p_getSmoothColorMultiplier_1_.getBiomeGenForCoords(blockposm).getFoliageColorAtPos(blockposm);
}
break;
default:
i2 = p_getSmoothColorMultiplier_0_.colorMultiplier(p_getSmoothColorMultiplier_1_, blockposm);
}
}
else
{
i2 = getCustomColor(aint, p_getSmoothColorMultiplier_1_, blockposm);
}
i += i2 >> 16 & 255;
j += i2 >> 8 & 255;
k += i2 & 255;
}
}
int j2 = i / 9;
int k2 = j / 9;
int l2 = k / 9;
return j2 << 16 | k2 << 8 | l2;
}
示例15: getSmoothColorMultiplier
import net.minecraft.world.ColorizerFoliage; //导入方法依赖的package包/类
private static int getSmoothColorMultiplier(Block p_getSmoothColorMultiplier_0_, IBlockAccess p_getSmoothColorMultiplier_1_, BlockPos p_getSmoothColorMultiplier_2_, int[] p_getSmoothColorMultiplier_3_, int[] p_getSmoothColorMultiplier_4_, int p_getSmoothColorMultiplier_5_, int p_getSmoothColorMultiplier_6_, RenderEnv p_getSmoothColorMultiplier_7_)
{
int i = 0;
int j = 0;
int k = 0;
int l = p_getSmoothColorMultiplier_2_.getX();
int i1 = p_getSmoothColorMultiplier_2_.getY();
int j1 = p_getSmoothColorMultiplier_2_.getZ();
BlockPosM blockposm = p_getSmoothColorMultiplier_7_.getColorizerBlockPos();
for (int k1 = l - 1; k1 <= l + 1; ++k1)
{
for (int l1 = j1 - 1; l1 <= j1 + 1; ++l1)
{
blockposm.setXyz(k1, i1, l1);
int[] aint = p_getSmoothColorMultiplier_3_;
if (p_getSmoothColorMultiplier_4_ != p_getSmoothColorMultiplier_3_ && p_getSmoothColorMultiplier_1_.getBiomeGenForCoords(blockposm) == BiomeGenBase.swampland)
{
aint = p_getSmoothColorMultiplier_4_;
}
int i2 = 0;
if (aint == null)
{
switch (p_getSmoothColorMultiplier_5_)
{
case 1:
i2 = p_getSmoothColorMultiplier_1_.getBiomeGenForCoords(blockposm).getGrassColorAtPos(blockposm);
break;
case 2:
if ((p_getSmoothColorMultiplier_6_ & 3) == 1)
{
i2 = ColorizerFoliage.getFoliageColorPine();
}
else if ((p_getSmoothColorMultiplier_6_ & 3) == 2)
{
i2 = ColorizerFoliage.getFoliageColorBirch();
}
else
{
i2 = p_getSmoothColorMultiplier_1_.getBiomeGenForCoords(blockposm).getFoliageColorAtPos(blockposm);
}
break;
default:
i2 = p_getSmoothColorMultiplier_0_.colorMultiplier(p_getSmoothColorMultiplier_1_, blockposm);
}
}
else
{
i2 = getCustomColor(aint, p_getSmoothColorMultiplier_1_, blockposm);
}
i += i2 >> 16 & 255;
j += i2 >> 8 & 255;
k += i2 & 255;
}
}
int j2 = i / 9;
int k2 = j / 9;
int l2 = k / 9;
return j2 << 16 | k2 << 8 | l2;
}