perf: watch/boundary items (TESR models and textures reused, single tile lookups, aura packet length check)

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
This commit is contained in:
layue13andClaude Opus 5.5 committed 2026-10-31 21:41:54 +08:00
1 parent fbc9f7e66f
commit 0fe2dded65
25 files changed
+200 -112

No files matched your search

@@ -12,6 +12,8 @@ import org.lwjgl.opengl.GL11;
public class GUICondensator extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guicondenser.png");
private TileOldCondensator mw;
@@ -23,7 +25,7 @@ public class GUICondensator extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guicondenser.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
int i = this.mw.getProgressScaled(36);
GL11.glPushMatrix();
@@ -12,6 +12,8 @@ import net.minecraft.util.ResourceLocation;
public class GUIDarkGenerator extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guidarkgen.png");
private TileDarkGen mw;
@@ -23,7 +25,7 @@ public class GUIDarkGenerator extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guidarkgen.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
this.drawTexturedModalRect(this.guiLeft + 84, this.guiTop + 44, 192, this.mw.getWorldObj().getMoonPhase() * 8, 8, 8);
this.drawTexturedModalRect(this.guiLeft + 84 - 4, this.guiTop + 44 - 20, 176, LightUtil.getLightValue(this.mw.getWorldObj(), this.mw.xCoord, this.mw.yCoord, this.mw.zCoord) * 16, 16, 16);
@@ -12,6 +12,8 @@ import net.minecraft.util.StatCollector;
public class GUIDarkInfuser extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guidarkinfuser.png");
private TileDarkInfuser mw;
@@ -23,7 +25,7 @@ public class GUIDarkInfuser extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guidarkinfuser.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
int i;
if(this.mw.cookTime > 0) {
@@ -11,6 +11,8 @@ import net.minecraft.util.ResourceLocation;
public class GUIHyperNodeCreator extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guihypernodecreator.png");
private TileHyperNodeCreator mw;
@@ -22,7 +24,7 @@ public class GUIHyperNodeCreator extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guihypernodecreator.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
}
@@ -10,6 +10,8 @@ import net.minecraft.util.ResourceLocation;
public class GUIInfuser extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guiinfuser.png");
private TileInfuser mw;
@@ -21,7 +23,7 @@ public class GUIInfuser extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guiinfuser.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
if(this.mw.cookTime > 0) {
int i = this.mw.getCookProgressScaled(47);
@@ -14,6 +14,8 @@ import net.minecraft.world.World;
public class GUISealGlobe extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guicrystalball.png");
private World world;
private int x;
private int y;
@@ -35,7 +37,7 @@ public class GUISealGlobe extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guicrystalball.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
if(this.dir == EnumRise.UP) {
this.color += 4.210651F;
@@ -10,6 +10,8 @@ import net.minecraft.util.ResourceLocation;
public class GUIThaumicCrystallizer extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guicrystalizer.png");
private TileThaumCrystallizer mw;
@@ -21,7 +23,7 @@ public class GUIThaumicCrystallizer extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guicrystalizer.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
int i = this.mw.getCookProgressScaled(47);
this.drawTexturedModalRect(this.guiLeft + 160, this.guiTop + 105 + 47 - i, 176, 47 - i, 9, i);
@@ -10,6 +10,8 @@ import net.minecraft.util.ResourceLocation;
public class GUIThaumicGenerator extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guigenerator.png");
private TileThaumicGenerator mw;
@@ -21,7 +23,7 @@ public class GUIThaumicGenerator extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guigenerator.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
int i = this.mw.amount * 47 / this.mw.maxAmount;
this.drawTexturedModalRect(this.guiLeft + 47, this.guiTop + 22 + 47 - i, 102, 47 - i, 9, i);
@@ -11,6 +11,8 @@ import net.minecraft.util.ResourceLocation;
public class GUIThaumicRestorer extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guirepairer.png");
private TileThaumicRestorer res;
@@ -22,7 +24,7 @@ public class GUIThaumicRestorer extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guirepairer.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
int i = this.res.tick * 31 / 5;
this.drawTexturedModalRect(this.guiLeft + 135, this.guiTop + 16 + 31 - i, 176, 31 - i, 7, i);
@@ -9,6 +9,8 @@ import net.minecraft.util.ResourceLocation;
public class GUIVoidChest extends GuiContainer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/gui/guivoidchest.png");
private TileVoidChest mw;
@@ -20,7 +22,7 @@ public class GUIVoidChest extends GuiContainer {
}
public void drawGuiContainerBackgroundLayer(float p_146976_1_, int p_146976_2_, int p_146976_3_) {
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/gui/guivoidchest.png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(TEXTURE);
this.drawTexturedModalRect(this.guiLeft, this.guiTop, 0, 0, this.xSize, this.ySize);
}
@@ -58,8 +58,9 @@ public class TileVisTube extends TileThaumcraft implements IMultiBlockPart, ITub
x = this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(fd);
y = this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(fd);
z = this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(fd);
if(this.worldObj.getTileEntity(x, y, z) instanceof ITubeConnectable) {
ITubeConnectable tube = (ITubeConnectable)this.worldObj.getTileEntity(x, y, z);
TileEntity neighbour = this.worldObj.getTileEntity(x, y, z); // read once per side
if(neighbour instanceof ITubeConnectable) {
ITubeConnectable tube = (ITubeConnectable)neighbour;
this.connectivity.put(fd, Boolean.valueOf(tube.canConnect(fd.getOpposite())));
if(((Boolean)this.connectivity.get(fd)).booleanValue()) {
this.connectivityExtended.put(fd, Boolean.valueOf(tube.shouldExtendRenderingForTubes(fd.getOpposite())));
@@ -71,8 +72,8 @@ public class TileVisTube extends TileThaumcraft implements IMultiBlockPart, ITub
this.connectivityExtended.put(fd, Boolean.valueOf(false));
}
if(this.worldObj.getTileEntity(x, y, z) instanceof ITubable) {
ITubable var12 = (ITubable)this.worldObj.getTileEntity(x, y, z);
if(neighbour instanceof ITubable) {
ITubable var12 = (ITubable)neighbour;
if(var12.canConnect(fd.getOpposite()) && !(var12 instanceof TileVisTube)) {
if(var12.canAccept(fd.getOpposite(), MagicType.VIS) && this.ejectVis(MagicType.VIS, var12.acceptVis(MagicType.VIS, this.grid.vis, fd.getOpposite()), fd) > 0) {
;
@@ -95,7 +96,8 @@ public class TileVisTube extends TileThaumcraft implements IMultiBlockPart, ITub
x = this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(fd);
y = this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(fd);
z = this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(fd);
TileVisTube var13 = this.world().getTileEntity(x, y, z) instanceof TileVisTube?(TileVisTube)this.world().getTileEntity(x, y, z):null;
TileEntity neighbour = this.world().getTileEntity(x, y, z);
TileVisTube var13 = neighbour instanceof TileVisTube?(TileVisTube)neighbour:null;
if(var13 != null && var13.canConnect(fd.getOpposite())) {
VisGrid grid0 = this.grid;
VisGrid grid1 = var13.grid;
@@ -2,7 +2,6 @@ package com.pengu.thaumcraft.additions.playnet.packtetmng;
import com.pengu.api.thaumicadditions.enums.EnumAT;
import com.pengu.thaumcraft.additions.utils.hud.HUD;
import cpw.mods.fml.common.FMLLog;
import cpw.mods.fml.common.network.simpleimpl.IMessage;
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
@@ -16,59 +15,68 @@ public class PacketAuraVis implements IMessage, IMessageHandler<PacketAuraVis, I
public void setData(EnumAT[] aspects, int[] amounts) {
this.aspects = aspects;
this.amts = amounts;
this.aspects = aspects;
this.amts = amounts;
}
public IMessage onMessage(PacketAuraVis message, MessageContext ctx) {
try {
FMLLog.info("Received!", new Object[0]);
for(int i = 0; i < Math.min(message.aspects.length, message.amts.length); ++i) {
HUD.currentAspects.aspects.put(Aspect.getAspect(message.aspects[i].getAspect()), Integer.valueOf(message.amts[i]));
}
} catch (Throwable var4) {
;
}
return null;
try {
for(int i = 0; i < Math.min(message.aspects.length, message.amts.length); ++i) {
HUD.currentAspects.aspects.put(Aspect.getAspect(message.aspects[i].getAspect()), Integer.valueOf(message.amts[i]));
}
} catch (Throwable var4) {
;
}
return null;
}
public void fromBytes(ByteBuf buf) {
this.amts = new int[buf.readInt()];
int i;
for(i = 0; i < this.amts.length; ++i) {
this.amts[i] = buf.readInt();
}
this.aspects = new EnumAT[buf.readInt()];
for(i = 0; i < this.aspects.length; ++i) {
this.aspects[i] = EnumAT.getFrom(buf.readInt());
}
this.amts = new int[checkedLength(buf)];
int i;
for(i = 0; i < this.amts.length; ++i) {
this.amts[i] = buf.readInt();
}
this.aspects = new EnumAT[checkedLength(buf)];
for(i = 0; i < this.aspects.length; ++i) {
this.aspects[i] = EnumAT.getFrom(buf.readInt());
}
}
// Each element is one int: a count larger than what is left in the packet is malformed
// (it used to size the array straight from the wire).
private static int checkedLength(ByteBuf buf) {
int n = buf.readInt();
if(n < 0 || n > buf.readableBytes() / 4) {
throw new IllegalArgumentException("bad aura packet length " + n);
}
return n;
}
public void toBytes(ByteBuf buf) {
buf.writeInt(this.amts.length);
int[] var2 = this.amts;
int var3 = var2.length;
int var4;
for(var4 = 0; var4 < var3; ++var4) {
int a = var2[var4];
buf.writeInt(a);
}
buf.writeInt(this.aspects.length);
EnumAT[] var6 = this.aspects;
var3 = var6.length;
for(var4 = 0; var4 < var3; ++var4) {
EnumAT var7 = var6[var4];
buf.writeInt(var7.id);
}
buf.writeInt(this.amts.length);
int[] var2 = this.amts;
int var3 = var2.length;
int var4;
for(var4 = 0; var4 < var3; ++var4) {
int a = var2[var4];
buf.writeInt(a);
}
buf.writeInt(this.aspects.length);
EnumAT[] var6 = this.aspects;
var3 = var6.length;
for(var4 = 0; var4 < var3; ++var4) {
EnumAT var7 = var6[var4];
buf.writeInt(var7.id);
}
}
}
@@ -10,16 +10,19 @@ import org.lwjgl.opengl.GL11;
public class RendererDarkGen extends TileEntitySpecialRenderer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/models/DarkGen.png");
private final ModelDarkGen modelDarkGen = new ModelDarkGen(); // one instance (each new one also compiled fresh display lists)
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float par1float) {
GL11.glPushMatrix();
GL11.glTranslatef((float)x + 0.5F, (float)y + 1.5F, (float)z + 0.5F);
ResourceLocation textures = new ResourceLocation("thaumicadditions", "textures/models/DarkGen.png");
ResourceLocation textures = TEXTURE;
Minecraft.getMinecraft().renderEngine.bindTexture(textures);
GL11.glPushMatrix();
GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
GL11.glPushMatrix();
GL11.glRotatef(0.0F, 0.0F, 1.0F, 0.0F);
(new ModelDarkGen()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, false);
this.modelDarkGen.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, false);
GL11.glPopMatrix();
GL11.glPopMatrix();
GL11.glPopMatrix();
@@ -11,16 +11,20 @@ import org.lwjgl.opengl.GL11;
public class RendererHyperNodeCreator extends TileEntitySpecialRenderer {
private static final ResourceLocation TEXTURE_PRIMALS = new ResourceLocation("thaumicadditions", "textures/models/HyperNodeCreator_primals.png");
private static final ResourceLocation TEXTURE_ALL = new ResourceLocation("thaumicadditions", "textures/models/HyperNodeCreator_all.png");
private final ModelHyperNodeCreator modelHyperNodeCreator = new ModelHyperNodeCreator(); // one instance (each new one also compiled fresh display lists)
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float par1float) {
GL11.glPushMatrix();
GL11.glTranslatef((float)x + 0.5F, (float)y + 1.5F, (float)z + 0.5F);
ResourceLocation textures = new ResourceLocation("thaumicadditions", "textures/models/HyperNodeCreator_" + (((TileHyperNodeCreator)te).primalsOnly?"primals":"all") + ".png");
ResourceLocation textures = ((TileHyperNodeCreator)te).primalsOnly ? TEXTURE_PRIMALS : TEXTURE_ALL;
Minecraft.getMinecraft().renderEngine.bindTexture(textures);
GL11.glPushMatrix();
GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
GL11.glPushMatrix();
GL11.glRotatef(0.0F, 0.0F, 1.0F, 0.0F);
(new ModelHyperNodeCreator()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, ((TileHyperNodeCreator)te).node);
this.modelHyperNodeCreator.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, ((TileHyperNodeCreator)te).node);
GL11.glPopMatrix();
GL11.glPopMatrix();
GL11.glPopMatrix();
@@ -13,15 +13,21 @@ import org.lwjgl.opengl.GL11;
public class RendererInfuser extends TileEntitySpecialRenderer {
private static final ResourceLocation TOP = new ResourceLocation("thaumicadditions", "textures/models/InfuserTop.png");
private static final ResourceLocation TOP_DARK = new ResourceLocation("thaumicadditions", "textures/models/InfuserTopDark.png");
private static final ResourceLocation SYMBOL = new ResourceLocation("thaumicadditions", "textures/models/infusersymbol.png");
private static final ResourceLocation SYMBOL_DARK = new ResourceLocation("thaumicadditions", "textures/models/darkinfusersymbol.png");
private final ModelTileInfuser modelTileInfuser = new ModelTileInfuser(); // one instance (each new one also compiled fresh display lists)
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float par1float) {
GL11.glPushMatrix();
GL11.glTranslatef((float)x + 0.5F, (float)y + 1.5F, (float)z + 0.5F);
Minecraft.getMinecraft().renderEngine.bindTexture(new ResourceLocation("thaumicadditions", "textures/models/InfuserTop" + (te instanceof TileDarkInfuser?"Dark":"") + ".png"));
Minecraft.getMinecraft().renderEngine.bindTexture((te instanceof TileDarkInfuser ? TOP_DARK : TOP));
GL11.glPushMatrix();
GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
GL11.glPushMatrix();
GL11.glRotatef(0.0F, 0.0F, 1.0F, 0.0F);
(new ModelTileInfuser()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, false);
this.modelTileInfuser.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, false);
GL11.glPopMatrix();
GL11.glPopMatrix();
GL11.glPopMatrix();
@@ -33,7 +39,7 @@ public class RendererInfuser extends TileEntitySpecialRenderer {
GL11.glTranslatef((float)x, (float)y + 0.5F - 0.2185F, (float)z);
}
Minecraft.getMinecraft().renderEngine.bindTexture(new ResourceLocation("thaumicadditions", "textures/models/infusersymbol.png"));
Minecraft.getMinecraft().renderEngine.bindTexture(SYMBOL);
if(inf.cookTime > 0) {
GL11.glTranslatef((float)x + 0.5F, (float)y + 0.5F - 0.2185F, (float)z + 0.5F);
GL11.glRotatef((float)Minecraft.getSystemTime() % 3600.0F / 10.0F, 0.0F, 1.0F, 0.0F);
@@ -50,7 +56,7 @@ public class RendererInfuser extends TileEntitySpecialRenderer {
GL11.glTranslatef((float)x, (float)y + 0.5F - 0.2185F, (float)z);
}
Minecraft.getMinecraft().renderEngine.bindTexture(new ResourceLocation("thaumicadditions", "textures/models/darkinfusersymbol.png"));
Minecraft.getMinecraft().renderEngine.bindTexture(SYMBOL_DARK);
if(inf1.cookTime + inf1.cookTimeTaint > 0) {
GL11.glTranslatef((float)x + 0.5F, (float)y + 0.5F - 0.2185F, (float)z + 0.5F);
GL11.glRotatef((float)Minecraft.getSystemTime() % 3600.0F / 10.0F, 0.0F, 1.0F, 0.0F);
@@ -13,10 +13,14 @@ import thaumcraft.client.renderers.item.ItemWandRenderer;
public class RendererInfuserActivator extends TileEntitySpecialRenderer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/models/InfuserActivator.png");
private final ModelInfuserActivator modelInfuserActivator = new ModelInfuserActivator(); // one instance (each new one also compiled fresh display lists)
private final ItemWandRenderer wandRenderer = new ItemWandRenderer();
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float par1float) {
GL11.glPushMatrix();
GL11.glTranslatef((float)x + 0.5F, (float)y + 1.5F, (float)z + 0.5F);
ResourceLocation textures = new ResourceLocation("thaumicadditions", "textures/models/InfuserActivator.png");
ResourceLocation textures = TEXTURE;
GL11.glPushMatrix();
GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
GL11.glPushMatrix();
@@ -28,13 +32,13 @@ public class RendererInfuserActivator extends TileEntitySpecialRenderer {
float rot = te instanceof TileInfuserActivator?(float)((TileInfuserActivator)te).beforeclick:0.0F;
rot = -rot;
GL11.glTranslatef(0.0F, 1.4F + rot / 360.0F, 0.0F);
(new ItemWandRenderer()).renderItem(ItemRenderType.ENTITY, ((TileInfuserActivator)te).wandstack, new Object[0]);
this.wandRenderer.renderItem(ItemRenderType.ENTITY, ((TileInfuserActivator)te).wandstack, new Object[0]);
GL11.glColor3f(1.0F, 1.0F, 1.0F);
GL11.glEnable(2896);
GL11.glPopMatrix();
GL11.glPopMatrix();
Minecraft.getMinecraft().renderEngine.bindTexture(textures);
(new ModelInfuserActivator()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
this.modelInfuserActivator.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
GL11.glPopMatrix();
GL11.glPopMatrix();
GL11.glPopMatrix();
@@ -12,6 +12,10 @@ import org.lwjgl.opengl.GL11;
public class RendererSeal extends TileEntitySpecialRenderer {
private static final ResourceLocation SEAL = new ResourceLocation("thaumicadditions", "textures/models/seal.png");
private static final ResourceLocation SEAL_OVER = new ResourceLocation("thaumicadditions", "textures/models/seal_over.png");
private final ModelSeal modelSeal = new ModelSeal(); // one instance (each new one also compiled fresh display lists)
ResourceLocation f0 = new ResourceLocation("thaumicadditions", "textures/blocks/seal_/s_0.png");
ResourceLocation f1 = new ResourceLocation("thaumicadditions", "textures/blocks/seal_/s_1.png");
ResourceLocation f2 = new ResourceLocation("thaumicadditions", "textures/blocks/seal_/s_2.png");
@@ -38,14 +42,14 @@ public class RendererSeal extends TileEntitySpecialRenderer {
GL11.glTranslatef(1.0F / (ori == 5?256.0F:-256.0F), 2.32F, 0.0F);
}
this.bindTexture(new ResourceLocation("thaumicadditions", "textures/models/seal.png"));
(new ModelSeal()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
this.bindTexture(new ResourceLocation("thaumicadditions", "textures/models/seal_over.png"));
this.bindTexture(SEAL);
this.modelSeal.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
this.bindTexture(SEAL_OVER);
float r0 = (float)(((TileSeal)te).color >> 16 & 255) / 255.0F;
float g0 = (float)(((TileSeal)te).color >> 8 & 255) / 255.0F;
float b0 = (float)(((TileSeal)te).color & 255) / 255.0F;
GL11.glColor3f(r0, g0, b0);
(new ModelSeal()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
this.modelSeal.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
GL11.glPopMatrix();
GL11.glPushMatrix();
float r1;
@@ -58,7 +62,7 @@ public class RendererSeal extends TileEntitySpecialRenderer {
b1 = (float)(((TileSeal)te).f.getType().getColor() & 255) / 255.0F;
GL11.glPushMatrix();
GL11.glColor3f(r1, g1, b1);
(new ModelSeal()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
this.modelSeal.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
GL11.glPopMatrix();
}
@@ -69,7 +73,7 @@ public class RendererSeal extends TileEntitySpecialRenderer {
b1 = (float)(((TileSeal)te).s.getType().getColor() & 255) / 255.0F;
GL11.glPushMatrix();
GL11.glColor3f(r1, g1, b1);
(new ModelSeal()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
this.modelSeal.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
GL11.glPopMatrix();
}
@@ -80,7 +84,7 @@ public class RendererSeal extends TileEntitySpecialRenderer {
b1 = (float)(((TileSeal)te).t.getType().getColor() & 255) / 255.0F;
GL11.glPushMatrix();
GL11.glColor3f(r1, g1, b1);
(new ModelSeal()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
this.modelSeal.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getBlockMetadata() < 6?ForgeDirection.OPPOSITES[te.getBlockMetadata()]:0);
GL11.glPopMatrix();
}
@@ -11,16 +11,19 @@ import thaumcraft.common.tiles.TileJarFillable;
public class RendererSymboller extends TileEntitySpecialRenderer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/models/TileSealSymboller.png");
private final ModelTileSealSymboller modelTileSealSymboller = new ModelTileSealSymboller(); // one instance (each new one also compiled fresh display lists)
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float floatt) {
GL11.glPushMatrix();
GL11.glTranslatef((float)x + 0.5F, (float)y + 1.5F, (float)z + 0.5F);
ResourceLocation textures = new ResourceLocation("thaumicadditions", "textures/models/TileSealSymboller.png");
ResourceLocation textures = TEXTURE;
Minecraft.getMinecraft().renderEngine.bindTexture(textures);
GL11.glPushMatrix();
GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
GL11.glPushMatrix();
GL11.glRotatef(0.0F, 0.0F, 1.0F, 0.0F);
(new ModelTileSealSymboller()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getWorldObj().getTileEntity(te.xCoord, te.yCoord + 1, te.zCoord) != null && te.getWorldObj().getTileEntity(te.xCoord, te.yCoord + 1, te.zCoord) instanceof TileJarFillable);
this.modelTileSealSymboller.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, te.getWorldObj().getTileEntity(te.xCoord, te.yCoord + 1, te.zCoord) instanceof TileJarFillable);
GL11.glPopMatrix();
GL11.glPopMatrix();
GL11.glPopMatrix();
@@ -14,10 +14,18 @@ import org.lwjgl.opengl.GL11;
public class RendererTankBasic extends TileEntitySpecialRenderer {
private static final ResourceLocation[] LIQUID_FRAMES = new ResourceLocation[16];
static {
for(int i = 0; i < LIQUID_FRAMES.length; ++i) {
LIQUID_FRAMES[i] = new ResourceLocation("thaumicadditions", "textures/models/TankLiquid/" + i + ".png");
}
}
private final ModelTankFill modelTankFill = new ModelTankFill(); // one instance (each new one also compiled fresh display lists)
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float floatt) {
GL11.glPushMatrix();
GL11.glTranslated(x + 0.5D, y + 0.001D, z + 0.5D);
Minecraft.getMinecraft().renderEngine.bindTexture(new ResourceLocation("thaumicadditions", "textures/models/TankLiquid/" + (int)(Minecraft.getSystemTime() % 1600L / 100L) + ".png"));
Minecraft.getMinecraft().renderEngine.bindTexture(LIQUID_FRAMES[(int)(Minecraft.getSystemTime() % 1600L / 100L)]);
GL11.glPushMatrix();
GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
GL11.glPushMatrix();
@@ -29,7 +37,7 @@ public class RendererTankBasic extends TileEntitySpecialRenderer {
Color mesh = ColorUtil.blend(new Color(VisGrid.visColor), new Color(VisGrid.taintColor));
GL11.glColor3f((float)mesh.getRed() / 255.0F, (float)mesh.getGreen() / 255.0F, (float)mesh.getBlue() / 255.0F);
if(storedTot > 0.0F) {
(new ModelTankFill()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
this.modelTankFill.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
}
}
@@ -2,7 +2,6 @@ package com.pengu.thaumcraft.additions.renderer;
import com.pengu.thaumcraft.additions.init.All;
import com.pengu.thaumcraft.additions.tileentity.TileThaumCrystallizer;
import java.awt.Color;
import java.util.Random;
import net.minecraft.client.Minecraft;
import net.minecraft.client.entity.EntityClientPlayerMP;
@@ -18,6 +17,8 @@ import thaumcraft.common.config.ConfigItems;
public class RendererThaumicCrystallizer extends TileEntitySpecialRenderer {
private final ModelCrystal crystal = new ModelCrystal(); // one instance (each new one also compiled a fresh display list)
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float par1float) {
if(te instanceof TileThaumCrystallizer) {
TileThaumCrystallizer t = (TileThaumCrystallizer)te;
@@ -200,10 +201,9 @@ public class RendererThaumicCrystallizer extends TileEntitySpecialRenderer {
private void drawCrystal(int ori, float x, float y, float z, float a1, float a2, Random rand, int color, float id) {
EntityClientPlayerMP p = Minecraft.getMinecraft().thePlayer;
float shade = MathHelper.sin((float)p.ticksExisted % (9.0E16F + id * 16.0F)) * 0.025F + 0.825F;
Color c = new Color(color);
float r = (float)c.getRed() / 220.0F;
float g = (float)c.getGreen() / 220.0F;
float b = (float)c.getBlue() / 220.0F;
float r = (float)(color >> 16 & 255) / 220.0F;
float g = (float)(color >> 8 & 255) / 220.0F;
float b = (float)(color & 255) / 220.0F;
GL11.glPushMatrix();
GL11.glEnable(2977);
GL11.glEnable(3042);
@@ -218,7 +218,7 @@ public class RendererThaumicCrystallizer extends TileEntitySpecialRenderer {
int var21 = var19 / 65536;
OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, (float)var20 / 1.0F, (float)var21 / 1.0F);
GL11.glColor4f(r, g, b, 1.0F);
(new ModelCrystal()).render();
this.crystal.render();
GL11.glScalef(1.0F, 1.0F, 1.0F);
GL11.glDisable('\u803a');
GL11.glDisable(3042);
@@ -11,16 +11,19 @@ import org.lwjgl.opengl.GL11;
public class RendererThaumicGenerator extends TileEntitySpecialRenderer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/models/ThaumicGenerator.png");
private final ModelThaumicGenerator modelThaumicGenerator = new ModelThaumicGenerator(); // one instance (each new one also compiled fresh display lists)
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float par1float) {
GL11.glPushMatrix();
GL11.glTranslatef((float)x + 0.5F, (float)y + 1.5F, (float)z + 0.5F);
ResourceLocation textures = new ResourceLocation("thaumicadditions", "textures/models/ThaumicGenerator.png");
ResourceLocation textures = TEXTURE;
Minecraft.getMinecraft().renderEngine.bindTexture(textures);
GL11.glPushMatrix();
GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
GL11.glPushMatrix();
GL11.glRotatef(0.0F, 0.0F, 1.0F, 0.0F);
(new ModelThaumicGenerator()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, ((TileThaumicGenerator)te).emitPowerFromSidesListedHere);
this.modelThaumicGenerator.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F, ((TileThaumicGenerator)te).emitPowerFromSidesListedHere);
GL11.glPopMatrix();
GL11.glPopMatrix();
GL11.glPopMatrix();
@@ -10,16 +10,19 @@ import org.lwjgl.opengl.GL11;
public class RendererThaumicRestorer extends TileEntitySpecialRenderer {
private static final ResourceLocation TEXTURE = new ResourceLocation("thaumicadditions", "textures/models/ThaumicRestorer.png");
private final ModelThaumicRestorer modelThaumicRestorer = new ModelThaumicRestorer(); // one instance (each new one also compiled fresh display lists)
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float par1float) {
GL11.glPushMatrix();
GL11.glTranslatef((float)x + 0.5F, (float)y + 1.5F, (float)z + 0.5F);
Minecraft.getMinecraft().renderEngine.bindTexture(new ResourceLocation("thaumicadditions", "textures/models/ThaumicRestorer.png"));
Minecraft.getMinecraft().renderEngine.bindTexture(TEXTURE);
GL11.glPushMatrix();
GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
GL11.glPushMatrix();
GL11.glRotatef(0.0F, 0.0F, 1.0F, 0.0F);
GL11.glDisable(2896);
(new ModelThaumicRestorer()).render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
this.modelThaumicRestorer.render((Entity)null, 0.0F, 0.0F, -0.1F, 0.0F, 0.0F, 0.0625F);
GL11.glEnable(2896);
GL11.glPopMatrix();
GL11.glPopMatrix();
@@ -1,7 +1,6 @@
package com.pengu.thaumcraft.additions.tileentity;
import com.pengu.thaumcraft.additions.tileentity.TileCreativeNode;
import java.util.Calendar;
import java.util.Random;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.Tessellator;
@@ -14,13 +13,19 @@ import org.lwjgl.opengl.GL11;
public class TileRendererCreativeNode extends TileEntitySpecialRenderer {
private static final ResourceLocation[] AURA = new ResourceLocation[]{new ResourceLocation("thaumicadditions", "textures/models/aura_1.png"), new ResourceLocation("thaumicadditions", "textures/models/aura_2.png")};
// Re-seeded per node each frame: setSeed gives the same sequence as new Random(seed)
private final Random rnd = new Random();
public void renderTileEntityAt(TileEntity te, double x, double y, double z, float floay) {
boolean wearsRevealer = false;
ItemStack helmet = Minecraft.getMinecraft().thePlayer.inventory.armorItemInSlot(0);
if(te instanceof TileCreativeNode) {
TileCreativeNode tcn = (TileCreativeNode)te;
Random rnd = new Random((long)(tcn.getId() + "" + tcn.yCoord).hashCode() ^ 256L);
float rot = (float)(Calendar.getInstance().get(14) + rnd.nextInt(1000)) % 1000.0F;
Random rnd = this.rnd;
rnd.setSeed((long)(tcn.getId() + "" + tcn.yCoord).hashCode() ^ 256L);
// millisecond of the current second, as Calendar.getInstance().get(MILLISECOND) gave
float rot = (float)((int)(System.currentTimeMillis() % 1000L) + rnd.nextInt(1000)) % 1000.0F;
boolean prevBlend = GL11.glIsEnabled(3042);
if(!prevBlend) {
GL11.glEnable(3042);
@@ -31,7 +36,7 @@ public class TileRendererCreativeNode extends TileEntitySpecialRenderer {
GL11.glTranslated(x + 0.5D, y + 0.15000000596046448D, z + 0.5D);
GL11.glEnable('\u803a');
GL11.glScalef(1.5F, 1.5F, 1.5F);
Minecraft.getMinecraft().getTextureManager().bindTexture(new ResourceLocation("thaumicadditions", "textures/models/aura_" + (rnd.nextInt(2) + 1) + ".png"));
Minecraft.getMinecraft().getTextureManager().bindTexture(AURA[rnd.nextInt(2)]);
Tessellator p_77026_1_ = Tessellator.instance;
float f = 0.0F;
float f1 = 1.0F;
@@ -10,11 +10,26 @@ import com.pengu.util.ForgeDirectionHelper;
import cpw.mods.fml.common.Loader;
import java.util.ArrayList;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraftforge.common.util.ForgeDirection;
import thaumcraft.api.TileThaumcraft;
public class TileThaumicGenerator extends TileThaumcraft implements ITubable {
private static final ForgeDirection[] DIRS = new ForgeDirection[]{ForgeDirection.UP, ForgeDirection.DOWN, ForgeDirection.EAST, ForgeDirection.WEST, ForgeDirection.SOUTH, ForgeDirection.NORTH};
private static final boolean BOTANIA_LOADED = Loader.isModLoaded("Botania");
private static Botania botania;
// Botania bridge is stateless: one instance, created only when Botania is loaded
private static Botania botania() {
if(botania == null) {
botania = new Botania();
}
return botania;
}
public int amount = 0;
public int maxAmount = 640;
public DirectionCombo emitPowerFromSidesListedHere;
@@ -25,7 +40,7 @@ public class TileThaumicGenerator extends TileThaumcraft implements ITubable {
}
public void updateEntity() {
ForgeDirection[] dirs = new ForgeDirection[]{ForgeDirection.UP, ForgeDirection.DOWN, ForgeDirection.EAST, ForgeDirection.WEST, ForgeDirection.SOUTH, ForgeDirection.NORTH};
ForgeDirection[] dirs = DIRS;
this.maxAmount = 640;
ArrayList fd = new ArrayList();
int i;
@@ -59,31 +74,31 @@ public class TileThaumicGenerator extends TileThaumcraft implements ITubable {
if(this.amount > 1) {
for(i = 0; i < dirs.length; ++i) {
if(this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i])) != null) {
if(this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i])) instanceof IRJReceiver) {
// one tile lookup per side (it was read up to nine times)
TileEntity te = this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i]));
if(te != null) {
if(te instanceof IRJReceiver) {
fd.add(dirs[i]);
}
if(this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i])) instanceof IEnergyReceiver) {
if(te instanceof IEnergyReceiver) {
fd.add(dirs[i]);
}
if(Loader.isModLoaded("Botania") && (new Botania()).canConnect(this.worldObj, this.xCoord, this.yCoord, this.zCoord, dirs[i])) {
if(BOTANIA_LOADED && botania().canConnect(this.worldObj, this.xCoord, this.yCoord, this.zCoord, dirs[i])) {
fd.add(dirs[i]);
}
}
if(this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i])) != null) {
if(this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i])) instanceof IRJReceiver) {
this.amount -= ((IRJReceiver)this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i]))).receiveRJ(dirs[i], 2000, false) / 1000;
if(te instanceof IRJReceiver) {
this.amount -= ((IRJReceiver)te).receiveRJ(dirs[i], 2000, false) / 1000;
}
if(this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i])) instanceof IEnergyReceiver) {
this.amount -= ((IEnergyReceiver)this.worldObj.getTileEntity(this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(dirs[i]), this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(dirs[i]), this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(dirs[i]))).receiveEnergy(dirs[i], 2000, false) / 1000;
if(te instanceof IEnergyReceiver) {
this.amount -= ((IEnergyReceiver)te).receiveEnergy(dirs[i], 2000, false) / 1000;
}
if(Loader.isModLoaded("Botania")) {
this.amount -= (new Botania()).handleManaGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, dirs[i], 2000) / 100;
if(BOTANIA_LOADED) {
this.amount -= botania().handleManaGen(this.worldObj, this.xCoord, this.yCoord, this.zCoord, dirs[i], 2000) / 100;
}
}
}
@@ -24,8 +24,8 @@ public class TileTileBooster extends TileThaumcraft {
int x = this.xCoord + ForgeDirectionHelper.getForgeDirectionXApplyed(fd);
int y = this.yCoord + ForgeDirectionHelper.getForgeDirectionYApplyed(fd);
int z = this.zCoord + ForgeDirectionHelper.getForgeDirectionZApplyed(fd);
TileEntity te = this.worldObj.getTileEntity(x, y, z) != null && !(this.worldObj.getTileEntity(x, y, z) instanceof TileTileBooster)?this.worldObj.getTileEntity(x, y, z):null;
if(te != null && te.canUpdate()) {
TileEntity te = this.worldObj.getTileEntity(x, y, z); // read once (was up to three times)
if(te != null && !(te instanceof TileTileBooster) && te.canUpdate()) {
for(int i = 0; i < this.speed; ++i) {
te.updateEntity();
}