Fix: Beacon effects broken since 1.20.2 (#4199)

Since 1.20.2, effect IDs start at 0, not 1. Bedrock of course doesn't respect that, so we need to subtract 1!
This commit is contained in:
chris 2023-10-08 12:33:17 +02:00 committed by GitHub
parent dec62e94e2
commit 3fdd6b41d0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -119,7 +119,7 @@ public class BeaconInventoryTranslator extends AbstractBlockInventoryTranslator
}
private OptionalInt toJava(int effectChoice) {
return effectChoice == 0 ? OptionalInt.empty() : OptionalInt.of(effectChoice);
return effectChoice == 0 ? OptionalInt.empty() : OptionalInt.of(effectChoice - 1);
}
@Override