3
0
Mirror von https://github.com/PaperMC/Paper.git synchronisiert 2024-12-18 20:40:08 +01:00

Fixed crash when breaking gravel with a high fortune enchant

Dieser Commit ist enthalten in:
Nathan Adams 2011-11-27 01:41:56 +00:00
Ursprung eb7bd5f23b
Commit 139ad8c34a

Datei anzeigen

@ -0,0 +1,15 @@
package net.minecraft.server;
import java.util.Random;
public class BlockGravel extends BlockSand {
public BlockGravel(int i, int j) {
super(i, j);
}
public int a(int i, Random random, int j) {
j = Math.max(j, 3); // CraftBukkit - added to fix crash when j > 3
return random.nextInt(10 - j * 3) == 0 ? Item.FLINT.id : this.id;
}
}