public abstract class LayerArmorBase<T extends ModelBase> extends java.lang.Object implements LayerRenderer<EntityLivingBase>
Modifier and Type | Field and Description |
---|---|
private float |
alpha |
private static java.util.Map<java.lang.String,ResourceLocation> |
ARMOR_TEXTURE_RES_MAP |
private float |
colorB |
private float |
colorG |
private float |
colorR |
protected static ResourceLocation |
ENCHANTED_ITEM_GLINT_RES |
protected T |
modelArmor |
protected T |
modelLeggings |
private RenderLivingBase<?> |
renderer |
private boolean |
skipRenderGlint |
Constructor and Description |
---|
LayerArmorBase(RenderLivingBase<?> rendererIn) |
Modifier and Type | Method and Description |
---|---|
void |
doRenderLayer(EntityLivingBase entitylivingbaseIn,
float limbSwing,
float limbSwingAmount,
float partialTicks,
float ageInTicks,
float netHeadYaw,
float headPitch,
float scale) |
protected T |
getArmorModelHook(EntityLivingBase entity,
ItemStack itemStack,
EntityEquipmentSlot slot,
T model)
Hook to allow item-sensitive armor model.
|
ResourceLocation |
getArmorResource(Entity entity,
ItemStack stack,
EntityEquipmentSlot slot,
java.lang.String type)
More generic ForgeHook version of the above function, it allows for Items to have more control over what texture they provide.
|
private ResourceLocation |
getArmorResource(ItemArmor armor,
boolean p_177181_2_)
Deprecated.
|
private ResourceLocation |
getArmorResource(ItemArmor armor,
boolean p_177178_2_,
java.lang.String p_177178_3_)
Deprecated.
|
T |
getModelFromSlot(EntityEquipmentSlot slotIn) |
protected abstract void |
initArmor() |
private boolean |
isLegSlot(EntityEquipmentSlot slotIn) |
private void |
renderArmorLayer(EntityLivingBase entityLivingBaseIn,
float limbSwing,
float limbSwingAmount,
float partialTicks,
float ageInTicks,
float netHeadYaw,
float headPitch,
float scale,
EntityEquipmentSlot slotIn) |
static void |
renderEnchantedGlint(RenderLivingBase<?> p_188364_0_,
EntityLivingBase p_188364_1_,
ModelBase model,
float p_188364_3_,
float p_188364_4_,
float p_188364_5_,
float p_188364_6_,
float p_188364_7_,
float p_188364_8_,
float p_188364_9_) |
protected abstract void |
setModelSlotVisible(T p_188359_1_,
EntityEquipmentSlot slotIn) |
boolean |
shouldCombineTextures() |
protected static final ResourceLocation ENCHANTED_ITEM_GLINT_RES
private final RenderLivingBase<?> renderer
private float alpha
private float colorR
private float colorG
private float colorB
private boolean skipRenderGlint
private static final java.util.Map<java.lang.String,ResourceLocation> ARMOR_TEXTURE_RES_MAP
public LayerArmorBase(RenderLivingBase<?> rendererIn)
public void doRenderLayer(EntityLivingBase entitylivingbaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch, float scale)
doRenderLayer
in interface LayerRenderer<EntityLivingBase>
public boolean shouldCombineTextures()
shouldCombineTextures
in interface LayerRenderer<EntityLivingBase>
private void renderArmorLayer(EntityLivingBase entityLivingBaseIn, float limbSwing, float limbSwingAmount, float partialTicks, float ageInTicks, float netHeadYaw, float headPitch, float scale, EntityEquipmentSlot slotIn)
public T getModelFromSlot(EntityEquipmentSlot slotIn)
private boolean isLegSlot(EntityEquipmentSlot slotIn)
public static void renderEnchantedGlint(RenderLivingBase<?> p_188364_0_, EntityLivingBase p_188364_1_, ModelBase model, float p_188364_3_, float p_188364_4_, float p_188364_5_, float p_188364_6_, float p_188364_7_, float p_188364_8_, float p_188364_9_)
@Deprecated private ResourceLocation getArmorResource(ItemArmor armor, boolean p_177181_2_)
@Deprecated private ResourceLocation getArmorResource(ItemArmor armor, boolean p_177178_2_, java.lang.String p_177178_3_)
protected abstract void initArmor()
protected abstract void setModelSlotVisible(T p_188359_1_, EntityEquipmentSlot slotIn)
protected T getArmorModelHook(EntityLivingBase entity, ItemStack itemStack, EntityEquipmentSlot slot, T model)
public ResourceLocation getArmorResource(Entity entity, ItemStack stack, EntityEquipmentSlot slot, java.lang.String type)
entity
- Entity wearing the armorstack
- ItemStack for the armorslot
- Slot ID that the item is intype
- Subtype, can be null or "overlay"