当前位置: 首页>>代码示例>>Java>>正文


Java Entity.addEntityCrashInfo方法代码示例

本文整理汇总了Java中net.minecraft.entity.Entity.addEntityCrashInfo方法的典型用法代码示例。如果您正苦于以下问题:Java Entity.addEntityCrashInfo方法的具体用法?Java Entity.addEntityCrashInfo怎么用?Java Entity.addEntityCrashInfo使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在net.minecraft.entity.Entity的用法示例。


在下文中一共展示了Entity.addEntityCrashInfo方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: doRenderEntity

import net.minecraft.entity.Entity; //导入方法依赖的package包/类
public boolean doRenderEntity(Entity entity, double x, double y, double z, float entityYaw, float partialTicks, boolean p_147939_10_)
{
    Render<Entity> render = null;

    try
    {
        render = this.<Entity>getEntityRenderObject(entity);

        if (render != null && this.renderEngine != null)
        {
            try
            {
                if (render instanceof RendererLivingEntity)
                {
                    ((RendererLivingEntity)render).setRenderOutlines(this.renderOutlines);
                }

                render.doRender(entity, x, y, z, entityYaw, partialTicks);
            }
            catch (Throwable throwable2)
            {
                throw new ReportedException(CrashReport.makeCrashReport(throwable2, "Rendering entity in world"));
            }

            try
            {
                if (!this.renderOutlines)
                {
                    render.doRenderShadowAndFire(entity, x, y, z, entityYaw, partialTicks);
                }
            }
            catch (Throwable throwable1)
            {
                throw new ReportedException(CrashReport.makeCrashReport(throwable1, "Post-rendering entity in world"));
            }

            if (this.debugBoundingBox && !entity.isInvisible() && !p_147939_10_)
            {
                try
                {
                    this.renderDebugBoundingBox(entity, x, y, z, entityYaw, partialTicks);
                }
                catch (Throwable throwable)
                {
                    throw new ReportedException(CrashReport.makeCrashReport(throwable, "Rendering entity hitbox in world"));
                }
            }
        }
        else if (this.renderEngine != null)
        {
            return false;
        }

        return true;
    }
    catch (Throwable throwable3)
    {
        CrashReport crashreport = CrashReport.makeCrashReport(throwable3, "Rendering entity in world");
        CrashReportCategory crashreportcategory = crashreport.makeCategory("Entity being rendered");
        entity.addEntityCrashInfo(crashreportcategory);
        CrashReportCategory crashreportcategory1 = crashreport.makeCategory("Renderer details");
        crashreportcategory1.addCrashSection("Assigned renderer", render);
        crashreportcategory1.addCrashSection("Location", CrashReportCategory.getCoordinateInfo(x, y, z));
        crashreportcategory1.addCrashSection("Rotation", Float.valueOf(entityYaw));
        crashreportcategory1.addCrashSection("Delta", Float.valueOf(partialTicks));
        throw new ReportedException(crashreport);
    }
}
 
开发者ID:Notoh,项目名称:DecompiledMinecraft,代码行数:69,代码来源:RenderManager.java

示例2: doRenderEntity

