add sorry maximilian for adding an max explosion check

This commit is contained in:
bixilon 2020-06-17 14:40:19 +02:00
parent fb09597303
commit 8a658da299
No known key found for this signature in database
GPG Key ID: 5CAD791931B09AC4

View File

@ -36,6 +36,7 @@ public class PacketExplosion implements ClientboundPacket {
radius = buffer.readFloat();
if (radius > 100.0F) {
// maybe somebody tries to crash me?
// Sorry, Maximilian Rosenmüller
throw new IllegalArgumentException(String.format("Explosion to big %s > 100.0F", radius));
}
int recordCount = buffer.readInteger();