Skip to content

Commit

Permalink
Fix GT circuit detection with dual interfaces (#194)
Browse files Browse the repository at this point in the history
* Also check machine if gt5nh

* Spotless apply for branch fixGTBlocking for #194 (#195)

Co-authored-by: GitHub GTNH Actions <>

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
  • Loading branch information
Caedis and github-actions[bot] authored Mar 11, 2024
1 parent 5cc8488 commit 29cb32b
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -338,8 +338,13 @@ private int gtMachineCircuitCheck(InventoryAdaptor ad) {
}

private boolean isGTMachine(Object o) {
return ModAndClassUtil.GT5 && o instanceof TileEntity
&& ((TileEntity) o).getBlockType().getUnlocalizedName().equals("gt.blockmachines");
if (!(ModAndClassUtil.GT5 || ModAndClassUtil.GT5NH)) return false;

if (o instanceof TileEntity te) {
return te.getBlockType().getUnlocalizedName().equals("gt.blockmachines");
}

return false;
}

private boolean isItemConduit(TileEntity te) {
Expand Down

0 comments on commit 29cb32b

Please sign in to comment.