Skip to content

Commit

Permalink
Don't suppress Network Tool behaviour for storage monitor on non-fron…
Browse files Browse the repository at this point in the history
…t faces
  • Loading branch information
62832 committed Jun 17, 2024
1 parent 5f5dbf3 commit 4210c2d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,6 @@ public boolean isLocked() {

@Override
public boolean showNetworkInfo(UseOnContext context) {
return false;
return context.getClickedFace() != getFront();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,11 @@ public final class MonitorDataProvider implements BodyProvider<StorageMonitorBlo
@Override
public void buildTooltip(StorageMonitorBlockEntity monitor, TooltipContext context, TooltipBuilder tooltip) {
var displayed = monitor.getDisplayed();
var isLocked = monitor.isLocked();

if (displayed != null) {
tooltip.addLine(InGameTooltip.Showing.text().append(": ").append(displayed.getDisplayName()));
}

tooltip.addLine(isLocked ? InGameTooltip.Locked.text() : InGameTooltip.Unlocked.text());
tooltip.addLine(monitor.isLocked() ? InGameTooltip.Locked.text() : InGameTooltip.Unlocked.text());
}
}

0 comments on commit 4210c2d

Please sign in to comment.