32 lines
1.3 KiB
Java
32 lines
1.3 KiB
Java
/*
|
|
* Decompiled with CFR 0.152.
|
|
*/
|
|
package net.minecraft.client.renderer.entity;
|
|
|
|
import net.minecraft.client.model.HoglinModel;
|
|
import net.minecraft.client.model.geom.ModelLayerLocation;
|
|
import net.minecraft.client.renderer.entity.AgeableMobRenderer;
|
|
import net.minecraft.client.renderer.entity.EntityRendererProvider;
|
|
import net.minecraft.client.renderer.entity.state.HoglinRenderState;
|
|
import net.minecraft.world.entity.Mob;
|
|
import net.minecraft.world.entity.monster.hoglin.HoglinBase;
|
|
|
|
public abstract class AbstractHoglinRenderer<T extends Mob>
|
|
extends AgeableMobRenderer<T, HoglinRenderState, HoglinModel> {
|
|
public AbstractHoglinRenderer(EntityRendererProvider.Context context, ModelLayerLocation adultLayer, ModelLayerLocation babyLayer, float shadow) {
|
|
super(context, new HoglinModel(context.bakeLayer(adultLayer)), new HoglinModel(context.bakeLayer(babyLayer)), shadow);
|
|
}
|
|
|
|
@Override
|
|
public HoglinRenderState createRenderState() {
|
|
return new HoglinRenderState();
|
|
}
|
|
|
|
@Override
|
|
public void extractRenderState(T entity, HoglinRenderState state, float partialTicks) {
|
|
super.extractRenderState(entity, state, partialTicks);
|
|
state.attackAnimationRemainingTicks = ((HoglinBase)entity).getAttackAnimationRemainingTicks();
|
|
}
|
|
}
|
|
|