@@ -155,12 +155,12 @@
|
||||
BlockPosition blockposition1 = blockposition.immutable();
|
||||
@@ -281,8 +383,8 @@
|
||||
TileEntity tileentity = iblockdata.hasBlockEntity() ? this.level.getBlockEntity(blockposition) : null;
|
||||
LootTableInfo.Builder loottableinfo_builder = (new LootTableInfo.Builder(worldserver)).withRandom(this.level.random).withParameter(LootContextParameters.ORIGIN, Vec3D.atCenterOf(blockposition)).withParameter(LootContextParameters.TOOL, ItemStack.EMPTY).withOptionalParameter(LootContextParameters.BLOCK_ENTITY, tileentity).withOptionalParameter(LootContextParameters.THIS_ENTITY, this.source);
|
||||
LootParams.a lootparams_a = (new LootParams.a(worldserver)).withParameter(LootContextParameters.ORIGIN, Vec3D.atCenterOf(blockposition)).withParameter(LootContextParameters.TOOL, ItemStack.EMPTY).withOptionalParameter(LootContextParameters.BLOCK_ENTITY, tileentity).withOptionalParameter(LootContextParameters.THIS_ENTITY, this.source);
|
||||
|
||||
- if (this.blockInteraction == Explosion.Effect.DESTROY_WITH_DECAY) {
|
||||
- loottableinfo_builder.withParameter(LootContextParameters.EXPLOSION_RADIUS, this.radius);
|
||||
- lootparams_a.withParameter(LootContextParameters.EXPLOSION_RADIUS, this.radius);
|
||||
+ if (yield < 1.0F) { // CraftBukkit - add yield
|
||||
+ loottableinfo_builder.withParameter(LootContextParameters.EXPLOSION_RADIUS, 1.0F / yield); // CraftBukkit - add yield
|
||||
+ lootparams_a.withParameter(LootContextParameters.EXPLOSION_RADIUS, 1.0F / yield); // CraftBukkit - add yield
|
||||
}
|
||||
|
||||
iblockdata.spawnAfterBreak(worldserver, blockposition, ItemStack.EMPTY, flag2);
|
||||
|
||||
Reference in New Issue
Block a user