Skip to content

Commit

Permalink
Thou shalt not change things after testing them.
Browse files Browse the repository at this point in the history
  • Loading branch information
fnuecke committed Jan 23, 2022
1 parent 9d73df1 commit c96e52a
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public void handleNeighborChanged(final BlockPos pos) {
return;
}

final HashSet<BlockEntry> newDevices = collectDevices(level, pos, direction.getOpposite());
final HashSet<BlockEntry> newDevices = collectDevices(level, pos, direction);

final int index = direction.get3DDataValue();
setEntriesForGroup(index, newDevices);
Expand Down Expand Up @@ -127,7 +127,7 @@ protected boolean canDetectDevicesTowards(@Nullable final Direction direction) {
protected HashSet<BlockEntry> collectDevices(final Level level, final BlockPos pos, @Nullable final Direction direction) {
final HashSet<BlockEntry> entries = new HashSet<>();
if (canDetectDevicesTowards(direction)) {
final BlockDeviceQuery query = Devices.makeQuery(level, pos, direction);
final BlockDeviceQuery query = Devices.makeQuery(level, pos, direction != null ? direction.getOpposite() : null);
for (final Invalidatable<BlockDeviceInfo> deviceInfo : Devices.getDevices(query)) {
if (deviceInfo.isPresent()) {
entries.add(new BlockEntry(deviceInfo, pos));
Expand Down

0 comments on commit c96e52a

Please sign in to comment.