24 lines
808 B
Java
24 lines
808 B
Java
package net.minecraft.client.renderer.entity;
|
|
|
|
import net.fabricmc.api.EnvType;
|
|
import net.fabricmc.api.Environment;
|
|
import net.minecraft.client.model.BatModel;
|
|
import net.minecraft.client.model.geom.ModelLayers;
|
|
import net.minecraft.resources.ResourceLocation;
|
|
import net.minecraft.world.entity.ambient.Bat;
|
|
|
|
@Environment(EnvType.CLIENT)
|
|
public class BatRenderer extends MobRenderer<Bat, BatModel> {
|
|
private static final ResourceLocation BAT_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/bat.png");
|
|
|
|
public BatRenderer(EntityRendererProvider.Context context) {
|
|
super(context, new BatModel(context.bakeLayer(ModelLayers.BAT)), 0.25F);
|
|
}
|
|
|
|
/**
|
|
* Returns the location of an entity's texture.
|
|
*/
|
|
public ResourceLocation getTextureLocation(Bat entity) {
|
|
return BAT_LOCATION;
|
|
}
|
|
}
|