當前位置: 首頁>>代碼示例>>Java>>正文


Java RenderManager類代碼示例

本文整理匯總了Java中net.minecraft.client.renderer.entity.RenderManager的典型用法代碼示例。如果您正苦於以下問題:Java RenderManager類的具體用法?Java RenderManager怎麽用?Java RenderManager使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


RenderManager類屬於net.minecraft.client.renderer.entity包,在下文中一共展示了RenderManager類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: renderParticle

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
/**
 * Renders the particle
 */
public void renderParticle(VertexBuffer worldRendererIn, Entity entityIn, float partialTicks, float rotationX, float rotationZ, float rotationYZ, float rotationXY, float rotationXZ)
{
    if (this.entity != null)
    {
        RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
        rendermanager.setRenderPosition(Particle.interpPosX, Particle.interpPosY, Particle.interpPosZ);
        float f = 0.42553192F;
        float f1 = ((float)this.particleAge + partialTicks) / (float)this.particleMaxAge;
        GlStateManager.depthMask(true);
        GlStateManager.enableBlend();
        GlStateManager.enableDepth();
        GlStateManager.blendFunc(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA);
        float f2 = 240.0F;
        OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, 240.0F, 240.0F);
        GlStateManager.pushMatrix();
        float f3 = 0.05F + 0.5F * MathHelper.sin(f1 * (float)Math.PI);
        GlStateManager.color(1.0F, 1.0F, 1.0F, f3);
        GlStateManager.translate(0.0F, 1.8F, 0.0F);
        GlStateManager.rotate(180.0F - entityIn.rotationYaw, 0.0F, 1.0F, 0.0F);
        GlStateManager.rotate(60.0F - 150.0F * f1 - entityIn.rotationPitch, 1.0F, 0.0F, 0.0F);
        GlStateManager.translate(0.0F, -0.4F, -1.5F);
        GlStateManager.scale(0.42553192F, 0.42553192F, 0.42553192F);
        this.entity.rotationYaw = 0.0F;
        this.entity.rotationYawHead = 0.0F;
        this.entity.prevRotationYaw = 0.0F;
        this.entity.prevRotationYawHead = 0.0F;
        rendermanager.doRenderEntity(this.entity, 0.0D, 0.0D, 0.0D, 0.0F, partialTicks, false);
        GlStateManager.popMatrix();
        GlStateManager.enableDepth();
    }
}
 
開發者ID:F1r3w477,項目名稱:CustomWorldGen,代碼行數:35,代碼來源:ParticleMobAppearance.java

示例2: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderShulkerBullet rendershulkerbullet = new RenderShulkerBullet(rendermanager);

    if (!Reflector.RenderShulkerBullet_model.exists())
    {
        Config.warn("Field not found: RenderShulkerBullet.model");
        return null;
    }
    else
    {
        Reflector.setFieldValue(rendershulkerbullet, Reflector.RenderShulkerBullet_model, modelBase);
        rendershulkerbullet.shadowSize = shadowSize;
        return rendershulkerbullet;
    }
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:18,代碼來源:ModelAdapterShulkerBullet.java

示例3: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderEvoker renderevoker = new RenderEvoker(rendermanager);
    renderevoker.mainModel = modelBase;
    renderevoker.shadowSize = shadowSize;
    return renderevoker;
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:9,代碼來源:ModelAdapterEvoker.java

示例4: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderSheep rendersheep = new RenderSheep(rendermanager);
    rendersheep.mainModel = modelBase;
    rendersheep.shadowSize = shadowSize;
    return rendersheep;
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:9,代碼來源:ModelAdapterSheep.java

