Fix #3701 - Loottables erasing on viewing

This commit is contained in:
William Blake Galbreath 2020-07-02 15:34:26 -05:00
parent 5064606627
commit 2ce563b6d0

View file

@ -586,10 +586,11 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
LootTable loottable = this.world.getMinecraftServer().getLootTableRegistry().getLootTable(this.lootTable);
if (entityhuman instanceof EntityPlayer) {
@@ -0,0 +0,0 @@ public abstract class EntityMinecartContainer extends EntityMinecartAbstract imp
CriterionTriggers.N.a((EntityPlayer) entityhuman, this.lootTable);
}
this.lootTable = null;
- this.lootTable = null;
+ //this.lootTable = null; // Paper
+ this.lootableData.processRefill(entityhuman); // Paper
LootTableInfo.Builder loottableinfo_builder = (new LootTableInfo.Builder((WorldServer) this.world)).set(LootContextParameters.POSITION, this.getChunkCoordinates()).a(this.lootTableSeed);
@ -645,10 +646,11 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
LootTable loottable = this.world.getMinecraftServer().getLootTableRegistry().getLootTable(this.lootTable);
if (entityhuman instanceof EntityPlayer) {
@@ -0,0 +0,0 @@ public abstract class TileEntityLootable extends TileEntityContainer {
CriterionTriggers.N.a((EntityPlayer) entityhuman, this.lootTable);
}
this.lootTable = null;
- this.lootTable = null;
+ //this.lootTable = null; // Paper
+ this.lootableData.processRefill(entityhuman); // Paper
LootTableInfo.Builder loottableinfo_builder = (new LootTableInfo.Builder((WorldServer) this.world)).set(LootContextParameters.POSITION, new BlockPosition(this.position)).a(this.lootTableSeed);