1
0
Fork 0

te cleanup

This commit is contained in:
Sen 2025-08-12 20:02:43 +02:00
parent bed1537d9a
commit 96674df391
Signed by: sen
GPG key ID: 3AC50A6F47D1B722
25 changed files with 246 additions and 384 deletions

View file

@ -30,7 +30,7 @@ public class GuiDevice extends GuiContainer {
public void updateScreen() {
super.updateScreen();
this.header.setText(this.tile.getStatus().color + this.tile.getBlockType().getDisplay());
this.header.setText(this.tile.getStatus().color + this.tile.getBlock().getDisplay());
this.desc.setText(this.tile.formatDisplay((ContainerTile)this.inventorySlots));
if(this.progress != null) {
this.progress.setText(this.tile.getTotal() <= 0 || this.tile.getProgress() < 0 ? "" : String.format("%d/%d (%.1f %%)",

View file

@ -1200,7 +1200,7 @@ public class ClientPlayer implements IClientPlayer
if (!(tileentity instanceof TileEntitySign))
{
tileentity = new TileEntitySign();
tileentity.setWorldObj(this.world);
tileentity.setWorld(this.world);
tileentity.setPos(packetIn.getSignPosition());
}
@ -1262,7 +1262,7 @@ public class ClientPlayer implements IClientPlayer
NetHandler.checkThread(packet, this, this.gm, this.world);
if(this.gm.world.isBlockLoaded(packet.getPos())) {
TileEntity te = this.gm.world.getTileEntity(packet.getPos());
if(te != null && packet.getType() == te.getBlockType())
if(te != null && packet.getType() == te.getBlock())
te.readTags(packet.getTag());
}
}

View file

@ -67,7 +67,7 @@ public class RegionRenderCache implements IWorldAccess
{
int i = (pos.getX() >> 4) - this.xPos;
int j = (pos.getZ() >> 4) - this.zPos;
return this.chunks[i][j].getTileEntity(pos, TileEntity.EnumCreateEntityType.QUEUED);
return this.chunks[i][j].getTileEntity(pos, TileEntity.CreateMode.QUEUED);
}
public int getCombinedLight(BlockPos pos, int lightValue)

View file

@ -80,9 +80,9 @@ public class DisplayRenderer extends ElementRenderer<TileEntityDisplay> {
}
public void renderElements(TileEntityDisplay te, double x, double y, double z, float partialTicks) {
Block block = te.getBlockType();
Block block = te.getBlock();
State state = te.getBlockState();
State state = te.getState();
Facing dir = state.getBlock() instanceof BlockDisplay ? state.getValue(BlockDisplay.FACING) : Facing.SOUTH;
float rot = 0.0F;
if(dir == Facing.NORTH)

View file

@ -17,7 +17,7 @@ public class SignRenderer extends ElementRenderer<TileEntitySign>
GL11.glPushMatrix();
float f = 0.6666667F;
State state = te.getBlockState();
State state = te.getState();
if (state.getBlock() instanceof BlockStandingSign)
{
GL11.glTranslatef((float)x + 0.5F, (float)y + 0.75F * f, (float)z + 0.5F);

View file

@ -127,7 +127,7 @@ public class ChunkClient extends Chunk {
this.genHeights();
for(TileEntity tile : this.tiles.values()) {
tile.updateContainingBlockInfo();
tile.resetBlock();
}
}

View file

@ -94,7 +94,7 @@ public class ChunkEmpty extends ChunkClient {
return pos.getY() > this.liquidY;
}
public TileEntity getTileEntity(BlockPos pos, TileEntity.EnumCreateEntityType type) {
public TileEntity getTileEntity(BlockPos pos, TileEntity.CreateMode type) {
return null;
}