示例5: entityESPBox

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public static void entityESPBox(Entity entity, Color c) {
	GL11.glBlendFunc(770, 771);
	GL11.glEnable(GL_BLEND);
	GL11.glLineWidth(2.0F);
	GL11.glDisable(GL11.GL_TEXTURE_2D);
	GL11.glDisable(GL_DEPTH_TEST);
	GL11.glDepthMask(false);
	GL11.glColor4f(c.getRed() / 255f, c.getGreen() / 255f, c.getBlue() / 255f, c.getAlpha() / 255f);
	RenderManager renderManager = Minecraft.getMinecraft().getRenderManager();
	drawSelectionBoundingBox(new AxisAlignedBB(
			entity.boundingBox.minX - 0.05 - entity.posX + (entity.posX - renderManager.renderPosX),
			entity.boundingBox.minY - entity.posY + (entity.posY - renderManager.renderPosY),
			entity.boundingBox.minZ - 0.05 - entity.posZ + (entity.posZ - renderManager.renderPosZ),
			entity.boundingBox.maxX + 0.05 - entity.posX + (entity.posX - renderManager.renderPosX),
			entity.boundingBox.maxY + 0.1 - entity.posY + (entity.posY - renderManager.renderPosY),
			entity.boundingBox.maxZ + 0.05 - entity.posZ + (entity.posZ - renderManager.renderPosZ)));
	GL11.glEnable(GL11.GL_TEXTURE_2D);
	GL11.glEnable(GL_DEPTH_TEST);
	GL11.glDepthMask(true);
	GL11.glDisable(GL_BLEND);
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:22,代碼來源:RenderUtils.java

示例6: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderWither renderwither = new RenderWither(rendermanager);
    renderwither.mainModel = modelBase;
    renderwither.shadowSize = shadowSize;
    return renderwither;
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:9,代碼來源:ModelAdapterWither.java

示例7: drawEntityBoxOutline

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public static void drawEntityBoxOutline(EntityLivingBase target, int color, float lineWidth, float partialTicks) {
    GL11.glPushMatrix();
    GL11.glLineWidth(lineWidth);
    double[] pos = EntityUtil.interpolate(target, partialTicks);
    double posX = pos[0] - RenderManager.field_78725_b;
    double posY = pos[1] - RenderManager.field_78726_c;
    double posZ = pos[2] - RenderManager.field_78723_d;
    AxisAlignedBB bb = AxisAlignedBB.func_72330_a(Wrapper.getEntityBoundingBox(target).field_72340_a - Wrapper.getPosX(target) + posX,
            Wrapper.getEntityBoundingBox(target).field_72338_b - Wrapper.getPosY(target) + posY,
            Wrapper.getEntityBoundingBox(target).field_72339_c - Wrapper.getPosZ(target) + posZ,
            Wrapper.getEntityBoundingBox(target).field_72336_d - Wrapper.getPosX(target) + posX,
            Wrapper.getEntityBoundingBox(target).field_72337_e - Wrapper.getPosY(target) + posY,
            Wrapper.getEntityBoundingBox(target).field_72334_f - Wrapper.getPosZ(target) + posZ);
    drawBoxOutline(bb, color, true);
    GL11.glPopMatrix();
}
 
開發者ID:Ygore,項目名稱:bit-client,代碼行數:17,代碼來源:RenderUtil.java

示例8: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderMinecart renderminecart = new RenderMinecart(rendermanager);

    if (!Reflector.RenderMinecart_modelMinecart.exists())
    {
        Config.warn("Field not found: RenderMinecart.modelMinecart");
        return null;
    }
    else
    {
        Reflector.setFieldValue(renderminecart, Reflector.RenderMinecart_modelMinecart, modelBase);
        renderminecart.shadowSize = shadowSize;
        return renderminecart;
    }
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:18,代碼來源:ModelAdapterMinecart.java

示例9: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderTntMinecart rendertntminecart = new RenderTntMinecart(rendermanager);

    if (!Reflector.RenderMinecart_modelMinecart.exists())
    {
        Config.warn("Field not found: RenderMinecart.modelMinecart");
        return null;
    }
    else
    {
        Reflector.setFieldValue(rendertntminecart, Reflector.RenderMinecart_modelMinecart, modelBase);
        rendertntminecart.shadowSize = shadowSize;
        return rendertntminecart;
    }
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:18,代碼來源:ModelAdapterMinecartTnt.java

示例10: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderWitherSkull renderwitherskull = new RenderWitherSkull(rendermanager);

    if (!Reflector.RenderWitherSkull_model.exists())
    {
        Config.warn("Field not found: RenderWitherSkull_model");
        return null;
    }
    else
    {
        Reflector.setFieldValue(renderwitherskull, Reflector.RenderWitherSkull_model, modelBase);
        renderwitherskull.shadowSize = shadowSize;
        return renderwitherskull;
    }
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:18,代碼來源:ModelAdapterWitherSkull.java

示例11: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderWolf renderwolf = new RenderWolf(rendermanager);
    renderwolf.mainModel = modelBase;
    renderwolf.shadowSize = shadowSize;
    return renderwolf;
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:9,代碼來源:ModelAdapterWolf.java

示例12: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderDragon renderdragon = new RenderDragon(rendermanager);
    renderdragon.mainModel = modelBase;
    renderdragon.shadowSize = shadowSize;
    return renderdragon;
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:9,代碼來源:ModelAdapterDragon.java

示例13: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderVex rendervex = new RenderVex(rendermanager);
    rendervex.mainModel = modelBase;
    rendervex.shadowSize = shadowSize;
    return rendervex;
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:9,代碼來源:ModelAdapterVex.java

示例14: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderAbstractHorse renderabstracthorse = new RenderAbstractHorse(rendermanager);
    renderabstracthorse.mainModel = modelBase;
    renderabstracthorse.shadowSize = shadowSize;
    return renderabstracthorse;
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:9,代碼來源:ModelAdapterDonkey.java

示例15: makeEntityRender

import net.minecraft.client.renderer.entity.RenderManager; //導入依賴的package包/類
public IEntityRenderer makeEntityRender(ModelBase modelBase, float shadowSize)
{
    RenderManager rendermanager = Minecraft.getMinecraft().getRenderManager();
    RenderZombie renderzombie = new RenderZombie(rendermanager);
    renderzombie.mainModel = modelBase;
    renderzombie.shadowSize = shadowSize;
    return renderzombie;
}
 
開發者ID:sudofox,項目名稱:Backmemed,代碼行數:9,代碼來源:ModelAdapterZombie.java


注:本文中的net.minecraft.client.renderer.entity.RenderManager類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。