HomeJavaModsSable Assembly Fix
Sable Assembly Fix
ModsJava

Sable Assembly Fix

by xiao-ou6630 · on Modrinth

Fixes item duplication during Sable assembly/disassembly by preventing non-Clearable block entities from dropping their contents. Works with any mod…

⬇ Download on Modrinth
Sable Assembly Fix — screenshot 1Sable Assembly Fix — screenshot 2

Overview

Sable Assembly Fix fixes an item duplication bug that occurs during Sable assembly/disassembly for block entities that do not implement the Clearable interface.

The Problem

Sable's SubLevelAssemblyHelper.moveBlocks() calls Clearable.tryClear() on every block entity during the assembly process. The issue is:

Triggering this bug is trivially cheap:

simply toggle the ship between physics mode and block mode (or vice versa) — each transition triggers assembly/disassembly, which duplicates the contents of any non-Clearable block entity on the ship. No expensive resources or complex setup required.

How It Works

A single @Redirect mixin intercepts the Clearable.tryClear() call inside SubLevelAssemblyHelper.moveBlocks() :

Affected Block Entities (Create + Addons)

Block Entity Items per dupe
TableCloth up to 4
Mechanical Arm entire held stack (e.g. 64 items at once)

Plus any modded BE with inventory that doesn't implement Clearable.

Note: The Mechanical Arm is especially severe — it duplicates the entire held stack in one operation. If the arm is holding a full stack of 64 items, you get 64 duplicated items per assembly/disassembly cycle. Any modded block entity with an inventory that doesn't implement Clearable is also affected.

Configuration

A whitelist system is included. The config file config/sableassemblyfix/whitelist.json is automatically created on first launch.

Add block entity IDs to the whitelist to skip the fix (e.g. if a mod handles Clearable on its own). Requires a game restart to reload.

Dependencies

License

MIT

Verified by MCModsHub

These come from our own check of the pack file, not from the source page.

Explore more