mirror of
https://github.com/Creators-of-Create/Create.git
synced 2024-11-10 20:11:35 +01:00
Belting these bugs.
- Belts now always render their items again. - Items on belts on contraptions are now at least somewhat lit.
This commit is contained in:
parent
25b4e4d5be
commit
e930e62436
3 changed files with 7 additions and 3 deletions
|
@ -225,6 +225,7 @@ public abstract class KineticTileEntity extends SmartTileEntity
|
|||
boolean overStressedBefore = overStressed;
|
||||
clearKineticInformation();
|
||||
|
||||
cachedBoundingBox = null;
|
||||
// DO NOT READ kinetic information when placed after movement
|
||||
if (wasMoved) {
|
||||
super.read(compound, clientPacket);
|
||||
|
|
|
@ -20,6 +20,7 @@ import com.simibubi.create.foundation.utility.AnimationTickHolder;
|
|||
import com.simibubi.create.foundation.utility.Iterate;
|
||||
import com.simibubi.create.foundation.utility.MatrixStacker;
|
||||
|
||||
import com.simibubi.create.foundation.utility.worldWrappers.WrappedWorld;
|
||||
import net.minecraft.block.BlockState;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.renderer.IRenderTypeBuffer;
|
||||
|
@ -45,7 +46,7 @@ public class BeltRenderer extends SafeTileEntityRenderer<BeltTileEntity> {
|
|||
|
||||
@Override
|
||||
public boolean isGlobalRenderer(BeltTileEntity te) {
|
||||
return BeltBlock.canTransportObjects(te.getBlockState());
|
||||
return te.isController();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -189,6 +190,8 @@ public class BeltRenderer extends SafeTileEntityRenderer<BeltTileEntity> {
|
|||
boolean slopeAlongX = beltFacing
|
||||
.getAxis() == Axis.X;
|
||||
|
||||
boolean onContraption = te.getWorld() instanceof WrappedWorld;
|
||||
|
||||
for (TransportedItemStack transported : te.getInventory()
|
||||
.getTransportedItems()) {
|
||||
ms.push();
|
||||
|
@ -203,7 +206,7 @@ public class BeltRenderer extends SafeTileEntityRenderer<BeltTileEntity> {
|
|||
sideOffset = transported.sideOffset;
|
||||
}
|
||||
|
||||
int stackLight = getPackedLight(te, offset);
|
||||
int stackLight = onContraption ? light : getPackedLight(te, offset);
|
||||
|
||||
if (offset < .5)
|
||||
verticalMovement = 0;
|
||||
|
|
|
@ -521,7 +521,7 @@ public class BeltTileEntity extends KineticTileEntity {
|
|||
|
||||
@Override
|
||||
public boolean shouldRenderAsTE() {
|
||||
return BeltBlock.canTransportObjects(getBlockState());
|
||||
return isController();
|
||||
}
|
||||
|
||||
private void updateLight() {
|
||||
|
|
Loading…
Reference in a new issue