Skip to content

Commit

Permalink
Update matchers with 1.21 blocks
Browse files Browse the repository at this point in the history
  • Loading branch information
pop4959 committed Sep 2, 2024
1 parent 111d7c7 commit 84b0e90
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/main/java/com/griefcraft/util/matchers/DoorMatcher.java
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,24 @@ public class DoorMatcher implements ProtectionFinder.Matcher {
WOODEN_TRAP_DOORS.addAll(EnumSet.of(Material.BAMBOO_TRAPDOOR, Material.CHERRY_TRAPDOOR));
PRESSURE_PLATES.addAll(EnumSet.of(Material.BAMBOO_PRESSURE_PLATE, Material.CHERRY_PRESSURE_PLATE));
}
if (VersionUtil.getMinorVersion() > 20) {
PROTECTABLES_DOORS.addAll(EnumSet.of(Material.COPPER_DOOR, Material.EXPOSED_COPPER_DOOR,
Material.OXIDIZED_COPPER_DOOR, Material.WAXED_COPPER_DOOR, Material.WEATHERED_COPPER_DOOR,
Material.WAXED_EXPOSED_COPPER_DOOR, Material.WAXED_OXIDIZED_COPPER_DOOR,
Material.WAXED_WEATHERED_COPPER_DOOR));
WOODEN_DOORS.addAll(EnumSet.of(Material.COPPER_DOOR, Material.EXPOSED_COPPER_DOOR,
Material.OXIDIZED_COPPER_DOOR, Material.WAXED_COPPER_DOOR, Material.WEATHERED_COPPER_DOOR,
Material.WAXED_EXPOSED_COPPER_DOOR, Material.WAXED_OXIDIZED_COPPER_DOOR,
Material.WAXED_WEATHERED_COPPER_DOOR));
TRAP_DOORS.addAll(EnumSet.of(Material.COPPER_TRAPDOOR, Material.EXPOSED_COPPER_TRAPDOOR,
Material.OXIDIZED_COPPER_TRAPDOOR, Material.WAXED_COPPER_TRAPDOOR,
Material.WEATHERED_COPPER_TRAPDOOR, Material.WAXED_EXPOSED_COPPER_TRAPDOOR,
Material.WAXED_OXIDIZED_COPPER_TRAPDOOR, Material.WAXED_WEATHERED_COPPER_TRAPDOOR));
WOODEN_TRAP_DOORS.addAll(EnumSet.of(Material.COPPER_TRAPDOOR, Material.EXPOSED_COPPER_TRAPDOOR,
Material.OXIDIZED_COPPER_TRAPDOOR, Material.WAXED_COPPER_TRAPDOOR,
Material.WEATHERED_COPPER_TRAPDOOR, Material.WAXED_EXPOSED_COPPER_TRAPDOOR,
Material.WAXED_OXIDIZED_COPPER_TRAPDOOR, Material.WAXED_WEATHERED_COPPER_TRAPDOOR));
}
}

public boolean matches(ProtectionFinder finder) {
Expand Down
32 changes: 32 additions & 0 deletions src/main/resources/config/core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,22 @@ protections:
enabled: true
cherry_door:
enabled: true
copper_door:
enabled: true
exposed_copper_door:
enabled: true
oxidized_copper_door:
enabled: true
weathered_copper_door:
enabled: true
waxed_copper_door:
enabled: true
waxed_exposed_copper_door:
enabled: true
waxed_oxidized_copper_door:
enabled: true
waxed_weathered_copper_door:
enabled: true
iron_trapdoor:
enabled: true
oak_trapdoor:
Expand All @@ -334,6 +350,22 @@ protections:
enabled: true
cherry_trapdoor:
enabled: true
copper_trapdoor:
enabled: true
exposed_copper_trapdoor:
enabled: true
oxidized_copper_trapdoor:
enabled: true
weathered_copper_trapdoor:
enabled: true
waxed_copper_trapdoor:
enabled: true
waxed_exposed_copper_trapdoor:
enabled: true
waxed_oxidized_copper_trapdoor:
enabled: true
waxed_weathered_copper_trapdoor:
enabled: true
oak_fence_gate:
enabled: true
spruce_fence_gate:
Expand Down

0 comments on commit 84b0e90

Please sign in to comment.