Allow sideloading the unloader

Main reason for blendbits > 1 & 2
This commit is contained in:
Patrick 'Quezler' Mounier
2020-02-10 12:38:48 +01:00
parent 562fa07755
commit 2bd7c92b9e

View File

@@ -138,9 +138,14 @@ public class CraterConveyor extends Block implements Autotiler{
CraterConveyorEntity entity = tile.ent();
int[] bits = buildBlending(tile, tile.rotation(), null, true);
final boolean[] upstream = {false};
upstream(tile, t -> {
if(t.block() instanceof CraterConveyor) upstream[0] = true;
});
entity.blendbit2 = 0;
if(bits[0] == 0 && blends(tile, tile.rotation(), 0) && !blends(tile, tile.rotation(), 2)) entity.blendbit2 = 5; // a 0 that faces into a crater conveyor with none behind it
if(bits[0] == 0 && !blends(tile, tile.rotation(), 0) && blends(tile, tile.rotation(), 2)) entity.blendbit2 = 6; // a 0 that faces into none with a crater conveyor behind it
if(upstream[0] && !blends(tile, tile.rotation(), 0)) entity.blendbit2 = 6; // a 0 that faces into none with a crater conveyor behind it
entity.blendbit1 = bits[0];
entity.blendsclx = bits[1];