--- a/net/minecraft/world/entity/vehicle/AbstractChestBoat.java
+++ b/net/minecraft/world/entity/vehicle/AbstractChestBoat.java
@@ -66,12 +_,12 @@
     }
 
     @Override
-    public void remove(Entity.RemovalReason reason) {
+    public void remove(Entity.RemovalReason reason, @Nullable org.bukkit.event.entity.EntityRemoveEvent.Cause cause) { // CraftBukkit - add Bukkit remove cause
         if (!this.level().isClientSide && reason.shouldDestroy()) {
             Containers.dropContents(this.level(), this, this);
         }
 
-        super.remove(reason);
+        super.remove(reason, cause); // CraftBukkit - add Bukkit remove cause
     }
 
     @Override
@@ -94,8 +_,8 @@
 
     @Override
     public void openCustomInventoryScreen(Player player) {
-        player.openMenu(this);
-        if (player.level() instanceof ServerLevel serverLevel) {
+        // Paper - fix inventory open cancel - moved into below if
+        if (player.level() instanceof ServerLevel serverLevel && player.openMenu(this).isPresent()) { // Paper - Fix InventoryOpenEvent cancellation
             this.gameEvent(GameEvent.CONTAINER_OPEN, player);
             PiglinAi.angerNearbyPiglins(serverLevel, player, true);
         }
@@ -148,7 +_,7 @@
     @Nullable
     @Override
     public AbstractContainerMenu createMenu(int containerId, Inventory playerInventory, Player player) {
-        if (this.lootTable != null && player.isSpectator()) {
+        if (this.lootTable != null && player.isSpectator()) { // Paper - LootTable API (TODO spectators can open chests that aren't ready to be re-generated but this doesn't support that)
             return null;
         } else {
             this.unpackLootTable(playerInventory.player);
@@ -195,4 +_,58 @@
     public void stopOpen(Player player) {
         this.level().gameEvent(GameEvent.CONTAINER_CLOSE, this.position(), GameEvent.Context.of(player));
     }
+
+    // Paper start - LootTable API
+    final com.destroystokyo.paper.loottable.PaperLootableInventoryData lootableData = new com.destroystokyo.paper.loottable.PaperLootableInventoryData();
+
+    @Override
+    public com.destroystokyo.paper.loottable.PaperLootableInventoryData lootableData() {
+        return this.lootableData;
+    }
+    // Paper end - LootTable API
+    // CraftBukkit start
+    public java.util.List<org.bukkit.entity.HumanEntity> transaction = new java.util.ArrayList<>();
+    private int maxStack = MAX_STACK;
+
+    @Override
+    public java.util.List<net.minecraft.world.item.ItemStack> getContents() {
+        return this.itemStacks;
+    }
+
+    @Override
+    public void onOpen(org.bukkit.craftbukkit.entity.CraftHumanEntity player) {
+        this.transaction.add(player);
+    }
+
+    @Override
+    public void onClose(org.bukkit.craftbukkit.entity.CraftHumanEntity player) {
+        this.transaction.remove(player);
+    }
+
+    @Override
+    public java.util.List<org.bukkit.entity.HumanEntity> getViewers() {
+        return this.transaction;
+    }
+
+    @Override
+    public @Nullable org.bukkit.inventory.InventoryHolder getOwner() {
+        org.bukkit.entity.Entity entity = this.getBukkitEntity();
+        return entity instanceof final org.bukkit.inventory.InventoryHolder inventoryHolder ? inventoryHolder : null;
+    }
+
+    @Override
+    public int getMaxStackSize() {
+        return this.maxStack;
+    }
+
+    @Override
+    public void setMaxStackSize(int size) {
+        this.maxStack = size;
+    }
+
+    @Override
+    public org.bukkit.Location getLocation() {
+        return this.getBukkitEntity().getLocation();
+    }
+    // CraftBukkit end
 }
