3
0
Mirror von https://github.com/ViaVersion/ViaVersion.git synchronisiert 2024-10-03 08:41:05 +02:00

Merge pull request #36 from Mystalion/drop-metadata

Drop MetadataPacket where metadata could not be rewritten
Dieser Commit ist enthalten in:
Myles 2016-03-02 14:45:50 +00:00
Commit b5b0117fa9

Datei anzeigen

@ -516,7 +516,7 @@ public class OutgoingTransformer {
return line;
}
private void transformMetadata(int entityID, Object dw, ByteBuf output) {
private void transformMetadata(int entityID, Object dw, ByteBuf output) throws CancelException {
// get entity
try {
transformMetadata(entityID, (List) ReflectionUtil.invoke(dw, "b"), output);
@ -529,11 +529,11 @@ public class OutgoingTransformer {
}
}
private void transformMetadata(int entityID, List dw, ByteBuf output) {
private void transformMetadata(int entityID, List dw, ByteBuf output) throws CancelException {
EntityType type = clientEntityTypes.get(entityID);
if (type == null) {
System.out.println("Unable to get entity for ID: " + entityID);
return;
throw new CancelException();
}
if (dw != null) {
short id = -1;