3
0
Mirror von https://github.com/IntellectualSites/FastAsyncWorldEdit.git synchronisiert 2024-11-07 12:00:07 +01:00

Add note if clipboard >= Integer.MAX_VALUE

Dieser Commit ist enthalten in:
NotMyFault 2021-02-05 13:21:15 +01:00
Ursprung ac16c9a2ba
Commit 3df080abe4
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 158F5701A6AAD00C

Datei anzeigen

@ -78,7 +78,7 @@ public class DiskOptimizedClipboard extends LinearClipboard implements Closeable
public DiskOptimizedClipboard(BlockVector3 dimensions, File file) {
super(dimensions);
if (HEADER_SIZE + ((long) getVolume() << 1) >= Integer.MAX_VALUE) {
throw new IllegalArgumentException("Dimensions too large for this clipboard format");
throw new IllegalArgumentException("Dimensions too large for this clipboard format. Use //lazycopy for large selections.");
} else if (HEADER_SIZE + ((long) getVolume() << 1) + (long) ((getHeight() >> 2) + 1) * ((getLength() >> 2) + 1) * ((getWidth() >> 2) + 1) >= Integer.MAX_VALUE) {
log.error("Dimensions are too large for biomes to be stored in a DiskOptimizedClipboard");
canHaveBiomes = false;