Skip to content

Commit

Permalink
fix: closes #995 #996
Browse files Browse the repository at this point in the history
  • Loading branch information
StarWishsama committed Jan 15, 2025
1 parent bf88afc commit ba3e0f1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public class ProgrammableAndroid extends SlimefunItem
private static final List<BlockFace> POSSIBLE_ROTATIONS =
Arrays.asList(BlockFace.NORTH, BlockFace.EAST, BlockFace.SOUTH, BlockFace.WEST);
private static final int[] BORDER = {
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 18, 24, 25, 26, 27, 33, 35, 36, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 18, 24, 26, 27, 33, 35, 36, 42, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53
};
private static final int[] OUTPUT_BORDER = {10, 11, 12, 13, 14, 19, 23, 28, 32, 37, 38, 39, 40, 41};
private static final String DEFAULT_SCRIPT = "START-TURN_LEFT-REPEAT";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,9 @@ public void onBlockPlace(BlockPlaceEvent e) {
if (sfItem != null && !(sfItem instanceof NotPlaceable)) {
// Fixes #994, should check placed block is equals to item material or not.
if (item.getType() != e.getBlock().getType()) {
return;
if (item.getType() != e.getBlock().getBlockData().getPlacementMaterial()) {
return;
}
}

if (!sfItem.canUse(e.getPlayer(), true)) {
Expand Down

0 comments on commit ba3e0f1

Please sign in to comment.