本文整理汇总了Java中net.minecraftforge.fml.client.registry.IRenderFactory类的典型用法代码示例。如果您正苦于以下问题:Java IRenderFactory类的具体用法?Java IRenderFactory怎么用?Java IRenderFactory使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
IRenderFactory类属于net.minecraftforge.fml.client.registry包,在下文中一共展示了IRenderFactory类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: register
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static <ENTITY extends Entity> void register(Class<ENTITY> classes, final Class<? extends Render<ENTITY>> render)
{
RenderingRegistry.registerEntityRenderingHandler(classes, new IRenderFactory<ENTITY>() {
@Override
public Render<ENTITY> createRenderFor(RenderManager manager)
{
try
{
return render.getConstructor(RenderManager.class).newInstance(manager);
}
catch (Exception e)
{
e.printStackTrace();
}
return null;
}
});
}
示例2: preInit
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
@Override
public void preInit(FMLPreInitializationEvent evt) {
MCDoom.instance.getGoreProperty().setConfigEntryClass(GuiConfigEntries.NumberSliderEntry.class);
MCDoom.instance.getMaxGoreParticles().setConfigEntryClass(GuiConfigEntries.NumberSliderEntry.class);
MinecraftForge.EVENT_BUS.register(screenEventHandler);
MinecraftForge.EVENT_BUS.register(soundEventsHandler);
registerItems();
RenderingRegistry.registerEntityRenderingHandler(PlasmaBallEntity.class, new IRenderFactory<PlasmaBallEntity>() {
@Override
public Render<? super PlasmaBallEntity> createRenderFor(RenderManager manager) {
return new RenderPlasmaBall(manager);
}
});
loadWeaponRenderers();
}
示例3: registerEntityRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
@SideOnly(Side.CLIENT)
public static void registerEntityRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityMobTest.class, new IRenderFactory() {
@Override
public Render createRenderFor(RenderManager manager) {
return new RenderMobTest(manager, new ModelMobTest(), 0.4F);
}});
}
示例4: initModels
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
@SideOnly(Side.CLIENT)
public static void initModels() {
RenderingRegistry.registerEntityRenderingHandler(EntityMeeCreeps.class, RenderMeeCreeps.FACTORY);
RenderingRegistry.registerEntityRenderingHandler(EntityProjectile.class, new IRenderFactory<EntityProjectile>() {
@Override
public Render<? super EntityProjectile> createRenderFor(RenderManager manager) {
return new RenderProjectile<EntityProjectile>(manager, Minecraft.getMinecraft().getRenderItem());
}
});
}
示例5: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
System.out.println("registering renders");
RenderingRegistry.registerEntityRenderingHandler(EntityBailey.class, new IRenderFactory<EntityBailey>() {
@Override
public Render<EntityBailey> createRenderFor(RenderManager manager) {
return new RenderBailey(manager);
}
});
}
示例6: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityKing.class, new IRenderFactory<EntityKing>() {
@Override
public Render<EntityKing> createRenderFor(RenderManager manager) {
return new RenderKing(manager);
}
});
}
示例7: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityRook.class, new IRenderFactory<EntityRook>() {
@Override
public Render<EntityRook> createRenderFor(RenderManager manager) {
return new RenderRook(manager);
}
});
}
示例8: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityPawn.class, new IRenderFactory<EntityPawn>() {
@Override
public Render<EntityPawn> createRenderFor(RenderManager manager) {
return new RenderPawn(manager);
}
});
}
示例9: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityKnight.class, new IRenderFactory<EntityKnight>() {
@Override
public Render<EntityKnight> createRenderFor(RenderManager manager) {
return new RenderKnight(manager);
}
});
}
示例10: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityBishop.class, new IRenderFactory<EntityBishop>() {
@Override
public Render<EntityBishop> createRenderFor(RenderManager manager) {
return new RenderBishop(manager);
}
});
}
示例11: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityQueen.class, new IRenderFactory<EntityQueen>() {
@Override
public Render<EntityQueen> createRenderFor(RenderManager manager) {
return new RenderQueen(manager);
}
});
}
示例12: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityRainbowKing.class, new IRenderFactory<EntityRainbowKing>() {
@Override
public Render<? super EntityRainbowKing> createRenderFor(RenderManager manager) {
return new RenderRainbowKing(manager);
}
});
}
示例13: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityShopkeeper.class, new IRenderFactory<EntityShopkeeper>() {
@Override
public Render<EntityShopkeeper> createRenderFor(RenderManager manager) {
return new RenderShopkeeper(manager);
}
});
}
示例14: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityVillageLord.class, new IRenderFactory<EntityVillageLord>() {
@Override
public Render<EntityVillageLord> createRenderFor(RenderManager manager) {
return new RenderVillageLord(manager);
}
});
}
示例15: registerRenders
import net.minecraftforge.fml.client.registry.IRenderFactory; //导入依赖的package包/类
public static void registerRenders() {
RenderingRegistry.registerEntityRenderingHandler(EntityVampireBat.class, new IRenderFactory<EntityVampireBat>() {
@Override
public Render<EntityVampireBat> createRenderFor(RenderManager manager) {
return new RenderVampireBat(manager);
}
});
}