import net.minecraft.entity.Entity; //导入方法依赖的package包/类
public boolean doRenderEntity(Entity entity, double x, double y, double z, float entityYaw, float partialTicks, boolean p_147939_10_)
{
    Render render = null;

    try
    {
        render = this.getEntityRenderObject(entity);

        if (render != null && this.renderEngine != null)
        {
            try
            {
                if (render instanceof RendererLivingEntity)
                {
                    ((RendererLivingEntity)render).setRenderOutlines(this.renderOutlines);
                }

                render.doRender(entity, x, y, z, entityYaw, partialTicks);
            }
            catch (Throwable throwable2)
            {
                throw new ReportedException(CrashReport.makeCrashReport(throwable2, "Rendering entity in world"));
            }

            try
            {
                if (!this.renderOutlines)
                {
                    render.doRenderShadowAndFire(entity, x, y, z, entityYaw, partialTicks);
                }
            }
            catch (Throwable throwable1)
            {
                throw new ReportedException(CrashReport.makeCrashReport(throwable1, "Post-rendering entity in world"));
            }

            if (this.debugBoundingBox && !entity.isInvisible() && !p_147939_10_)
            {
                try
                {
                    this.renderDebugBoundingBox(entity, x, y, z, entityYaw, partialTicks);
                }
                catch (Throwable throwable)
                {
                    throw new ReportedException(CrashReport.makeCrashReport(throwable, "Rendering entity hitbox in world"));
                }
            }
        }
        else if (this.renderEngine != null)
        {
            return false;
        }

        return true;
    }
    catch (Throwable throwable3)
    {
        CrashReport crashreport = CrashReport.makeCrashReport(throwable3, "Rendering entity in world");
        CrashReportCategory crashreportcategory = crashreport.makeCategory("Entity being rendered");
        entity.addEntityCrashInfo(crashreportcategory);
        CrashReportCategory crashreportcategory1 = crashreport.makeCategory("Renderer details");
        crashreportcategory1.addCrashSection("Assigned renderer", render);
        crashreportcategory1.addCrashSection("Location", CrashReportCategory.getCoordinateInfo(x, y, z));
        crashreportcategory1.addCrashSection("Rotation", Float.valueOf(entityYaw));
        crashreportcategory1.addCrashSection("Delta", Float.valueOf(partialTicks));
        throw new ReportedException(crashreport);
    }
}
 
开发者ID:SkidJava,项目名称:BaseClient,代码行数:69,代码来源:RenderManager.java

示例3: tickPlayers

