Skip to content

Commit 1103b95

Browse files
committed
replace left over deprecated parseMaterial calls
1 parent 6be25ca commit 1103b95

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

AnarchyExploitFixesLegacy/src/main/java/me/xginko/aef/modules/chunklimits/BlockLimit.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ public BlockLimit() {
133133
Map<String, Object> compatible = new TreeMap<>();
134134
for (Map.Entry<XMaterial, Integer> entry : universal.entrySet()) {
135135
if (entry.getKey().isSupported()) {
136-
compatible.put(entry.getKey().parseMaterial().name(), entry.getValue());
136+
compatible.put(entry.getKey().get().name(), entry.getValue());
137137
}
138138
}
139139

shared/src/main/java/me/xginko/aef/utils/ChunkUtil.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,9 @@ public static boolean isEntitiesLoaded(Chunk chunk) {
4949
public static void createBedrockLayer(Chunk chunk, int y) {
5050
for (int x = 0; x < 16; x++) {
5151
for (int z = 0; z < 16; z++) {
52-
if (chunk.getBlock(x, y, z).getType() != XMaterial.BEDROCK.parseMaterial()) {
52+
if (chunk.getBlock(x, y, z).getType() != XMaterial.BEDROCK.get()) {
5353
// prevent physics to avoid loading nearby chunks which causes infinite chunk loading loops
54-
chunk.getBlock(x, y, z).setType(XMaterial.BEDROCK.parseMaterial(), false);
54+
chunk.getBlock(x, y, z).setType(XMaterial.BEDROCK.get(), false);
5555
}
5656
}
5757
}

shared/src/main/java/me/xginko/aef/utils/EntityUtil.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ public static void disableMapPositionCursor(@NotNull ItemFrame itemFrame) {
5252

5353
ItemStack itemInsideFrame = itemFrame.getItem();
5454
if (itemInsideFrame == null) return; // Shouldn't be null but just in case
55-
if (itemInsideFrame.getType() != XMaterial.MAP.parseMaterial()
56-
&& itemInsideFrame.getType() != XMaterial.FILLED_MAP.parseMaterial()) return;
55+
if (itemInsideFrame.getType() != XMaterial.MAP.get()
56+
&& itemInsideFrame.getType() != XMaterial.FILLED_MAP.get()) return;
5757
if (!itemInsideFrame.hasItemMeta()) return;
5858

5959
MapMeta mapMeta = (MapMeta) itemInsideFrame.getItemMeta();

0 commit comments

Comments
 (0)