3
0
Mirror von https://github.com/ViaVersion/ViaBackwards.git synchronisiert 2024-07-06 07:38:03 +02:00

Possibility to suppress type not found errors

Dieser Commit ist enthalten in:
Matsv 2017-07-30 12:23:00 +02:00
Ursprung 908931e174
Commit 34ca6324c5
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 97CEC2A2EA31350F
3 geänderte Dateien mit 9 neuen und 3 gelöschten Zeilen

Datei anzeigen

@ -13,6 +13,7 @@ package nl.matsv.viabackwards.api.entities.types;
import lombok.AllArgsConstructor;
import lombok.Getter;
import nl.matsv.viabackwards.ViaBackwards;
import us.myles.ViaVersion.api.Via;
import java.util.ArrayList;
import java.util.List;
@ -30,7 +31,8 @@ public class EntityType1_10 {
type = EntityType.findById(typeID);
if (!type.isPresent()) {
ViaBackwards.getPlatform().getLogger().severe("[EntityType1_10] Could not find type id " + typeID + " isObject=" + isObject);
if (!Via.getConfig().isSuppressMetadataErrors())
ViaBackwards.getPlatform().getLogger().severe("[EntityType1_10] Could not find type id " + typeID + " isObject=" + isObject);
return EntityType.ENTITY; // Fall back to the basic ENTITY
}

Datei anzeigen

@ -13,6 +13,7 @@ package nl.matsv.viabackwards.api.entities.types;
import lombok.AllArgsConstructor;
import lombok.Getter;
import nl.matsv.viabackwards.ViaBackwards;
import us.myles.ViaVersion.api.Via;
import java.util.ArrayList;
import java.util.List;
@ -29,7 +30,8 @@ public class EntityType1_11 {
type = EntityType.findById(typeID);
if (!type.isPresent()) {
ViaBackwards.getPlatform().getLogger().severe("[EntityType1_11] Could not find type id " + typeID + " isObject=" + isObject);
if (!Via.getConfig().isSuppressMetadataErrors())
ViaBackwards.getPlatform().getLogger().severe("[EntityType1_11] Could not find type id " + typeID + " isObject=" + isObject);
return EntityType.ENTITY; // Fall back to the basic ENTITY
}

Datei anzeigen

@ -13,6 +13,7 @@ package nl.matsv.viabackwards.api.entities.types;
import lombok.AllArgsConstructor;
import lombok.Getter;
import nl.matsv.viabackwards.ViaBackwards;
import us.myles.ViaVersion.api.Via;
import java.util.ArrayList;
import java.util.List;
@ -29,7 +30,8 @@ public class EntityType1_12 {
type = EntityType.findById(typeID);
if (!type.isPresent()) {
ViaBackwards.getPlatform().getLogger().severe("[EntityType1_12] Could not find type id " + typeID + " isObject=" + isObject);
if (!Via.getConfig().isSuppressMetadataErrors())
ViaBackwards.getPlatform().getLogger().severe("[EntityType1_12] Could not find type id " + typeID + " isObject=" + isObject);
return EntityType.ENTITY; // Fall back to the basic ENTITY
}