Down to less than 100 errors
This commit is contained in:
@@ -252,6 +252,10 @@ public class Block extends UnlockableContent{
|
||||
return sum;
|
||||
}
|
||||
|
||||
public TextureRegion getDisplayIcon(Tile tile){
|
||||
return tile.entity == null ? icon(Cicon.medium) : tile.entity.getDisplayIcon();
|
||||
}
|
||||
|
||||
public String getDisplayName(Tile tile){
|
||||
return tile.entity == null ? localizedName : tile.entity.getDisplayName();
|
||||
}
|
||||
|
||||
@@ -89,7 +89,7 @@ public class Build{
|
||||
}
|
||||
|
||||
if(type.isMultiblock()){
|
||||
if(type.canReplace(tile.block()) && tile.block().size == type.size && type.canPlaceOn(tile) && tile.interactable(team)){
|
||||
if(type.canReplace(tile.block()) && tile.size == type.size && type.canPlaceOn() && tile.interactable(team)){
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -121,7 +121,7 @@ public class Build{
|
||||
&& tile.floor().placeableOn
|
||||
&& ((type.canReplace(tile.block())
|
||||
&& !(type == tile.block() && rotation == tile.rotation() && type.rotate)) || tile.block().alwaysReplace || tile.block() == Blocks.air)
|
||||
&& tile.block().isMultiblock() == type.isMultiblock() && type.canPlaceOn(tile);
|
||||
&& tile.isMultiblock() == type.isMultiblock() && type.canPlaceOn();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -150,6 +150,6 @@ public class Build{
|
||||
/** Returns whether the tile at this position is breakable by this team */
|
||||
public static boolean validBreak(Team team, int x, int y){
|
||||
Tile tile = world.tile(x, y);
|
||||
return tile != null && tile.block().canBreak(tile) && tile.breakable() && tile.interactable(team);
|
||||
return tile != null && tile.canBreak() && tile.breakable() && tile.interactable(team);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,7 +22,6 @@ public class CachedTile extends Tile{
|
||||
@Override
|
||||
protected void preChanged(){
|
||||
//this basically overrides the old tile code and doesn't remove from proximity
|
||||
team = 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -37,7 +37,8 @@ public class ConsumeItems extends Consume{
|
||||
@Override
|
||||
public void build(Tilec tile, Table table){
|
||||
for(ItemStack stack : items){
|
||||
table.add(new ReqImage(new ItemImage(stack.item.icon(Cicon.medium), stack.amount), () -> tile.entity != null && tile.entity.items() != null && tile.entity.items().has(stack.item, stack.amount))).size(8 * 4).padRight(5);
|
||||
table.add(new ReqImage(new ItemImage(stack.item.icon(Cicon.medium), stack.amount),
|
||||
() -> tile.items() != null && tile.items().has(stack.item, stack.amount))).size(8 * 4).padRight(5);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user