import net.minecraft.entity.Entity; //导入方法依赖的package包/类
protected void tickPlayers()
{
    super.tickPlayers();
    this.theProfiler.endStartSection("players");

    for (int i = 0; i < this.playerEntities.size(); ++i)
    {
        Entity entity = (Entity)this.playerEntities.get(i);
        Entity entity1 = entity.getRidingEntity();

        if (entity1 != null)
        {
            if (!entity1.isDead && entity1.isPassenger(entity))
            {
                continue;
            }

            entity.dismountRidingEntity();
        }

        this.theProfiler.startSection("tick");

        if (!entity.isDead)
        {
            try
            {
                this.updateEntity(entity);
            }
            catch (Throwable throwable)
            {
                CrashReport crashreport = CrashReport.makeCrashReport(throwable, "Ticking player");
                CrashReportCategory crashreportcategory = crashreport.makeCategory("Player being ticked");
                entity.addEntityCrashInfo(crashreportcategory);
                throw new ReportedException(crashreport);
            }
        }

        this.theProfiler.endSection();
        this.theProfiler.startSection("remove");

        if (entity.isDead)
        {
            int j = entity.chunkCoordX;
            int k = entity.chunkCoordZ;

            if (entity.addedToChunk && this.isChunkLoaded(j, k, true))
            {
                this.getChunkFromChunkCoords(j, k).removeEntity(entity);
            }

            this.loadedEntityList.remove(entity);
            this.onEntityRemoved(entity);
        }

        this.theProfiler.endSection();
    }
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:58,代码来源:WorldServer.java

示例4: doRenderEntity

import net.minecraft.entity.Entity; //导入方法依赖的package包/类
public void doRenderEntity(Entity entityIn, double x, double y, double z, float yaw, float partialTicks, boolean p_188391_10_)
{
    Render<Entity> render = null;

    try
    {
        render = this.<Entity>getEntityRenderObject(entityIn);

        if (render != null && this.renderEngine != null)
        {
            try
            {
                render.setRenderOutlines(this.renderOutlines);

                if (CustomEntityModels.isActive())
                {
                    this.renderEntity = entityIn;
                    this.renderRender = render;
                }

                render.doRender(entityIn, x, y, z, yaw, partialTicks);
            }
            catch (Throwable throwable2)
            {
                throw new ReportedException(CrashReport.makeCrashReport(throwable2, "Rendering entity in world"));
            }

            try
            {
                if (!this.renderOutlines)
                {
                    render.doRenderShadowAndFire(entityIn, x, y, z, yaw, partialTicks);
                }
            }
            catch (Throwable throwable1)
            {
                throw new ReportedException(CrashReport.makeCrashReport(throwable1, "Post-rendering entity in world"));
            }

            if (this.debugBoundingBox && !entityIn.isInvisible() && !p_188391_10_ && !Minecraft.getMinecraft().isReducedDebug())
            {
                try
                {
                    this.renderDebugBoundingBox(entityIn, x, y, z, yaw, partialTicks);
                }
                catch (Throwable throwable)
                {
                    throw new ReportedException(CrashReport.makeCrashReport(throwable, "Rendering entity hitbox in world"));
                }
            }
        }
    }
    catch (Throwable throwable3)
    {
        CrashReport crashreport = CrashReport.makeCrashReport(throwable3, "Rendering entity in world");
        CrashReportCategory crashreportcategory = crashreport.makeCategory("Entity being rendered");
        entityIn.addEntityCrashInfo(crashreportcategory);
        CrashReportCategory crashreportcategory1 = crashreport.makeCategory("Renderer details");
        crashreportcategory1.addCrashSection("Assigned renderer", render);
        crashreportcategory1.addCrashSection("Location", CrashReportCategory.getCoordinateInfo(x, y, z));
        crashreportcategory1.addCrashSection("Rotation", Float.valueOf(yaw));
        crashreportcategory1.addCrashSection("Delta", Float.valueOf(partialTicks));
        throw new ReportedException(crashreport);
    }
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:66,代码来源:RenderManager.java

示例5: doRenderEntity

import net.minecraft.entity.Entity; //导入方法依赖的package包/类
public void doRenderEntity(Entity entityIn, double x, double y, double z, float yaw, float partialTicks, boolean p_188391_10_)
{
    Render<Entity> render = null;

    try
    {
        render = this.<Entity>getEntityRenderObject(entityIn);

        if (render != null && this.renderEngine != null)
        {
            try
            {
                render.setRenderOutlines(this.renderOutlines);
                render.doRender(entityIn, x, y, z, yaw, partialTicks);
            }
            catch (Throwable throwable1)
            {
                throw new ReportedException(CrashReport.makeCrashReport(throwable1, "Rendering entity in world"));
            }

            try
            {
                if (!this.renderOutlines)
                {
                    render.doRenderShadowAndFire(entityIn, x, y, z, yaw, partialTicks);
                }
            }
            catch (Throwable throwable2)
            {
                throw new ReportedException(CrashReport.makeCrashReport(throwable2, "Post-rendering entity in world"));
            }

            if (this.debugBoundingBox && !entityIn.isInvisible() && !p_188391_10_ && !Minecraft.getMinecraft().isReducedDebug())
            {
                try
                {
                    this.renderDebugBoundingBox(entityIn, x, y, z, yaw, partialTicks);
                }
                catch (Throwable throwable)
                {
                    throw new ReportedException(CrashReport.makeCrashReport(throwable, "Rendering entity hitbox in world"));
                }
            }
        }
    }
    catch (Throwable throwable3)
    {
        CrashReport crashreport = CrashReport.makeCrashReport(throwable3, "Rendering entity in world");
        CrashReportCategory crashreportcategory = crashreport.makeCategory("Entity being rendered");
        entityIn.addEntityCrashInfo(crashreportcategory);
        CrashReportCategory crashreportcategory1 = crashreport.makeCategory("Renderer details");
        crashreportcategory1.addCrashSection("Assigned renderer", render);
        crashreportcategory1.addCrashSection("Location", CrashReportCategory.getCoordinateInfo(x, y, z));
        crashreportcategory1.addCrashSection("Rotation", Float.valueOf(yaw));
        crashreportcategory1.addCrashSection("Delta", Float.valueOf(partialTicks));
        throw new ReportedException(crashreport);
    }
}
 
开发者ID:F1r3w477,项目名称:CustomWorldGen,代码行数:59,代码来源:RenderManager.java


注:本文中的net.minecraft.entity.Entity.addEntityCrashInfo方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。