本文整理汇总了Java中net.minecraft.entity.passive.EntityWolf.isInvisible方法的典型用法代码示例。如果您正苦于以下问题:Java EntityWolf.isInvisible方法的具体用法?Java EntityWolf.isInvisible怎么用?Java EntityWolf.isInvisible使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类net.minecraft.entity.passive.EntityWolf
的用法示例。
在下文中一共展示了EntityWolf.isInvisible方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: doRenderLayer
import net.minecraft.entity.passive.EntityWolf; //导入方法依赖的package包/类
public void doRenderLayer(EntityWolf entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch, float scale)
{
if (entitylivingbaseIn.isTamed() && !entitylivingbaseIn.isInvisible())
{
this.wolfRenderer.bindTexture(WOLF_COLLAR);
float[] afloat = EntitySheep.getDyeRgb(entitylivingbaseIn.getCollarColor());
if (Config.isCustomColors())
{
afloat = CustomColors.getWolfCollarColors(entitylivingbaseIn.getCollarColor(), afloat);
}
GlStateManager.color(afloat[0], afloat[1], afloat[2]);
this.wolfRenderer.getMainModel().render(entitylivingbaseIn, limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scale);
}
}
示例2: doRenderLayer
import net.minecraft.entity.passive.EntityWolf; //导入方法依赖的package包/类
@Override
public void doRenderLayer(EntityWolf entity, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch, float scale) {
boolean invis = entity.isInvisible() || entity.isInvisibleToPlayer(CrystalMod.proxy.getClientPlayer());
if(invis)return;
if(ItemStackTools.isValid(WolfAccessories.getWolfArmorStack(entity))){
ItemStack armorStack = WolfAccessories.getWolfArmorStack(entity);
GlStateManager.pushMatrix();
for(int i = 0; i < 2; i++){
ModelWolfArmor model = null;
if(i == 0)model = modelWolfArmor0;
if(i == 1)model = modelWolfArmor1;
if(model !=null){
model.setModelAttributes(renderer.getMainModel());
model.setLivingAnimations(entity, limbSwing, limbSwingAmount, partialTicks);
//TODO Add leather armor dying support
renderer.bindTexture(getTexture(WolfAccessories.getWolfArmor(armorStack), i));
GlStateManager.color(1, 1, 1, 1);
model.render(entity, limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scale);
}
}
GlStateManager.popMatrix();
}
}
示例3: doRenderLayer
import net.minecraft.entity.passive.EntityWolf; //导入方法依赖的package包/类
public void doRenderLayer(EntityWolf entitylivingbaseIn, float p_177141_2_, float p_177141_3_, float partialTicks, float p_177141_5_, float p_177141_6_, float p_177141_7_, float scale)
{
if (entitylivingbaseIn.isTamed() && !entitylivingbaseIn.isInvisible())
{
this.wolfRenderer.bindTexture(WOLF_COLLAR);
EnumDyeColor enumdyecolor = EnumDyeColor.byMetadata(entitylivingbaseIn.getCollarColor().getMetadata());
float[] afloat = EntitySheep.func_175513_a(enumdyecolor);
GlStateManager.color(afloat[0], afloat[1], afloat[2]);
this.wolfRenderer.getMainModel().render(entitylivingbaseIn, p_177141_2_, p_177141_3_, p_177141_5_, p_177141_6_, p_177141_7_, scale);
}
}
示例4: doRenderLayer
import net.minecraft.entity.passive.EntityWolf; //导入方法依赖的package包/类
public void doRenderLayer(EntityWolf entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch, float scale)
{
if (entitylivingbaseIn.isTamed() && !entitylivingbaseIn.isInvisible())
{
this.wolfRenderer.bindTexture(WOLF_COLLAR);
EnumDyeColor enumdyecolor = EnumDyeColor.byMetadata(entitylivingbaseIn.getCollarColor().getMetadata());
float[] afloat = EntitySheep.getDyeRgb(enumdyecolor);
GlStateManager.color(afloat[0], afloat[1], afloat[2]);
this.wolfRenderer.getMainModel().render(entitylivingbaseIn, limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scale);
}
}
示例5: doRenderLayer
import net.minecraft.entity.passive.EntityWolf; //导入方法依赖的package包/类
/**
* Renders the layer.
*
* @param entityWolf The wolf to render. If it is not am EntityWolfArmored, the layer will not render.
* @param limbSwing The entity's limb swing progress.
* @param limbSwingAmount The entity's limb swing progress amount.
* @param partialTicks The current game tick.
* @param ageInTicks The entity's age.
* @param netHeadYaw The yaw of the entity's head.
* @param headPitch The pitch of the entity's head.
* @param scale The scale at which to render the layer.
*/
@SuppressWarnings("ConstantConditions")
@Override
public void doRenderLayer(@Nonnull EntityWolf entityWolf,
float limbSwing,
float limbSwingAmount,
float partialTicks,
float ageInTicks,
float netHeadYaw,
float headPitch,
float scale) {
if (!WolfArmorMod.getConfiguration().getIsWolfChestRenderEnabled()) {
return;
}
IWolfArmorCapability wolfArmor = entityWolf.getCapability(CapabilityWolfArmor.WOLF_ARMOR_CAPABILITY, null);
if (wolfArmor != null && wolfArmor.getHasChest()) {
this.modelWolfBackpack.setModelAttributes(renderer.getMainModel());
this.modelWolfBackpack.setLivingAnimations(entityWolf, limbSwing, limbSwingAmount, partialTicks);
this.renderer.bindTexture(Textures.TEXTURE_WOLF_BACKPACK);
GlStateManager.color(1, 1, 1, 1);
if (!entityWolf.isInvisible()) {
this.modelWolfBackpack.render(entityWolf, limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scale);
} else {
GlStateManager.pushMatrix();
{
GlStateManager.color(1, 1, 1, 0.15F);
GlStateManager.depthMask(false);
{
GlStateManager.enableBlend();
{
GlStateManager.blendFunc(GlStateManager.SourceFactor.SRC_ALPHA,
GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA);
this.modelWolfBackpack.render(entityWolf,
limbSwing,
limbSwingAmount,
ageInTicks,
netHeadYaw,
headPitch,
scale);
}
GlStateManager.disableBlend();
}
GlStateManager.depthMask(true);
}
GlStateManager.popMatrix();
}
}
}