Skip to content

Commit f2e2f18

Browse files
authored
Fix custom sound handling in 1.9->1.8 (#691)
1 parent 2adf775 commit f2e2f18

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

common/src/main/java/com/viaversion/viarewind/protocol/v1_9to1_8/rewriter/WorldPacketRewriter1_9.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,9 +92,12 @@ public void register() {
9292
String name = wrapper.get(Types.STRING, 0);
9393
name = protocol.getMappingData().getMappedNamedSound(name);
9494
if (name == null) {
95-
wrapper.cancel();
96-
} else {
95+
return;
96+
}
97+
if (!name.isEmpty()) {
9798
wrapper.set(Types.STRING, 0, name);
99+
} else {
100+
wrapper.cancel();
98101
}
99102
});
100103
read(Types.VAR_INT); // Sound category

0 commit comments

Comments
 (0)