Remove try/catch from BlockTranslator and ItemTranslator

This commit is contained in:
DoctorMacc 2020-06-26 11:15:21 -04:00
parent e60f47f65d
commit 54f6fada12
2 changed files with 115 additions and 126 deletions

View file

@ -100,7 +100,6 @@ public class ItemRegistry {
int itemIndex = 0; int itemIndex = 0;
Iterator<Map.Entry<String, JsonNode>> iterator = items.fields(); Iterator<Map.Entry<String, JsonNode>> iterator = items.fields();
while (iterator.hasNext()) { while (iterator.hasNext()) {
try {
Map.Entry<String, JsonNode> entry = iterator.next(); Map.Entry<String, JsonNode> entry = iterator.next();
if (entry.getValue().has("tool_type")) { if (entry.getValue().has("tool_type")) {
if (entry.getValue().has("tool_tier")) { if (entry.getValue().has("tool_tier")) {
@ -132,10 +131,6 @@ public class ItemRegistry {
} }
itemIndex++; itemIndex++;
} catch (Exception e) {
System.out.println("Exception in item registry! " + e.toString());
e.printStackTrace();
}
} }
/* Load creative items */ /* Load creative items */

View file

@ -117,7 +117,6 @@ public class BlockTranslator {
int spawnerRuntimeId = -1; int spawnerRuntimeId = -1;
Iterator<Map.Entry<String, JsonNode>> blocksIterator = blocks.fields(); Iterator<Map.Entry<String, JsonNode>> blocksIterator = blocks.fields();
while (blocksIterator.hasNext()) { while (blocksIterator.hasNext()) {
try {
javaRuntimeId++; javaRuntimeId++;
Map.Entry<String, JsonNode> entry = blocksIterator.next(); Map.Entry<String, JsonNode> entry = blocksIterator.next();
String javaId = entry.getKey(); String javaId = entry.getKey();
@ -210,11 +209,6 @@ public class BlockTranslator {
} }
bedrockRuntimeId++; bedrockRuntimeId++;
} catch (Exception e) {
// REMOVE AFTER 1.16 UPDATE PROBABLY
System.out.println("Block translator error! " + e.toString());
e.printStackTrace();
}
} }
if (cobwebRuntimeId == -1) { if (cobwebRuntimeId == -1) {