mirror of
https://github.com/GTNewHorizons/ForgeMultipart.git
synced 2026-11-24 22:14:38 +00:00
[Target 2.10+] Port ForgeMultipart to Java. Checkpoint with binary compatibility preserved for safe consumers port. (#59)
This commit is contained in:
1 parent
264aa16cf0
commit
3b181eb231
618 files changed
+61535
-9991
No files matched your search
@@ -0,0 +1,905 @@
|
||||
# Downstream compatibility: ABI inventory and consumer audit
|
||||
|
||||
Status: installed-jar and source refresh 2026-10-16 against GTNH `2.9.0-RC-2`; older dated snapshots are kept
|
||||
below as history. Read this before changing any compatibility surface. It has two parts, answering two different
|
||||
questions.
|
||||
|
||||
- **Part 1, the ABI inventory**, answers "what must still link?" It is a constant-pool scan of every mod jar in a
|
||||
real pack, not a source search.
|
||||
- **Part 2, the consumer audit**, answers the harder question: "what behavior do real consumers expect after they
|
||||
have linked?" It covered all 27 ForgeMultipart consumers in the supplied GTNH daily `2026-08-25+700` instance, plus
|
||||
UtilitiesInExcess as the planned Extra Utilities replacement. The `2.9.0-RC-2` refresh adds ThaumicEnergistics
|
||||
as a 28th installed consumer and GT5U's new ProjectRed wire recoloring path.
|
||||
|
||||
Intentional differences from the reference belong in the [divergence ledger](DIVERGENCES.md), and the
|
||||
consumer-facing summary of what breaks on rebuild is in the [release notes](../RELEASE_NOTES.md).
|
||||
|
||||
# Part 1 - Downstream ABI inventory
|
||||
|
||||
Method: constant-pool scan of every mod jar in a real pack, not a source search. Bytecode is the only oracle that
|
||||
covers reflection strings, closed-source consumers, and mods whose published source does not match their release jar.
|
||||
GitHub code search was deliberately not used; it indexes default branches only and silently omits results.
|
||||
|
||||
Scanned: GTNH `2.9.0-RC-2`, 240 mod jars (`ForgeMultipart-1.7.16.jar` itself excluded). Reproduce with
|
||||
`tools/AbiScan.java`; frozen baselines in `src/test/fixtures/abi/gtnh-2.9.0-rc2-consumers.txt` (current) and
|
||||
`gtnh-daily-678-consumers.txt` (original `2026-08-14+678` inventory).
|
||||
|
||||
```
|
||||
java tools/AbiScan.java <instance>/.minecraft/mods ForgeMultipart
|
||||
```
|
||||
|
||||
Requires a JDK 17+ single-file source launch. Re-run after public-API changes and diff against the frozen baseline;
|
||||
any member that disappears from the port but appears in the baseline is a linkage break in a shipping mod.
|
||||
|
||||
The RC-2 scan was resolved against this branch's compiled classes: every inherited type, other type and member
|
||||
resolves to a non-private declaration, or to an inherited Minecraft member. The one static exception is
|
||||
`scalatraits.TSlottedTile.v_partMap()`, a runtime-generated trait accessor covered by `ForgeEnvironmentSmokeTest`.
|
||||
|
||||
## Totals
|
||||
|
||||
| Category | `+678` | `2.9.0-RC-2` |
|
||||
| --- | ---: | ---: |
|
||||
| Consumer jars | 27 of 240 | 28 of 240 |
|
||||
| Types extended or implemented downstream | 35 | 35 |
|
||||
| Referenced members with exact descriptors | 255 | 268 |
|
||||
| Other referenced types | 76 | 80 |
|
||||
| Reflective string constants | 20 | 9 |
|
||||
|
||||
Every `+678` member, inherited-type and other-type row is still present. The changes are:
|
||||
|
||||
- **GuideNH `1.3.41`** replaced its 17-string reflection with 28 direct member references, most already linked by other consumers, including
|
||||
`MultipartGenerator$.generateCompositeTile(TileEntity, scala.collection.Iterable, boolean)`,
|
||||
`TileMultipart.loadParts(scala.collection.Iterable)`, `MicroblockGenerator$.create` and `Microblock.shape_$eq(B)`.
|
||||
This matches the [source findings](#guidenh); the reflective contracts remain for older GuideNH jars.
|
||||
- **GT5U `5.09.54.205`** gained a ProjectRed wire recoloring path: `BlockMultipart.reduceMOP(MovingObjectPosition):
|
||||
scala.Tuple2`, `TileMultipart.partMap(int)`, `TSlottedPart.getSlotMask()` and `TMultiPart.getType()`.
|
||||
- **AE2 `rv3-beta-1080`** links `JCuboidPart.bind(TileMultipart)`, the `super.bind` call from its host-refresh fix.
|
||||
- **ThaumicEnergistics `1.7.64-GTNH`** is a new consumer through one `Class.forName` string.
|
||||
|
||||
## Consumers by weight
|
||||
|
||||
Ranked by number of classes in the jar that touch `codechicken/multipart` or `codechicken/microblock`.
|
||||
|
||||
| Classes | Jar |
|
||||
| ---: | --- |
|
||||
| 142 | ProjRed-4.12.47-GTNH |
|
||||
| 38 | extrautilities-1.2.12 |
|
||||
| 19 | OpenComputers-1.12.64-GTNH |
|
||||
| 18 | ProjectBlue-1.2.11-GTNH |
|
||||
| 7 | appliedenergistics2-rv3-beta-1080-GTNH |
|
||||
| 7 | buildcraft-compat-7.1.22 |
|
||||
| 5 | ForgeRelocationFMP-0.2.0, gregtech-5.09.54.205 |
|
||||
| 4 | Galacticraft-3.4.34-GTNH, ThaumicTinkerer-2.12.33, WR-CBE-1.7.12, chisel-2.17.34-GTNH |
|
||||
| 3 | IguanaTweaksTConstruct-2.7.12, WitchingGadgets-1.8.51-GTNH, guidenh-1.3.41 |
|
||||
| 2 | BloodArsenal-1.5.12, Botania-1.13.37-GTNH, Waila-1.19.34, matter-manipulator-0.1.61-GTNH |
|
||||
| 1 | BiomesOPlenty, BloodMagic-1.9.14, Natura-2.8.24, Schematica-1.12.6-GTNH, TConstruct-1.14.118-GTNH, ae2fc-1.5.113-gtnh, endercore-0.5.15, etfuturum-2.6.60-GTNH, thaumicenergistics-1.7.64-GTNH |
|
||||
|
||||
Two distinct consumer shapes:
|
||||
|
||||
- **Java consumers** (extrautilities, AE2, chisel, WitchingGadgets, ThaumicTinkerer, buildcraft-compat, gregtech,
|
||||
matter-manipulator, and the long tail) use the Java-facing API: `MultiPartRegistry.registerParts(IPartFactory, String[])`,
|
||||
`registerConverter`, `BlockMicroMaterial`, `MicroMaterialRegistry.registerMaterial`, `TileMultipart.jPartList()`,
|
||||
`addPart`, `remPart`, `canAddPart`. None of these need Scala.
|
||||
- **Scala consumers** (ProjRed, OpenComputers, ProjectBlue, ForgeRelocationFMP) mix in ForgeMultipart traits and call
|
||||
the generated `$class` static helpers directly. These are the constraint on Scala removal.
|
||||
|
||||
## Load-bearing Scala surface
|
||||
|
||||
Everything in this section must keep its exact descriptor, or a named consumer fails to link.
|
||||
|
||||
### Trait `$class` helpers (8 classes, 16 static methods)
|
||||
|
||||
| Helper | Methods used | Consumers |
|
||||
| --- | --- | --- |
|
||||
| `TCuboidPart$class` | `$init$`, `drawBreaking`, `getCollisionBoxes`, `getSubParts` | ForgeRelocationFMP, OpenComputers, ProjRed, ProjectBlue |
|
||||
| `TIconHitEffects$class` | `$init$`, `addDestroyEffects`, `addHitEffects` | ForgeRelocationFMP, OpenComputers, ProjRed |
|
||||
| `TNormalOcclusion$class` | `$init$`, `occlusionTest` | ForgeRelocationFMP, OpenComputers, ProjRed |
|
||||
| `JIconHitEffects$class` | `$init$`, `getBreakingIcon` | ForgeRelocationFMP, OpenComputers, ProjRed |
|
||||
| `TFacePart$class` | `$init$`, `solid`, `redstoneConductionMap` | OpenComputers, ProjRed, ProjectBlue |
|
||||
| `TItemMultiPart$class` | `$init$`, `getHitDepth`, `onItemUse` | ProjRed |
|
||||
| `Saw$class` | `$init$`, `getMaxCuttingStrength` | ProjRed |
|
||||
| `TEdgePart$class` | `$init$` | OpenComputers |
|
||||
|
||||
`JPartialOcclusion$class` is not retained: it has **no** downstream caller in the pack. The two consumers that
|
||||
touch `JPartialOcclusion` (ForgeRelocationFMP, WitchingGadgets) only call
|
||||
`getPartialOcclusionBoxes()Ljava/lang/Iterable;`, which remains. The eight helpers above are the ones that matter.
|
||||
|
||||
### Companion object singletons (17 `MODULE$` fields read downstream)
|
||||
|
||||
`MultiPartRegistry$`, `TileMultipart$`, `MultipartGenerator$`, `NormalOcclusionTest$`, `RedstoneInteractions$`,
|
||||
`MicroMaterialRegistry$`, `MicroblockGenerator$`, `MicroblockRender$`, `BlockMicroMaterial$`, `ItemMicroPart$`,
|
||||
`CornerMicroClass$`, `EdgeMicroClass$`, `FaceMicroClass$`, `HollowMicroClass$`,
|
||||
`handler/MultipartProxy$`, `handler/MultipartSaveLoad$`, `handler/MicroblockProxy$`.
|
||||
|
||||
Each must keep a public static `MODULE$` field of its own type plus the instance methods used on it.
|
||||
|
||||
### Members with Scala types in their descriptors (8 total)
|
||||
|
||||
| Descriptor | Consumers |
|
||||
| --- | --- |
|
||||
| `TileMultipart.partList()Lscala/collection/Seq;` | OpenComputers, ProjRed, AE2, extrautilities, guidenh |
|
||||
| `NormalOcclusionTest$.apply(Lscala/collection/Traversable;Lscala/collection/Traversable;)Z` | ForgeRelocationFMP, OpenComputers |
|
||||
| `MultiPartRegistry$.registerParts(Lcodechicken/multipart/MultiPartRegistry$IPartFactory2;Lscala/collection/Seq;)V` | ProjRed |
|
||||
| `MultiPartRegistry$.registerParts(Lscala/Function2;Lscala/collection/Seq;)V` | ForgeRelocationFMP |
|
||||
| `MicroMaterialRegistry.getIdMap()[Lscala/Tuple2;` | extrautilities |
|
||||
| `MultipartGenerator$.generateCompositeTile(Lnet/minecraft/tileentity/TileEntity;Lscala/collection/Iterable;Z)Lcodechicken/multipart/TileMultipart;` | guidenh (`2.9.0-RC-2`; previously reflective only) |
|
||||
| `TileMultipart.loadParts(Lscala/collection/Iterable;)V` | guidenh (`2.9.0-RC-2`; previously reflective only) |
|
||||
| `BlockMultipart.reduceMOP(Lnet/minecraft/util/MovingObjectPosition;)Lscala/Tuple2;` | gregtech (new in `2.9.0-RC-2`) |
|
||||
|
||||
GT5U reads `reduceMOP`'s `_1()` as the boxed `Integer` part index and ignores `_2()`. The port keeps the exact
|
||||
static and companion descriptors, and `BlockMultipartCharacterizationTest` pins the boxed index and rebased hit.
|
||||
`BlockMultipart.hitPartIndex` is the Java replacement for the index; see the [guide](../api/HIT_PART.md) and the
|
||||
adoption ledger.
|
||||
|
||||
The Scala-typed surface is small. `TileMultipart.jPartList()Ljava/util/List;` is already the more
|
||||
widely used accessor (ProjectBlue, WitchingGadgets, buildcraft-compat, extrautilities, gregtech, matter-manipulator),
|
||||
so the Java-first collection API mostly exists already and the Scala overloads are a thin retained shell.
|
||||
|
||||
The port supplies `NormalOcclusionTest.testBoxes(java.lang.Iterable, java.lang.Iterable)` for the box-list
|
||||
contract. Both old `apply(Traversable, Traversable)` entries remain, with deprecations pointing to the Java entry.
|
||||
The shipping ForgeRelocationFMP/OpenComputers companion calls still require their exact descriptor until adoption;
|
||||
see the [migration guide](../api/OCCLUSION.md#box-versus-box-queries) and consumer ledger.
|
||||
|
||||
`MultiPartRegistry.registerPartFactory(IPartFactory2, String...)` now provides the Java registration entry without
|
||||
Scala overload resolution. Both `registerParts(IPartFactory2, Seq)` entries are deprecated; all eight existing
|
||||
registration descriptors remain. ProjectRed's sequence and ForgeRelocationFMP's function companion calls still need
|
||||
their bridges until release/adoption. See the [registration guide](../api/PART_REGISTRATION.md).
|
||||
|
||||
`IDWriter` has **zero** downstream references, so its Scala function accessors were not retained.
|
||||
|
||||
## Reflective consumers
|
||||
|
||||
These fail at runtime, not at link time, so ABI tooling will not catch a break. In `2.9.0-RC-2`, 9 string
|
||||
constants across:
|
||||
|
||||
- `Schematica-1.12.6-GTNH` - `TileMultipart`, `TMultiPart`, `MultiPartRegistry$`, `MultipartGenerator$`, `MicroblockClass`.
|
||||
- `Galacticraft-3.4.34-GTNH` - `TileMultipart`, `MicroMaterialRegistry`, `BlockMicroMaterial`.
|
||||
- `Waila-1.19.34` - `BlockMultipart`.
|
||||
- `AE2`, `ae2fc`, `thaumicenergistics-1.7.64-GTNH` - `TileMultipart`, loaded with `Class.forName` to register Waila
|
||||
providers.
|
||||
- `etfuturum-2.6.60-GTNH` - `codechicken.multipart.minecraft.ButtonPart`.
|
||||
|
||||
`guidenh-1.3.20` in `+678` was the broadest reflective consumer, with 17 strings: `MultipartGenerator`/`MultipartGenerator$`,
|
||||
`MultipartHelper`/`MultipartHelper$`, `MultipartRenderer`/`MultipartRenderer$`, `TileMultipart`,
|
||||
`TileMultipartClient`, `MicroblockClient`, `Microblock`, `MicroblockClass`, `MicroblockGenerator$`,
|
||||
`BlockMicroMaterial`/`BlockMicroMaterial$`, `MicroMaterialRegistry`/`MicroMaterialRegistry$`, `BlockMultipart`.
|
||||
`guidenh-1.3.41` in RC-2 has none; it links the same members directly.
|
||||
|
||||
Note that both the class and its `$` companion are named in several cases, so renaming or removing a companion
|
||||
object breaks these even where no bytecode reference exists.
|
||||
|
||||
The port offers `MultipartHelper.createPreviewTileFromNBT` to replace Schematica's private registry map,
|
||||
microblock construction, Scala collection, generator and loader reflection as one all-or-nothing preview operation.
|
||||
The lower-level `MultiPartRegistry.getPartFactory(String): IPartFactory2` remains available for specialized callers.
|
||||
Existing private fields, companions and descriptors remain for released consumers until adoption.
|
||||
|
||||
`ButtonPart.setOrientation(int, ForgeDirection): void` now replaces Et Futurum's four reflective array writes and
|
||||
keeps the two direction maps consistent; [guide](../api/BUTTON_ORIENTATIONS.md). The existing public mutable static
|
||||
`metaSideMap` and `sideMetaMap` fields retain their exact names, types and modifiers for old releases. Removing or
|
||||
narrowing them still waits for a migrated Et Futurum release, target-pack adoption and a fresh reflective-source scan.
|
||||
|
||||
`ItemSaw.setHarvestLevel(int): void` now replaces Iguana's private-field write; [guide](../api/SAW_STRENGTH.md).
|
||||
The existing private `harvestLevel: int` field remains for old releases and shares storage with the setter. It loses
|
||||
only `ACC_FINAL`, which makes the supported mutation explicit and keeps reflective writes working. Removal still
|
||||
waits for an Iguana release, target-pack adoption and a fresh scan.
|
||||
|
||||
## Compatibility retention rules
|
||||
|
||||
1. Scala removal follows released-consumer adoption and retirement of internal Scala users.
|
||||
2. Keep `registerScalaTrait`, ScalaSignature decoding and the external-trait fixtures covering
|
||||
`MicroblockGenerator.registerTrait`. Third-party Scala traits are not internal-only: ProjRed's
|
||||
`LightMicroMaterial$` registers `mrtjp.projectred.illumination.LightMicroblock`, a compiled Scala trait with a
|
||||
`$class` helper, so `ASMMixinFactory.registerTrait` parses its ScalaSignature. Removing that path breaks
|
||||
ProjRed's illuminated microblocks until a migrated release ships.
|
||||
3. Preserve the listed 8 `$class` helpers, 17 `MODULE$` singletons and 8 Scala-typed descriptors until their removal
|
||||
gates pass. Absence from that list alone is not permission to delete a bridge; check source and reflective use too.
|
||||
4. Verify reflective member lookups separately; constant-pool strings do not establish which members are selected.
|
||||
|
||||
## Historical GuideNH reflective surface, from source
|
||||
|
||||
This section describes older supported releases, not current GuideNH source or the `1.3.41` jar shipped in
|
||||
`2.9.0-RC-2`. Commit `4a0cd02e` (2026-09-16, included in tags `1.3.33` onward) removed FMP reflection and the
|
||||
private-material accessor mixin. Current source
|
||||
still calls the generator companions and Scala collection APIs directly; see the [current findings](#guidenh).
|
||||
The constraints below remain relevant to old jars until target-pack adoption is verified.
|
||||
|
||||
The constant-pool scan can see the names guidenh reflects on but not the members it looks up. This section is read
|
||||
from the checked-out source at `6137525`, in
|
||||
`src/main/java/com/hfstudio/guidenh/integration/forgemultipart/ForgeMultipartHelpers.java`. **None of this is visible
|
||||
to the ABI diff**; a break here is silent until a user opens a guide page.
|
||||
|
||||
The dispatch helper is `invokeStaticOrSingletonMethod(class, companion, method, args...)`. It tries a **static** method
|
||||
on the plain class first, and only on `INVOCATION_MISSING` falls back to reading `companion.MODULE$` and invoking the
|
||||
method on it. So for most entries the companion is a fallback. The exceptions below are the ones that matter.
|
||||
|
||||
| Owner | Member reflected on | Reached via |
|
||||
| --- | --- | --- |
|
||||
| `MultipartHelper` | `createTileFromNBT(World, NBTTagCompound)` | static; companion is fallback |
|
||||
| `MultipartRenderer` | `renderWorldBlock(IBlockAccess, int, int, int, Block, int, RenderBlocks)` | static; companion is fallback |
|
||||
| `MultipartGenerator` | `generateCompositeTile(TileEntity, scala.collection.Iterable, boolean)` | **companion only for the Scala descriptor**; new static Java-Iterable entry is additive |
|
||||
| `BlockMicroMaterial` | `register(material)`, plus a constructor of arity 2 `(Block, int)` or 1 `(Block)` | static; companion is fallback |
|
||||
| `MicroMaterialRegistry` | `getMaterial(int)` | static; companion is fallback |
|
||||
| `MicroblockGenerator$` | `create(MicroblockClass, int, boolean)` | GuideNH explicitly selects the companion, matched by exact parameter types; static Java replacement exists |
|
||||
| `TileMultipart` | `partList()`, `partList_$eq(scala.collection.Seq)`, `loadParts(...)`, `notifyTileChange()`, `markRender()` | instance |
|
||||
| `Microblock` | `microClass()`, `material()`, `shape()` | instance |
|
||||
| `TMultiPart` | `getDrops()` | instance |
|
||||
| `BlockMicroMaterial` | `block()`, `meta()` | instance; absent from general `IMicroMaterial` |
|
||||
|
||||
Types used only for `isInstanceOf`: `BlockMultipart`, `TileMultipart`, `TileMultipartClient`, `Microblock`,
|
||||
`MicroblockClient`, `BlockMicroMaterial`.
|
||||
|
||||
### Three constraints this adds
|
||||
|
||||
1. **`MultipartGenerator$.MODULE$` is load-bearing through reflection.** `generateCompositeTile` is `private[multipart]`
|
||||
in Scala, so no static forwarder is emitted on `MultipartGenerator` and guidenh's static attempt always misses. It
|
||||
reaches the method only through the companion. A port that keeps the class but drops the companion, or
|
||||
promotes the method to a public static and removes it from the companion, breaks guidenh silently.
|
||||
|
||||
The port adds `MultipartGenerator.generateCompositeTile(TileEntity, java.lang.Iterable, boolean)` while
|
||||
retaining the exact companion Scala descriptor/body. GuideNH's old Scala sequence is not assignable to the new
|
||||
Java parameter, so its existing matcher still falls back to the companion. Both old and new reflective contracts
|
||||
are tested; migration requires a Java parts collection. See the [guide](../api/COMPOSITE_GENERATION.md).
|
||||
|
||||
2. **`MicroblockGenerator$.create` is matched by exact parameter types**, including `pts[0].getName()` string-compared
|
||||
against `"codechicken.microblock.MicroblockClass"`. That pins `create(MicroblockClass, int, boolean)` on the
|
||||
companion and pins `MicroblockClass`'s fully qualified name. Widening a parameter or renaming the class breaks the
|
||||
lookup even though every call site still links.
|
||||
|
||||
The existing static `MicroblockGenerator.create(MicroblockClass, int, boolean)` now has a
|
||||
[guide and compiling example](../api/MICROBLOCK_CREATION.md). Both exact reflective entries are tested; no API
|
||||
shape or production method body changes were needed. GuideNH must change its explicitly selected owner and receiver
|
||||
before it stops using the companion. Release/adoption, shape-setter override checks and client previews remain gates.
|
||||
|
||||
3. **`TileMultipart.partList_$eq(scala.collection.Seq)` is reflectively load-bearing.** The port supplies
|
||||
`setPartList(java.util.List)` and `loadPartList(java.util.Collection)`, while retaining the exact legacy setter and
|
||||
loader descriptors and override dispatch. Dropping the old setter in favor of the Java method would still break
|
||||
guidenh invisibly. Exact and assignability-based reflective tests cover both legacy contracts. `resolvePartList` also falls back to a public *field*
|
||||
named `partList`, which never existed - Scala emits the field private - so that path is dead in the reference too.
|
||||
|
||||
`MultipartHelper$` is retained on the strength of the fallback path alone: the static is found first today, so the
|
||||
companion is never reached in practice. That is a weaker justification than the two "companion only" entries above,
|
||||
but the cost of keeping a four-method forwarder is negligible against a silent break.
|
||||
|
||||
GuideNH's private `BlockMicroMaterial.block: Block` and `meta: int` fields remain unchanged for its accessor mixin.
|
||||
Existing public virtual `block()` / `meta()` now have a [typed query guide](../api/MATERIAL_ACCESS.md) and regression
|
||||
coverage; no descriptor or method body changed. The mixin reads constructor fields whereas direct calls honor
|
||||
subclass overrides, as the old reflective fallback already did. Remove the consumer's mixin only when adopting the
|
||||
typed query; FMP field removal still waits for released-consumer adoption.
|
||||
|
||||
|
||||
# Part 2 - Source-level consumer audit
|
||||
|
||||
|
||||
## Bottom line
|
||||
|
||||
The Java conversion cannot be treated as a set of independent class translations. Downstream code depends on five
|
||||
connected contracts:
|
||||
|
||||
1. **The generated composite tile architecture.** Parts cause `TileMultipart` subclasses to acquire Scala traits,
|
||||
Java traits, and arbitrary pass-through interfaces. AE2, ProjectRed, Extra Utilities, WR-CBE,
|
||||
WitchingGadgets, ForgeRelocationFMP, and UtilitiesInExcess all exercise this architecture.
|
||||
2. **Scala-emitted binary shapes.** ProjectRed, OpenComputers, ProjectBlue, and ForgeRelocationFMP call generated
|
||||
trait `$class` helpers and companion `MODULE$` objects. Java consumers also use Scala-shaped APIs such as
|
||||
`partList(): scala.collection.Seq` and `getIdMap(): scala.Tuple2[]`.
|
||||
3. **Multipart state and lifecycle.** Consumers do more than add parts. They inspect `partMap`, mutate/rebuild slot
|
||||
maps, move the live tile object, call `onMoved`, remove and reload parts, trigger part/tile notifications, and
|
||||
make deliberate choices about description packets.
|
||||
4. **World, NBT, and packet formats.** The container `parts` list, each part's `id`, core microblock fields and part
|
||||
type strings are an interchange format used by builders, schematic tools, movers, HUD mods, and save/load code.
|
||||
Material numeric IDs and their packet encoding are also shared outside FMP.
|
||||
5. **Names that are not in ordinary linkage.** Schematica reaches a private Scala-mangled field, Et Futurum mutates
|
||||
static arrays, older GuideNH releases mix into private fields, Iguana reflects a saw field, and several mods load FMP classes
|
||||
and companions by string. A clean ABI diff alone will miss these breaks.
|
||||
|
||||
The safest first Java release is therefore **Java-maintainable implementation with the bounded Scala compatibility
|
||||
shell retained**. Removing the Scala runtime is a separate coordinated migration, not the end of this source port.
|
||||
|
||||
## Coverage and method
|
||||
|
||||
The supplied instance was rescanned with `tools/AbiScan.java` before reading source:
|
||||
|
||||
- scanner visited 241 mod JARs, one of which was excluded as ForgeMultipart itself;
|
||||
- 27 consumer JARs;
|
||||
- 35 downstream-extended or implemented FMP types;
|
||||
- 255 referenced FMP members with exact descriptors;
|
||||
- 76 other referenced FMP types;
|
||||
- 20 class-name/reflection strings.
|
||||
|
||||
Those structural totals are unchanged from the frozen `+678` inventory. The consumer versions changed, but no new
|
||||
binary API family appeared. The compatibility audit covers active consumer binaries, including Extra Utilities,
|
||||
and the supplied source checkouts. It records required types/members, reflection contracts, factories, converters,
|
||||
part subclasses, tile access, registry access, NBT, packets, rendering, occlusion, redstone and movement behavior.
|
||||
Where source checkouts are available, important call sites were traced through the owning code instead of counting imports.
|
||||
|
||||
The 2026-10-16 refresh rescanned GTNH `2.9.0-RC-2` (above) and traced every new or changed row to consumer source.
|
||||
The new consumer, ThaumicEnergistics, was read at `83c405d0bee3` (`1.7.66-GTNH`). Its only FMP reference
|
||||
appeared in `1.7.62-GTNH`, and `ModuleWaila.java` is unchanged since the installed `1.7.64-GTNH` tag.
|
||||
|
||||
This gives full coverage of the current pack's known source and binary consumers. It does not claim that an arbitrary
|
||||
future mod, a runtime-generated script, or an unpublished patched JAR cannot contain another reflective use. The ABI
|
||||
scanner should remain a release gate for exactly that reason.
|
||||
|
||||
`ForgeRelocation` itself is not the source of `ForgeRelocationFMP`; both repositories are needed and both are now
|
||||
present. Only the plugin is one of the FMP consumers.
|
||||
|
||||
### Current source references (2026-10-16)
|
||||
|
||||
Diffed every Java/Scala file that references FMP at either end, between the 2026-09-21 heads and the current
|
||||
heads. Only three consumers changed such files:
|
||||
|
||||
- **GT5U**: `gregtech/api/util/ColoredBlockContainer.java` gained `ProjectRedWireContainer` (details in the
|
||||
[GT5U row](#narrow-consumers-still-real-contracts)).
|
||||
- **ProjectRed**: `transmission/redwires.scala` and `bundledwires.scala` add `recolour(int)` to insulated wires and
|
||||
bundled cables, plus part-update key `11`. It uses only FMP members ProjectRed already linked: `markDirty`, the
|
||||
part write stream, `notifyPartChange` and `markRender`. This is the target of GT5U's recoloring.
|
||||
- **ProjectBlue**: `ControlPanelRenderer.java` changed label spacing only; its FMP use is unchanged.
|
||||
|
||||
All other changed checkouts touched no FMP-referencing file. The September note that only GuideNH and AE2 had
|
||||
changed still holds for that window. Extra Utilities is the unchanged non-Git 1.2.12. No physical-client run was
|
||||
performed.
|
||||
|
||||
| Checkout | Inspected HEAD | 2026-09-21 HEAD |
|
||||
| --- | --- | --- |
|
||||
| AE2FluidCraft-Rework | `c7ec5b0c8b5f` | `6e8dd013bd4e` |
|
||||
| Applied-Energistics-2-Unofficial | `c690fbc273be` | `fdedc3a8f023` |
|
||||
| BiomesOPlenty | `fc7f1f6392a1` | same |
|
||||
| BloodArsenal | `890824be106a` | same |
|
||||
| BloodMagic | `10a36f6413b8` | `6776676ef209` |
|
||||
| Botania | `3f62d4b8fe7c` | `c802a448e4f4` |
|
||||
| BuildCraftCompat | `79e02803be32` | same |
|
||||
| Chisel | `d08e48b73ba5` | `3d3260cd71b8` |
|
||||
| EnderCore | `1998218128c7` | same |
|
||||
| Et-Futurum-Requiem | `1944927eecd1` | `65407a439b57` |
|
||||
| ForgeRelocation | `21da7aae0e6e` | same |
|
||||
| ForgeRelocationFMP | `49a810b8c63b` | same |
|
||||
| Galacticraft | `ff4c5c87ba21` | `fbdc41b97e81` |
|
||||
| GT5-Unofficial | `1a9469a13228` | `fe3606a12547` |
|
||||
| GuideNH | `99785342eff2` | `16f142417df1` |
|
||||
| IguanaTweaksTConstruct | `2bc09889d3e2` | same |
|
||||
| MatterManipulator | `dbc15f55a031` | `4d9bc003f193` |
|
||||
| Natura | `4f88c0665928` | same |
|
||||
| OpenComputers | `1e4559ff5f24` | `a3ac18595179` |
|
||||
| ProjectBlue | `28abef1385cb` | `c01a5e769643` |
|
||||
| ProjectRed | `b29f404eaa05` | `e173952e96a4` |
|
||||
| Schematica | `3b03ee937953` | same |
|
||||
| ThaumicEnergistics | `83c405d0bee3` | new |
|
||||
| ThaumicTinkerer | `e4c8acdd4fa9` | same |
|
||||
| TinkersConstruct | `644373000cdc` | `8f6e2496f792` |
|
||||
| UtilitiesInExcess | `3e107a1fe9bc` | same |
|
||||
| waila | `f998f9ebfe09` | same |
|
||||
| WirelessRedstone-CBE | `9dfb913b4880` | same |
|
||||
| WitchingGadgets | `adf174f552f9` | `663bad20ac24` |
|
||||
|
||||
## Cross-cutting compatibility map
|
||||
|
||||
| Contract | Consumers that make it load-bearing | What must survive |
|
||||
| --- | --- | --- |
|
||||
| Part factory/converter registration | ProjectRed, Extra Utilities, OpenComputers, AE2, BuildCraftCompat, ForgeRelocationFMP, Chisel, ThaumicTinkerer, WR-CBE, WitchingGadgets, ProjectBlue, UtilitiesInExcess | Java `IPartFactory`/`IPartFactory2`, converters, the Scala `Function2` and `Seq` overloads, stable type strings, client/server construction |
|
||||
| Dynamic composite tiles | ProjectRed, Extra Utilities, AE2, ForgeRelocationFMP, WR-CBE, WitchingGadgets, UtilitiesInExcess; GuideNH and Schematica reconstruct them | Trait-bit selection, generated subclass caching, pass-through interfaces, client/server selection, promotion of an existing tile |
|
||||
| External Scala trait generation | ProjectRed illuminated microblocks | `MicroblockGenerator.registerTrait`, ScalaSignature decoding, `$class` helper handling, correct trait initialization and dispatch |
|
||||
| Tile collections and slot state | ProjectRed, Extra Utilities, OpenComputers, AE2, ProjectBlue, GT5U, BuildCraftCompat, WitchingGadgets, MatterManipulator, GuideNH | `partList(): Seq`, `jPartList(): List`, ordering, `partMap(int)`, mutable `TSlottedTile.v_partMap`, `bindPart`, slot-map rebuilds |
|
||||
| Capability-cache refresh | OpenComputers `PrintPart.toggleState` | Supported `TileMultipart.bindPart` dispatch, caller-cleared old slot entries, no implicit list insertion or part binding |
|
||||
| Local part-change notification | ProjectRed `RedstoneGatePart.onOutputChange` | Supported `TileMultipart.internalPartChange`, equality filtering and `operate` dispatch; caller retains packet/dirty/external-neighbor policy |
|
||||
| Placement/removal/replacement | Most custom-part mods | `getTile`/`getOrConvertTile`, `canPlacePart`, `canAddPart`, `canReplacePart`, `addPart`, `remPart`, binding and notifications in their current order |
|
||||
| Move lifecycle | ForgeRelocationFMP, MatterManipulator | A live `TileMultipart` can be detached/reinserted, coordinates rewritten, then `onMoved`; render, dirty, lighting, and description synchronization remain coherent |
|
||||
| Occlusion and geometry | ProjectRed, Extra Utilities, OpenComputers, AE2, ForgeRelocationFMP, Chisel, WR-CBE, WitchingGadgets, UtilitiesInExcess | Normal and partial occlusion, collision/subpart boxes, `PartMap` numbering, Java iterable adapters, Scala `Traversable` overload |
|
||||
| Redstone and connectivity | ProjectRed, Extra Utilities, OpenComputers, ProjectBlue, AE2, WR-CBE | `IRedstonePart` family, `TRedstoneTile`, `RedstoneInteractions`, face/edge/center maps, neighbor and part-change propagation |
|
||||
| Micro-material registry | Extra Utilities, ProjectRed, ProjectBlue, AE2, BuildCraftCompat, Chisel, material-only integrations, UtilitiesInExcess | Stable material names, integer IDs, remapping, packet ID encoding, `getIdMap(): Tuple2[]`, block/meta access, material behavior hooks |
|
||||
| Multipart save/load | Extra Utilities, ProjectRed, OpenComputers, BuildCraftCompat, MatterManipulator, GuideNH, Schematica, Waila, UtilitiesInExcess | Tile `parts` list, per-part `id`, factory lookup, `save`/`load` ordering, microblock fields, unknown/invalid-part behavior |
|
||||
| Description/update packets | Every substantial custom part integration | `writeDesc`/`readDesc`, keyed part packets, `sendDescUpdate`, `sendDescPacket`, material packet IDs, render and neighbor notification behavior |
|
||||
| Hit-to-part reduction | GT5U `ColoredBlockContainer` | Static `BlockMultipart.reduceMOP(MovingObjectPosition): scala.Tuple2`, boxed `Integer` `_1()` matching `jPartList()` order for an `ExtendedMOP` from `RayTracer.retraceBlock`; Java replacement `hitPartIndex` |
|
||||
| Reflection/mixins | Older GuideNH releases, Schematica, Et Futurum, Galacticraft, Waila, AE2/AE2FC/ThaumicEnergistics, Iguana | Exact class/companion/member/field names and, where stated below, exact parameter and field types; current GuideNH uses direct calls |
|
||||
|
||||
## Consumer findings
|
||||
|
||||
### ProjectRed - deepest current consumer
|
||||
|
||||
ProjectRed is not merely an optional integration. Wires, framed wires, bundled wires, gates, lamps, buttons, pipes,
|
||||
solar panels, and fabricated gates are FMP parts. Its 141 touching classes dominate the installed binary surface.
|
||||
|
||||
- Its parts mix `TMultiPart` with `TCuboidPart`, `TFacePart`, `TSlottedPart`, `TNormalOcclusion`,
|
||||
`TIconHitEffects`, redstone interfaces, and microblock hollow-connect interfaces. The emitted classes directly call
|
||||
Scala trait `$class` helpers.
|
||||
- Item placement uses `TItemMultiPart`; registries use both `IPartFactory` and `IPartFactory2`, including the
|
||||
Scala-`Seq` registration descriptor.
|
||||
- Connectivity is built on exact `PartMap` face/edge/center numbering and repeated `partMap` queries across the same
|
||||
and neighboring tiles. Redstone propagation uses `RedstoneInteractions` and casts generated tiles to
|
||||
`scalatraits.TRedstoneTile` for `openConnections`.
|
||||
- Parts rely on lifecycle callbacks and their ordering: `onAdded`, `onRemoved`, `onPartChanged`,
|
||||
`onNeighborChanged`, `onChunkLoad`, `onWorldJoin`, scheduled ticks, `notifyPartChange`, `markDirty`, and
|
||||
`markRender`.
|
||||
- Framed wires persist material names and use `materialID`, `materialName`, `getMaterial`, packet material IDs, and
|
||||
`ItemMicroPart.create`. Their fit calculation temporarily changes their own occlusion bounds and calls
|
||||
`tile.canReplacePart(this, this)`.
|
||||
- Part-owned NBT and packet fields include `connMap`, `side`, `orient`, `shape`, `mat`, and type-specific data. FMP
|
||||
must keep treating these tags as opaque and must continue calling part save/load and packet hooks exactly once in
|
||||
the established order.
|
||||
- `LightMicroMaterial` implements `MicroblockGenerator.IGeneratedMaterial` and registers the third-party Scala trait
|
||||
`LightMicroblock` with `MicroblockGenerator.registerTrait`. Generated microblocks must actually acquire that trait;
|
||||
it supplies dynamic halo rendering and computes light from `tile.partList`.
|
||||
- ProjectRed also uses `MultipartSaveLoad.loadingWorld`, `MultipartProxy.block`, vanilla multipart part classes,
|
||||
microblock class companions, saw traits, and the material highlight renderer extension.
|
||||
|
||||
**Migration consequence:** ProjectRed is the acceptance test for the complete architecture: Scala trait ingestion,
|
||||
trait linearization, tile and microblock code generation, redstone tile traits, core lifecycle, rendering, packets,
|
||||
and the micro-material system. A launch-only smoke test is inadequate; illuminated microblocks, gates, face/framed
|
||||
wires, and routed pipes need functional fixtures.
|
||||
|
||||
### Extra Utilities 1.2.12 - active supported consumer
|
||||
|
||||
Extra Utilities remains in the supported compatibility target. UtilitiesInExcess is its intended replacement;
|
||||
approval to switch that target and adoption of the replacement in the pack are still pending. Preserve the current
|
||||
consumer's required APIs, saved-data behavior and integration coverage until both gates pass.
|
||||
|
||||
Required compatibility spans several FMP subsystems:
|
||||
|
||||
- It registers generated-tile pass-through interfaces for `IAntiMobTorch`, pipe/cosmetic/filter pipe interfaces,
|
||||
node, inventory, liquid, and energy node interfaces, plus CoFH `IEnergyHandler`. Composite tiles must expose these
|
||||
interfaces and dispatch to the correct part.
|
||||
- Transfer pipes and nodes are multipart factories/converters. They use face/slot traits, neighbor-tile callbacks,
|
||||
hollow connections, `TRedstoneTile`, `RedstoneInteractions`, part lists/maps, and part-change notifications.
|
||||
- Custom parts include the magnum torch, fence, wall, sphere, pipe jackets, and several microblock-derived shapes.
|
||||
They exercise normal/partial occlusion, icon hit effects, `PartMetaAccess`, `MicroblockRender`, and client/server
|
||||
factories.
|
||||
- Connected-texture and colored/full-bright micro-materials subclass `BlockMicroMaterial` and participate in
|
||||
material rendering. Fences and walls add their own pass-through interfaces.
|
||||
- NEI recipes and item enumeration consume `MicroMaterialRegistry.getIdMap()` as `scala.Tuple2[]`, use
|
||||
`MicroRecipe`, saw cutting strength, material names, and `ItemMicroPart` creation.
|
||||
- Some paths use `jPartList`; others use `partList().toIterator()`. Both collection views and stable ordering are
|
||||
required even though the mod's implementation language is Java.
|
||||
|
||||
The jar is sufficient to establish behavior, while the exact JAR's constant pool remains the authority for
|
||||
names and descriptors. Obfuscated Minecraft method names should not be treated as source-quality naming evidence.
|
||||
|
||||
**Migration consequence:** Extra Utilities covers almost every Java-facing extension seam and is the strongest test
|
||||
that Java wrappers still compose into the same generated tile. UtilitiesInExcess does not make this compatibility
|
||||
burden disappear until existing worlds and the old mod have been retired.
|
||||
|
||||
### OpenComputers - generated slot state is part of the effective API
|
||||
|
||||
OpenComputers converts its cable and 3D print blocks to parts and registers `oc` cable/print factories.
|
||||
|
||||
- `CablePart` mixes cuboid, slotted, hollow-connect, normal-occlusion, icon-effect, and OC network-environment
|
||||
behavior. Network join/separate is driven from part lifecycle callbacks.
|
||||
- Network traversal locates cable parts through `TileMultipart.partList`. Connection checks combine FMP normal
|
||||
occlusion boxes, solid face parts, and exact `PartMap.face(...).mask` values.
|
||||
- `PrintPart` mixes cuboid, edge, face, slotted, normal occlusion, and redstone traits. Its shape and slot mask change
|
||||
at runtime.
|
||||
- When a print toggles shape, it casts the generated tile to `scalatraits.TSlottedTile`, directly clears every
|
||||
matching entry in `v_partMap`, and calls `tile.bindPart(this)` to rebuild its slots. `v_partMap` field shape and
|
||||
`bindPart` behavior are therefore externally load-bearing, not private implementation details in practice.
|
||||
- Placement uses `getOrConvertTile`, `canAddPart`, and `addPart`; complexity limits are calculated across the Scala
|
||||
`partList`. Print redstone input also folds over that list.
|
||||
|
||||
**Migration consequence:** a Java slot-map rewrite must retain a binary and behavioral bridge for `TSlottedTile`,
|
||||
including its public generated state. Test a print whose on/off shapes occupy different slots next to a cable and a
|
||||
face part.
|
||||
|
||||
### ProjectBlue - Java parts built on Scala shim bases
|
||||
|
||||
ProjectBlue defines tiny Scala bridge bases (`JFacePart`, `JCuboidFacePart`, `JCenterPart`) so most of its FMP code
|
||||
can be Java. Its active multipart is the bundled-redstone control panel.
|
||||
|
||||
- The bridge bases inherit `TFacePart`, `TCuboidPart`, and `TSlottedPart`, so their generated `$class` calls remain
|
||||
binary dependencies.
|
||||
- Control panels register an `IPartFactory`, place through `canPlacePart`/`addPart`, remove through `remPart`, and
|
||||
send part description updates.
|
||||
- Bundled/redwire connectivity repeatedly queries `partMap` using exact face, edge, and center indices and uses
|
||||
`RedstoneInteractions` for vanilla/FMP power.
|
||||
- The panel resolves its cover material by stable micro-material name and item representation. Its own persistent
|
||||
fields are opaque part data.
|
||||
- Its edit network identifies a target part by world coordinates plus index in `jPartList`; list order is therefore
|
||||
observable over the network.
|
||||
|
||||
**Migration consequence:** preserve trait bridges, part ordering, `PartMap`, redstone semantics, and stable material
|
||||
name lookup. A control-panel edit packet is a useful ordering regression test.
|
||||
|
||||
### Applied Energistics 2
|
||||
|
||||
AE2's cable bus is a full multipart integration, not just visual compatibility.
|
||||
|
||||
- `CableBusPart` is a Java cuboid part with normal occlusion, masked redstone, and `AEMultiTile`; AE2 dynamically
|
||||
registers `AEMultiTile` and layer interfaces as pass-through interfaces.
|
||||
- `PartRegistry` constructs registered AE2 parts through AE2's combined-instance helper. The FMP integration acts as
|
||||
both part factory and block converter.
|
||||
- Placement/conversion uses `getOrConvertTile`, `canAddPart`, and `addPart`. Code traverses the Scala `partList`
|
||||
iterator.
|
||||
- Occlusion is checked both directly with `NormalOcclusionTest` and by asking `tile.canAddPart` with an AE2
|
||||
`NormallyOccludedPart` probe.
|
||||
- When a generated tile implements `TIInventoryTile`, AE2 calls `rebuildSlotMap()` from `notifyNeighbors()`, after
|
||||
its cable bus inventory size may have changed. `TileMultipart.refreshInventorySlots()` is the supported replacement.
|
||||
- AE2's Waila path and AE2 Fluid Craft load `TileMultipart` by name to register multipart HUD providers.
|
||||
- Since `4548d13f0` (2026-09-12), `CableBusPart.bind(TileMultipart)` calls `super.bind` then refreshes hosted
|
||||
parts through `CableBusContainer.updatePartHostInfo`. Host changes and world join also refresh those references.
|
||||
Loading and composite expansion/reduction must dispatch through the virtual `bind` hook, with the new tile already
|
||||
visible through `tile()`, without restarting the parts during replacement. The port retains this behavior;
|
||||
`TileMultipartLoadingTest` covers consumer host refresh through successive replacements.
|
||||
- That commit also makes `CableBusPart.addPart` reject placement when `canAddPart` fails, using the existing FMP
|
||||
occlusion path. No new FMP entry point is required; the Scala part-list dependency remains.
|
||||
|
||||
**Migration consequence:** preserve dynamic pass-through interfaces and generated tile inventory traits, not only
|
||||
the `CableBusPart` class ABI. Test a cable bus sharing a block with an inventory-bearing part and an occluding cover.
|
||||
|
||||
### BuildCraftCompat
|
||||
|
||||
BuildCraftCompat serializes multipart blocks for builders and reconstructs them later.
|
||||
|
||||
- It identifies `MultipartProxy.block`, walks `jPartList`, calls each part's `save`, and records the part type.
|
||||
- Restore calls `MultiPartRegistry.loadPart(type, tag)`, then uses `canPlacePart`/`addPart`.
|
||||
- Its microblock schematic validates the saved material name through `MicroMaterialRegistry.getMaterial`.
|
||||
- It understands and rotates FMP's own saved type IDs for face, corner, edge, post, hollow, torch, lever, button,
|
||||
and redstone-torch parts.
|
||||
|
||||
**Migration consequence:** registry lookup, part `save`/`load`, core type IDs, material names, and placement validation
|
||||
are a world-data contract. A builder round trip containing every built-in Minecraft part and microblock shape should
|
||||
be a golden test.
|
||||
|
||||
### ForgeRelocationFMP
|
||||
|
||||
The plugin registers `rfmp_frame`, a frame-block converter, an `IFrame` pass-through interface, and an FMP tile
|
||||
mover.
|
||||
|
||||
- `FramePart` mixes `TCuboidPart`, `TNormalOcclusion`, and `TIconHitEffects`. Its special fit test temporarily exposes
|
||||
one face occlusion box, calls `canReplacePart(this, this)`, and combines another part's normal boxes, partial boxes,
|
||||
and collision boxes through the Scala `NormalOcclusionTest` overload.
|
||||
- Frame placement requires an existing multipart tile and uses `canPlacePart`/`addPart`.
|
||||
- The mover removes the live `TileMultipart`, moves the original block and tile object, rewrites `xCoord/yCoord/zCoord`,
|
||||
reinserts it, and calls `onMoved()` in the post-move hook.
|
||||
|
||||
**Migration consequence:** this is a direct test of Scala trait helpers, Scala factory overloads, mixed occlusion,
|
||||
pass-through interfaces, and live tile movement. `onMoved` must reestablish every coordinate-sensitive/generated-tile
|
||||
invariant without replacing the tile object.
|
||||
|
||||
### Chisel
|
||||
|
||||
Chisel registers its blocks as micro-materials and adds a `chisel_torch` factory/converter. `PartChiselTorch`
|
||||
subclasses FMP's `TorchPart`, including its constructors, load/read/write behavior and static side mapping. Placement
|
||||
uses tile conversion, fit checks, and `addPart`; Chisel also supplies a full-bright material implementation.
|
||||
|
||||
**Migration consequence:** the Minecraft-part classes are extension bases, not internal examples. Keep protected
|
||||
state, constructors, packet/NBT hooks, and static orientation tables source- and binary-compatible.
|
||||
|
||||
### ThaumicTinkerer
|
||||
|
||||
ThaumicTinkerer registers block micro-materials and factories/converters for candle and nitor parts. The parts extend
|
||||
`McMetaPart`; the candle participates in random display ticks. They rely on FMP meta-part persistence, placement,
|
||||
render hooks, and factory type dispatch.
|
||||
|
||||
**Migration consequence:** preserve `McMetaPart` subclass semantics and random-display capability composition.
|
||||
|
||||
### Wireless Redstone CBE
|
||||
|
||||
WR-CBE registers transmitter, receiver, and jammer parts and pass-through interfaces for wireless tile APIs.
|
||||
|
||||
- Its Java parts use `JItemMultiPart`, `JCuboidPart`, face/redstone, normal/partial occlusion, icon effects, and
|
||||
micro-shrink rendering interfaces.
|
||||
- It uses `partMap`, `RedstoneInteractions`, `IRedstonePart`, `NormalOcclusionTest`, `MicroOcclusion.recalcBounds`,
|
||||
`onPartChanged`, `remPart`, and tile item drops.
|
||||
|
||||
**Migration consequence:** Java compatibility bases must retain the same trait defaults and generated composite
|
||||
behavior. Test wireless interface dispatch through a composite tile, not just direct calls on the part.
|
||||
|
||||
### WitchingGadgets
|
||||
|
||||
WitchingGadgets registers multipart essentia tubes and buffers, with block converters and factories.
|
||||
|
||||
- Parts extend `McMetaPart`; the tube is slotted, and parts implement Thaumcraft transport/wand interfaces.
|
||||
- Those external APIs are registered as pass-through interfaces, including the overload carrying client/server
|
||||
generation flags.
|
||||
- Connection logic walks `jPartList` and directly consumes other parts' normal and partial occlusion boxes.
|
||||
- Rendering goes through `PartMetaAccess`; placement uses `canAddPart`/`addPart`.
|
||||
|
||||
**Migration consequence:** preserve flag-sensitive pass-through registration, Java occlusion iterables, slotted part
|
||||
semantics, and `PartMetaAccess` behavior.
|
||||
|
||||
### MatterManipulator
|
||||
|
||||
MatterManipulator is the broadest external editor of multipart state.
|
||||
|
||||
- Analysis records each part's `getType`, calls `save` into NBT containing `id`, and captures `getDrops`.
|
||||
- Application removes current parts with `remPart`, sorts microblocks before other parts, reconstructs through
|
||||
`MultiPartRegistry.loadPart(type, nbt)`, calls `part.load(nbt)`, and adds through `TileMultipart.addPart`.
|
||||
- It interprets core microblock type prefixes and NBT fields `material`, `shape`, `side`, `orient`, and `connMap`, and
|
||||
transforms exact `PartMap` edge/corner numbering.
|
||||
- Its mover detaches and reinserts the same tile object, rewrites coordinates, validates it, calls `onMoved`, then
|
||||
performs dirty, render, block-update, lighting, and description-packet synchronization.
|
||||
- Its apply path intentionally does **not** send a redundant description packet: rebuilding the tile a second time
|
||||
previously produced null bounds. Packet timing and reconstruction side effects therefore matter.
|
||||
|
||||
**Migration consequence:** add capture/apply/move golden tests. This consumer will expose changes in part ordering,
|
||||
factory semantics, core NBT, movement lifecycle, and over-eager network synchronization.
|
||||
|
||||
### GuideNH
|
||||
|
||||
GuideNH reconstructs and renders multipart tiles for guide scenes and exports part statistics. At `16f142417df1`,
|
||||
the FMP integration uses direct calls guarded by mod-presence checks and Forge `@Optional.Method` annotations.
|
||||
Commit `4a0cd02e` (2026-09-16, included in tags `1.3.33` onward) removed its FMP reflection and
|
||||
`AccessorBlockMicroMaterial` mixin. The dependency is FMP `1.7.14`; this is not adoption of the unreleased Java API.
|
||||
This upstream cleanup uses existing APIs and is not work performed by this migration project.
|
||||
|
||||
- Reconstruction still starts with `MultipartHelper.createTileFromNBT`, promotes client microblocks and tiles,
|
||||
loads/binds parts, then calls `notifyTileChange` and `markRender`. Rendering calls `MultipartRenderer` directly.
|
||||
- It directly invokes `MultipartGenerator$.MODULE$.generateCompositeTile` with a Scala iterable and
|
||||
`MicroblockGenerator$.MODULE$.create`, then copies shape through `shape_$eq(byte)`.
|
||||
- Preview paths retain `partList(): Seq`, Scala iteration/`ListBuffer`, and `loadParts(scala.collection.Iterable)`.
|
||||
`Ae2ForgeMultipartBridge` also retains Scala part traversal. The old `partList_$eq` call is gone.
|
||||
- Material export uses `jPartList`, `Microblock.material`, registry lookup and public `BlockMicroMaterial.block()` /
|
||||
`meta()` getters. Statistics use `jPartList` and direct `getDrops`. Material lookup failures are logged and skipped;
|
||||
getter failures propagate. See the [material guide](../api/MATERIAL_ACCESS.md) for differences from the example.
|
||||
- `createPreviewTileFromNBT` and the Java generator/collection replacements have not been adopted.
|
||||
|
||||
**Migration consequence:** direct linking now enforces the retained companion/Scala contracts. All these calls have
|
||||
counterparts in the port; no production API change is required. Material access already uses public getters, while
|
||||
preview/Scala migration remains pending. Keep old private fields and setter descriptors for older supported jars
|
||||
until pack adoption is verified; source tags alone do not establish installed-artifact compatibility.
|
||||
|
||||
### Schematica
|
||||
|
||||
Schematica's optional integration reconstructs multipart tiles from schematic NBT, especially on the client. It is
|
||||
more invasive than its small binary footprint suggests.
|
||||
|
||||
- It reflects `MultiPartRegistry$.MODULE$` and the **private Scala-mangled field**
|
||||
`codechicken$multipart$MultiPartRegistry$$typeMap`, casting it to `scala.collection.mutable.Map`.
|
||||
- It resolves material IDs, obtains the registered microblock class from that map, and invokes
|
||||
`MicroblockClass.create(boolean, int)`.
|
||||
- It reflects part `load`, `onPartChanged`, `TileMultipart.loadParts`, `TileMultipart.createFromNBT`, and
|
||||
`MultipartGenerator$.generateCompositeTile(TileEntity, scala.collection.Iterable, boolean)`.
|
||||
- It parses tile NBT `parts`, each part's `id`, and microblock `material`; it rejects a preview if any part fails to
|
||||
reconstruct.
|
||||
|
||||
**Migration consequence:** the registry's private field name **and Scala mutable-map representation are currently
|
||||
effective public API**. A Java `Map` replacement will silently disable Schematica unless an exact compatibility field
|
||||
is retained or Schematica is patched and deployed first. This is a higher-risk constraint than the constant-pool
|
||||
inventory alone shows.
|
||||
|
||||
`MultiPartRegistry$` retains the exact private field as a Scala mutable-map wrapper backed by the canonical Java
|
||||
`HashMap`. A regression test performs Schematica's lookup and verifies that both views resolve the same factory.
|
||||
|
||||
The port provides `MultiPartRegistry.getPartFactory(String)` as the supported replacement for map lookup.
|
||||
It returns the exact registered factory or null without construction or missing-name logging. Schematica can reflect
|
||||
this public static method and continue invoking `MicroblockClass.create(client, materialId)` on the returned object;
|
||||
`loadPart` would incorrectly choose the server factory path for its client preview. The old private field remains.
|
||||
See the [guide](../api/FACTORY_LOOKUP.md) and the now-available [Java tile generator](../api/COMPOSITE_GENERATION.md);
|
||||
consumer patches and pack adoption remain pending.
|
||||
|
||||
### UtilitiesInExcess - future replacement, already a substantial consumer
|
||||
|
||||
UtilitiesInExcess is not in the `2.9.0-RC-2` JAR scan but is in scope because it is intended to replace Extra Utilities.
|
||||
|
||||
- `Content` implements `IPartFactory2` for `ue_fence`, `ue_wall`, and `ue_sphere`, with legacy Extra Utilities type
|
||||
aliases when the old mod is absent.
|
||||
- Parts extend `TMultiPart`, implement Java icon/normal-occlusion interfaces, call the normal occlusion protocol, and
|
||||
render through microblock material helpers.
|
||||
- Placement and connectivity use `canPlacePart`, `addPart`, `BlockMultipart`, neighboring `TileMultipart` instances,
|
||||
`jPartList`, and part sub-boxes.
|
||||
- Recipes and item enumeration consume `MicroMaterialRegistry.getIdMap()` as `scala.Tuple2[]` and use microblock
|
||||
class IDs plus `ItemMicroPart.create`.
|
||||
- Materials use name/ID lookup, packet material ID helpers, remapping, sounds, icons, drops, and rendering. Legacy
|
||||
Extra Utilities material names are explicitly remapped for world conversion.
|
||||
- At audited HEAD, the server factory reads NBT key `material` while `MaterialBasedPart.save` writes `mat`. That is a
|
||||
UtilitiesInExcess-side inconsistency to resolve before relying on save/load round trips; FMP should not special-case
|
||||
it.
|
||||
|
||||
**Migration consequence:** replacing Extra Utilities does not permit early removal of `IPartFactory2`, the Scala
|
||||
`Tuple2[]` registry view, legacy material remapping, or the Java part/occlusion bridges. UtilitiesInExcess should be
|
||||
added to compatibility CI before it enters the pack.
|
||||
|
||||
## Narrow consumers, still real contracts
|
||||
|
||||
| Consumer | Actual use | Compatibility requirement |
|
||||
| --- | --- | --- |
|
||||
| BloodArsenal | Registers decorative blocks/metas as `BlockMicroMaterial` instances | Constructor and `registerMaterial`; stable chosen names |
|
||||
| Botania | Registers decorative blocks/metas as micro-materials | Same material registration API and block/meta behavior |
|
||||
| Biomes O' Plenty | Registers historical BOP block/metas as micro-materials | Constructor, registry, and its dot-separated material names |
|
||||
| Natura | Registers single/ranged block metas, using both `createAndRegister` and direct registration | Static helper plus registry API and generated material keys |
|
||||
| TConstruct | Optional init plugin registers many smeltery/metal/glass blocks with `createAndRegister` | Helper availability and init-time registration behavior |
|
||||
| Galacticraft | Reflectively constructs `BlockMicroMaterial` and chooses the first public method named `registerMaterial`; separately rejects `TileMultipart` as an energy receiver | Exact class/constructor names; compatible public registration method; tile class identity. Avoid incompatible same-name overloads because it does not check the signature |
|
||||
| BloodMagic | Teleposer reconstructs multipart tiles with `MultipartHelper.createTileFromNBT` and sends a description packet after placement | NBT reconstruction, placement lifecycle, and `sendDescPacket` |
|
||||
| Waila | Reflects `BlockMultipart`, reads tile NBT `parts`, then dispatches providers using each part tag's `id` | Block class name and tile/part NBT layout |
|
||||
| AE2 Fluid Craft | Reflects `TileMultipart` and registers Waila part providers | Tile class name and `jPartList`/provider behavior reached by AE2 |
|
||||
| GT5U | Detects `TileMultipart`, iterates `jPartList`, and finds a ProjectRed `GatePart` to expose its screwdriver slot. Since `5.09.54.205`, spray cans recolor ProjectRed insulated wires and bundled cables: retrace the block, take `(Integer) BlockMultipart.reduceMOP(hit)._1()` as a `jPartList` index, take the slot from `TSlottedPart.getSlotMask()`, then follow chained blocks through `partMap(slot)` and equal `getType()` | Tile identity, Java list view/order, part instance identity; exact `reduceMOP` static descriptor with Scala `Tuple2` return and boxed-index `_1`; ray-trace index agreeing with `jPartList` order; `partMap` slot numbering; stable type strings |
|
||||
| ThaumicEnergistics | Loads `TileMultipart` with `Class.forName` and registers Waila body/NBT providers on it, so vis-link info still shows after a cover moves its AE2 parts into a multipart tile. Parts are found through AE2's `Platform.getPartFromTE`, not FMP. Added by `f6422d7` (2026-10-02, tags `1.7.62-GTNH` onward); no FMP compile dependency | Exact `codechicken.multipart.TileMultipart` class name; AE2 part-host pass-through on generated tiles |
|
||||
| EnderCore | Tests items with `instanceof ItemSaw` for durability display | `ItemSaw` class identity and inheritance |
|
||||
| IguanaTweaksTConstruct | Creates saws through `MicroblockProxy`, reads saw methods, accesses proxy companions, and reflectively mutates private `ItemSaw.harvestLevel` | Proxy methods and `MODULE$`, `Saw`/`ItemSaw` identity, exact `harvestLevel: int` field name/type until adoption; `setHarvestLevel(int)` is the supported replacement |
|
||||
| Et Futurum Requiem | Reflectively gets and mutates static `int[] ButtonPart.metaSideMap` and `sideMetaMap` to add floor and ceiling orientation | Exact class and mutable static field names/types until migration; `ButtonPart.setOrientation` is the supported replacement |
|
||||
|
||||
## Source-only hazards
|
||||
|
||||
The constant-pool inventory identifies reflective class names, but source inspection adds exact member-level
|
||||
requirements:
|
||||
|
||||
| Consumer | Hidden requirement | Likely symptom if broken |
|
||||
| --- | --- | --- |
|
||||
| Schematica | `MultiPartRegistry$.MODULE$`; field `codechicken$multipart$MultiPartRegistry$$typeMap` of Scala mutable-map shape; exact generator/load methods | FMP schematic tile reconstruction disables itself or returns no preview |
|
||||
| Older GuideNH releases | Companion-only generator methods; `partList_$eq(Seq)`; `BlockMicroMaterial.block` and `.meta` mixin fields | Missing/incorrect guide preview, material export, or part statistics; current source instead links directly to companion/Scala methods |
|
||||
| Et Futurum | Static mutable `ButtonPart.metaSideMap` and `sideMetaMap`, both `int[]`, until direct API adoption | FMP buttons attach with pre-fix orientation behavior |
|
||||
| Iguana | Private `ItemSaw.harvestLevel` field until direct setter adoption | Existing saw cutting strengths are not adjusted |
|
||||
| Galacticraft | Reflection by method name only for `registerMaterial` | Galacticraft micro-material registration is skipped after a caught exception |
|
||||
| Waila | `BlockMultipart` string plus tile NBT `parts`/part `id` | No multipart HUD data |
|
||||
|
||||
These need targeted runtime tests or explicit downstream patches. They cannot be proven safe by `javap` ABI diffing.
|
||||
|
||||
`ConsumerReflectionCompatibilityTest` freezes the older GuideNH, Et Futurum, Iguana, and Galacticraft
|
||||
member shapes above. `ButtonOrientationFunctionalTest` also freezes Et Futurum's exact array mutation and all-face
|
||||
placement, then verifies the supported typed replacement. `ItemSawCharacterizationTest` runs Iguana's exact boxed
|
||||
field mutation and the direct setter against shared storage. Schematica's registry lookup has its own live-view
|
||||
regression test. The manual client checks remain necessary for end-to-end integration behavior.
|
||||
|
||||
## Data and ordering contracts
|
||||
|
||||
### Core NBT and identity
|
||||
|
||||
The following are read by code outside FMP and must be treated as serialized API:
|
||||
|
||||
- the tile's `parts` compound list;
|
||||
- the `id` string in every part compound;
|
||||
- built-in multipart type strings and registry lookup behavior;
|
||||
- microblock `material`, `shape`, and orientation fields used by schematic/editor code;
|
||||
- material names and remapping, including legacy Extra Utilities names;
|
||||
- invalid/unknown part handling during `loadPart`, tile creation, and preview reconstruction.
|
||||
|
||||
Consumer-specific fields such as ProjectRed's `connMap` and UtilitiesInExcess's `mat` belong to their parts. FMP's
|
||||
obligation is to invoke each part's hooks with the same tag and ordering, not to interpret or rewrite those fields.
|
||||
|
||||
### Observable part order
|
||||
|
||||
Part list order is not an internal detail:
|
||||
|
||||
- ProjectBlue identifies an edited part by its `jPartList` index;
|
||||
- rendering code in ProjectRed and Extra Utilities indexes `partList` from hit data;
|
||||
- MatterManipulator deliberately sorts placement, with microblocks first;
|
||||
- GuideNH and Schematica build an ordered list before generating/loading a composite tile;
|
||||
- Waila preserves tile NBT order when dispatching part providers.
|
||||
|
||||
The Java port may add faster indexed storage, but all published views, serialization, binding, ray-hit indices, and
|
||||
packet consumers must observe one consistent order.
|
||||
|
||||
Current-branch verification: `MultipartHelperFunctionalTest` freezes ordered two-part NBT reconstruction and slot
|
||||
rebinding plus the exact logical chunk-description framing and part payload. `TileMultipartLifecycleFunctionalTest`
|
||||
freezes add/remove callbacks and the MatterManipulator-shaped live move, including ordered `onWorldSeparate` before
|
||||
ordered `onMoved`/`onWorldJoin`, without replacing the generated tile.
|
||||
|
||||
### Material IDs and packets
|
||||
|
||||
Numeric material IDs are runtime registry identities used in descriptions and custom-part packets. Names are the
|
||||
persistent identity. Preserve:
|
||||
|
||||
- deterministic name-to-ID lookup for one runtime;
|
||||
- remap behavior for renamed materials;
|
||||
- `writeMaterialID`/`readMaterialID` wire agreement;
|
||||
- `materialName`/`materialID` round trips;
|
||||
- the legacy `getIdMap(): scala.Tuple2[]` view until Extra Utilities and UtilitiesInExcess are migrated.
|
||||
|
||||
## Java API adoption ledger
|
||||
|
||||
This ledger tracks migration of a specific legacy contract, not completion of an entire consumer's migration.
|
||||
Factory registration/lookup, material enumeration, tile collection/traversal access, tile loading/storage assignment,
|
||||
client preview reconstruction, tile occlusion and box queries, render-ID accessors, named tile conversion results and
|
||||
the struck-part index and inventory slot refresh are implemented on
|
||||
`algent/java`. The [API index](../API.md) links the guides and compiling Java examples. These additions are not yet
|
||||
tied to a released minimum dependency version. Unlisted contracts remain governed by the inventories above.
|
||||
|
||||
| Legacy contract | Consumer and inspected source | Supported replacement | Consumer migration/release | Target-pack adoption and removal gate |
|
||||
| --- | --- | --- | --- | --- |
|
||||
| `ButtonPart.sideMetaMap[side ^ 1]` live inverse lookup | ProjectRed `e173952e96a4` and separate preparatory migration checkout: `illumination/items.scala`, `ItemPartButtonCommons.newPart` | `ButtonPart.metaForSide(side ^ 1)`; [lookup contract](../api/BUTTON_ORIENTATIONS.md#reading-orientation-metadata) | FMP accessor/example and regression coverage added; consumer replacement requires a rebuilt FMP artifact; preparatory migration is not upstream adoption | Retain the array until ProjectRed and Et Futurum migrations are released/adopted and a fresh scan clears legacy use |
|
||||
| `TRedstoneTile.openConnections(int)` | ProjectRed `e173952e96a4`: `transmission/redwires.scala` | Existing stable `IRedstoneTile.openConnections(int)` with the same mask/rotation logic; [guide](../api/TILE_TRAIT_ACCESS.md) | FMP source-access example and Forge coverage complete; consumer source patch/release pending | Retain the old runtime interface descriptor until adoption |
|
||||
| `TSlottedTile.v_partMap()` array mutation | OpenComputers `2c00f79be24b`: `PrintPart.toggleState` | `TileMultipart.refreshPartSlots(part)`; [equality, cache and notification contract](../api/TILE_TRAIT_ACCESS.md#refreshing-a-changed-slot-mask) | FMP API/example complete; consumer source patch/release pending, preserving validation and following sound/notify/packet/schedule order | Keep the live array/accessor ABI until released pack adoption; do not replace it with reflection or a whole-tile reload |
|
||||
| `TIInventoryTile.rebuildSlotMap()` raw trait call | AE2 `c690fbc273be`: `appeng/fmp/CableBusPart.notifyNeighbors` | `TileMultipart.refreshInventorySlots()`, a no-op without inventory parts, so the `instanceof` guard can go; [mapping and scope](../api/TILE_TRAIT_ACCESS.md#refreshing-inventory-slots) | FMP API, example and regression coverage complete; consumer source patch and release pending, keeping its neighbor notification afterward | Keep the `TIInventoryTile` interface and `rebuildSlotMap` until released pack adoption |
|
||||
| External Scala `LightMicroblock` registered through `MicroblockGenerator.registerTrait` | ProjectRed `e173952e96a4`: `illumination/lightmicroblocks.scala` | Java source trait registered by name, `IGeneratedMaterial`, typed sibling traversal and halo helper; [example](../api/MICROBLOCK_EXTENSIONS.md) | FMP example tested; consumer rewrite/release, existing config/halo wiring and physical-client checks pending | Retain external Scala trait ingestion until released-consumer adoption and internal Scala-trait removal |
|
||||
| `MultiPartRegistry$.registerParts(IPartFactory2, Seq)` and existing array calls | ProjectRed `e173952e96a4`: transmission, expansion and fabrication proxies | `MultiPartRegistry.registerPartFactory` with existing `IPartFactory2` methods and unchanged IDs | Source patch and release pending; Boolean-factory proxies separately need the two-method adapter described in the guide | No migrated pack version verified; retain all registration bridges and external trait support |
|
||||
| `MultiPartRegistry$.registerParts(Function2, Seq)` | ForgeRelocationFMP `49a810b8c63b`: proxy init registering `rfmp_frame` | `IPartFactory2` creating a fresh `FramePart` on both paths, registered through `registerPartFactory` | Source patch and release pending; preserve `rfmp_frame` and keep converter/pass-through registration | No migrated pack version verified; retain the function companion descriptor |
|
||||
| `MicroMaterialRegistry.getIdMap(): scala.Tuple2[]` | UtilitiesInExcess `3e107a1fe9bc15fcb6a808242ffda1354dac7c3a`: `FMPRecipeLoader.run`, `UEMultipartItem.getSubItems` | `materialCount()` with `materialName(int)` and, when needed, `getMaterial(int)` | Source patch and first released version pending; checkout used as reference only | No migrated pack version verified; retain the bridge |
|
||||
| `MicroMaterialRegistry.getIdMap(): scala.Tuple2[]` | Extra Utilities 1.2.12, active supported consumer: NEI and microblock material enumeration | Same ID-based Java enumeration | Keep current compatibility; switching support to UtilitiesInExcess awaits approval and pack adoption | Verify Extra Utilities is absent and its replacement uses the new API before retiring this dependency |
|
||||
| `TileMultipart.partList(): scala.collection.Seq` | ProjectRed `e173952e96a4`: illumination aggregation, packet indices and rendered-part lookup | `jPartList()` with unchanged indices, filters and aggregation | Source patch and release pending; Scala consumer code may remain Scala | No migrated pack version verified; retain the getter and external trait support |
|
||||
| `TileMultipart.partList(): scala.collection.Seq` | OpenComputers `2c00f79be24b`: cable/print/network searches and aggregation | `jPartList()` with the same search/aggregation semantics | Source patch and release pending | No migrated pack version verified; retain the getter |
|
||||
| `TileMultipart.partList(): scala.collection.Seq` | AE2 `fdedc3a8f023`: `FMPPlacementHelper.getPart` and `removePart` | Iterate `jPartList()`; retain last-match lookup and removal/break behavior | Source patch and release pending; September host-binding fix does not migrate traversal | No migrated pack version verified; retain the getter |
|
||||
| `TileMultipart.partList(): scala.collection.Seq` | Extra Utilities 1.2.12: multipart renderer iterators | Iterate `jPartList()` without adding detached-part filtering | Retirement/replacement pending | Confirm absence or migration in the target pack before retiring the getter |
|
||||
| `TileMultipart.partList(): scala.collection.Seq` and Scala loading | GuideNH `16f142417df1`: `Ae2ForgeMultipartBridge`, `ForgeMultipartHelpers` | `createPreviewTileFromNBT` for previews; `jPartList()` for remaining traversal | Direct calls replaced reflection in `4a0cd02e` (tags `1.3.33` onward); export/statistics use Java traversal, preview/AE2 paths still use Scala; setter call removed | Retain getter/loader for current source and setter for older supported jars; pack adoption unverified |
|
||||
| `TileMultipart.loadParts(scala.collection.Iterable)` exact reflection | Schematica `3b03ee937953`: `nbt.ForgeMultipart` | `MultipartHelper.createPreviewTileFromNBT`; [complete preview contract](../api/CLIENT_PREVIEW.md) | Source patch and release pending; replace the whole reconstruction chain rather than one reflected method | No migrated pack version verified; retain the Scala loader descriptor |
|
||||
| Private `MultiPartRegistry$` Scala `typeMap` field and `Map.get` / `Option` | Schematica `3b03ee937953`: `nbt.ForgeMultipart.init` and `createPart` | `MultipartHelper.createPreviewTileFromNBT`; factories opt in through `createPartForClientPreview` | Source patch/release pending; all-or-nothing lookup, client construction and loading are implemented | No migrated pack version verified; retain the exact private live Scala-map field |
|
||||
| `MultipartGenerator$.generateCompositeTile(TileEntity, scala.collection.Iterable, boolean)` | Schematica `3b03ee937953` exact reflection; GuideNH `16f142417df1` direct companion call | `createPreviewTileFromNBT` for saved previews; static `MultipartGenerator.generateCompositeTile` for other staged reconstruction | Java API migration pending in both consumers; GuideNH removed reflection but still passes Scala parts | No migrated pack version verified; retain the companion and Scala descriptor |
|
||||
| `MicroblockGenerator$.create(MicroblockClass, int, boolean)` and encoded shape copy | GuideNH `16f142417df1`: `promoteMicroblockToClient` directly calls companion and `shape_$eq(byte)` | `createPreviewTileFromNBT` for whole previews; static `MicroblockGenerator.create` and `setShape` for individual unbound parts | Reflection/private shape write removed in source; static Java/preview migration pending; validate client traits and shape callback ordering | No migrated pack version verified; retain companion singleton and exact descriptor |
|
||||
| Private `BlockMicroMaterial.block` / `meta` accessor mixin and reflective material query | GuideNH `16f142417df1`: `resolvePrimaryMicroblockId`; mixin removed | Direct `jPartList()`, `Microblock.material()`, `getMaterial(int)`, `BlockMicroMaterial.block()` / `meta()`; [typed example and policy differences](../api/MATERIAL_ACCESS.md) | Upstream cleanup uses existing public getters since `4a0cd02e`, included in tags `1.3.33` onward; published artifacts, custom getter behavior and optional loading not validated here | No migrated pack version verified; retain private fields for older releases |
|
||||
| Reflective mutation of `ButtonPart.metaSideMap` / `sideMetaMap` | Et Futurum Requiem `78a5744dfd33`: `compat.CompatMisc.runModHooksInit` | Two direct `ButtonPart.setOrientation(int, ForgeDirection)` calls; [mapping and lifecycle guide](../api/BUTTON_ORIENTATIONS.md) | FMP API/example complete; consumer source patch and first released version pending | Retain both public mutable arrays until the migrated release is in the target pack and a fresh scan confirms no legacy access |
|
||||
| `MicroblockProxy$.MODULE$` saw access and reflective mutation of private `ItemSaw.harvestLevel` | IguanaTweaksTConstruct `2bc09889d3e2`: `ClientFMPProxy.updateSawRenderers`, `IguanaFMPCompat.postInit` | Use static `MicroblockProxy.sawStone()` / `sawIron()` / `sawDiamond()` / `useSawIcons()`; read `harvestLevel()` and call `setHarvestLevel(int)`; [state and lifecycle guide](../api/SAW_STRENGTH.md) | FMP Scala-free API example complete; consumer source/lifecycle patch and first released version pending | Retain the companion and private field until the migrated release is in the target pack; ensure Iguana runs before ForgeMicroblock post-init and rescan for legacy access |
|
||||
| `NormalOcclusionTest$.apply(Traversable, Traversable)` | OpenComputers `2c00f79be24b`: `common.block.Cable.canConnectFromSideFMP`, `server.network.Network.canConnectFromSideFMP` | `NormalOcclusionTest.testBoxes(ownBounds.asJava, otherBounds)`; `otherBounds` already comes from Java `getOcclusionBoxes()` | Source patch and release pending; retain side/color/face filtering | No migrated pack version verified; retain the companion and descriptor |
|
||||
| `NormalOcclusionTest$.apply(Traversable, Traversable)` | ForgeRelocationFMP `49a810b8c63b`: `FramePart.occlusionTest` | `NormalOcclusionTest.testBoxes(boxes.asJava, getOcclusionBoxes)`; retain combined normal/partial/collision boxes and caller order | Source patch and release pending; preserve temporary face bounds and replacement protocol | No migrated pack version verified; retain the companion and descriptor |
|
||||
| `BlockMultipart.reduceMOP(MovingObjectPosition): scala.Tuple2` | GT5U `1a9469a13228`: `ColoredBlockContainer` ProjectRed wire branch, shipped in `5.09.54.205` | `BlockMultipart.hitPartIndex(hit)`, same index, `-1` when the hit carries none; [guide](../api/HIT_PART.md) | FMP API, example and regression coverage complete; consumer source patch and release pending, keeping its `ExtendedMOP` and coordinate guards | No migrated pack version verified; retain the exact static descriptor and boxed-`Integer` `_1()`; new in `2.9.0-RC-2` |
|
||||
|
||||
## Adoption constraints
|
||||
|
||||
The installed GTNH daily `2026-09-04+719` rescan scanned 241 jars, excluding FMP. Its 27 consumers retained
|
||||
all 386 full member/type/reflection rows from `+678`: 35 inherited types, 255 members, 76 other types and 20
|
||||
reflection strings. The `2.9.0-RC-2` rescan (240 jars, 28 consumers) keeps every `+678` member and type row and
|
||||
adds 13 members and 4 other types. GuideNH `1.3.41` replaced 17 reflection strings with direct links, and
|
||||
ThaumicEnergistics adds one. Source revisions above identify inspected checkouts, not guaranteed parity with newer jars.
|
||||
GuideNH's upstream material-access cleanup ships in RC-2's `1.3.41`, but none of its pending Java API migrations do. No consumer has been verified to have completed the full Java API
|
||||
migration; update artifact/adoption columns only with actual artifacts.
|
||||
|
||||
### Consumer-specific migration traps
|
||||
|
||||
- UtilitiesInExcess writes and loads its material name under `mat`, while `Content.createPart(String,
|
||||
NBTTagCompound)` reads `material`. Fix the consumer factory before testing save/load or replacement adoption. FMP
|
||||
must not add a fallback that hides the consumer's inconsistent persistent format.
|
||||
- Galacticraft selects the first public `MicroMaterialRegistry.registerMaterial` method by name without checking its
|
||||
parameters. Keep exactly one compatible public method with that name until Galacticraft migrates; the reflection
|
||||
compatibility test pins this constraint.
|
||||
- AE2's `FMPPlacementHelper.getPart` scans the whole part list and retains the last matching `CableBusPart`. Replacing
|
||||
that loop with a first-match helper changes behavior. Iterate `jPartList()` and preserve the original selection and
|
||||
removal rules.
|
||||
- MatterManipulator and ForgeRelocationFMP both move the same live `TileMultipart`, but they own different validation,
|
||||
render, lighting and packet policies. A future common move coordinator belongs in `MultipartHelper`, which already
|
||||
owns cross-tile NBT and description-packet operations; `TileMultipart.onMoved()` remains the per-tile callback. Add
|
||||
such a coordinator only when both consumers can express their existing synchronization policy through it.
|
||||
- Waila, AE2 Fluid Craft and ThaumicEnergistics use `Class.forName` as an optional-mod loading boundary. That class lookup is intentional;
|
||||
replacing it with a direct FMP type would make their otherwise optional integration load eagerly.
|
||||
- GT5U `5.09.54.205` (in `2.9.0-RC-2`) is the first consumer to call `BlockMultipart.reduceMOP`. It needs only
|
||||
the part index, which `hitPartIndex` returns as an `int`. Add a named result only if a second consumer needs the
|
||||
rebased hit. Keep the `Tuple2` descriptor, and its boxed-`Integer` `_1()` that GT5U casts, until a migrated GT5U
|
||||
release ships.
|
||||
|
||||
- FMP's own `ItemMicroPart` and `MicroRecipe$` still use legacy material arrays. Internal tuple paths also remain
|
||||
in the generator and placement code, including `MicroblockPlacement.gtile()`. External adoption does not retire them.
|
||||
- Existing `jPartList()` users need no rename. `forEachPart` filters detached/rebound parts and must not replace
|
||||
arbitrary read/query loops. It delegates through the supported `operate(Function1)` override hook, which lifecycle
|
||||
callbacks still use. See [traversal](../api/PART_TRAVERSAL.md).
|
||||
- `setPartList` copies non-null list storage; the legacy setter retains the supplied sequence. Neither binds parts.
|
||||
Use `loadPartList` for prepared reconstruction, preserving world/position setup and subsequent notifications.
|
||||
See [loading and storage](../api/PART_LOADING.md).
|
||||
- No direct supplied consumer call to the two-argument tile `occlusionTest` was found, but generated
|
||||
`TPartialOcclusionTile` and placement/replacement dispatch still require it. `canAddPart`/`canReplacePart` callers
|
||||
need no rename and must retain outgoing-part exclusion. Box-list queries are a separate contract;
|
||||
[testOcclusion and testBoxes](../api/OCCLUSION.md) do not retire each other's bridges.
|
||||
- `registerPartFactory` avoids Scala-dependent Java overload resolution. Preserve registration IDs, order,
|
||||
ownership, partial-registration failure policy, and both NBT/packet construction paths. All legacy registration
|
||||
entries remain; Schematica's private live Scala map is a separate dependency. See [registration](../api/PART_REGISTRATION.md).
|
||||
- No supplied direct legacy render-ID or tuple-result conversion caller was found (GT5U's `reduceMOP` tuple is
|
||||
covered above). Existing tile-only `getOrConvertTile` users
|
||||
need no rename. New [render-ID](../api/RENDER_ID.md) accessors do not allocate/register a renderer;
|
||||
[conversion results](../api/TILE_CONVERSION.md) still describe uninstalled placeholders.
|
||||
- Saved client previews should use the complete [preview helper](../api/CLIENT_PREVIEW.md). The lower-level
|
||||
[staged generator](../api/COMPOSITE_GENERATION.md) still does not copy/load/install parts automatically and remains
|
||||
available for reconstruction flows that need candidate reuse or custom setup.
|
||||
- GuideNH's [typed material getters](../api/MATERIAL_ACCESS.md) likewise honor overrides that raw mixin fields
|
||||
bypassed. Preserve first-usable-part order, export filtering and failure behavior; validate custom overrides and
|
||||
optional-mod loading. Physical-client construction and GPU previews remain release checks.
|
||||
- Iguana must apply [saw strength](../api/SAW_STRENGTH.md) before ForgeMicroblock's post-init maximum calculation.
|
||||
Et Futurum's [orientation setter](../api/BUTTON_ORIENTATIONS.md) maintains both inverse maps; keep the legacy
|
||||
private field/public arrays until the respective released integrations are adopted.
|
||||
|
||||
## API boundary audit
|
||||
|
||||
Rechecked 2026-09-05 across 28 source checkouts, active Extra Utilities compatibility and the installed `+719`
|
||||
constant-pool inventory. No external calls were found to the 15 tile/material-registry implementation hooks listed
|
||||
in the [API boundary table](../API.md#supported-api-and-internal-hooks). Searches covered FMP-importing Java/Scala,
|
||||
method names and reflective strings; historical GuideNH comments avoiding `from`/`copyFrom` and WR-CBE's unrelated
|
||||
`RenderWireless.loadIcons` were excluded. This is evidence about the audited references, not every possible mod.
|
||||
|
||||
Supported exceptions are OpenComputers `2c00f79be24b`, `PrintPart.scala:171`, clearing slots before
|
||||
`tile.bindPart(this)`, and ProjectRed `e173952e96a4`, `gatepartrs.scala:74`, calling `internalPartChange(this)`
|
||||
between packet/dirty work and selective neighbor notification. Cache binding neither places nor rebinds a part
|
||||
and is not universally idempotent. Local part notification does not perform world updates. Internal markers change
|
||||
no descriptor and authorize no removal; `operate`, `getOrConvertTile2` and material `loadIcons` retain their
|
||||
separate legacy/extension contracts.
|
||||
|
||||
## Extension and converter migration
|
||||
|
||||
- The [illuminated Java microblock example](../api/MICROBLOCK_EXTENSIONS.md) uses name-based registration and
|
||||
`IGeneratedMaterial`. Register before input-class loading; keep inherited access in an ordinary helper with
|
||||
`Object` parameters and dispatch through the stable base. It preserves metadata 16–31, cutter metadata modulo
|
||||
16, all-shape selection, strict sibling filtering, light rounding/capping, pass-zero halos and hollow trimmed strips,
|
||||
without new part NBT/packet fields. Headless client-body probes do not replace physical-client construction,
|
||||
configuration/halo integration and released ProjectRed adoption.
|
||||
- Existing `IPartConverter`/`registerConverter` users need no replacement API; companion users can use the static
|
||||
entry. Preserve separate factories, IDs, Chisel metadata selection, ForgeRelocationFMP frame construction,
|
||||
OpenComputers original-tile lookup, AE2 state copying and consumer-specific cleanup. The
|
||||
[converter guide](../api/BLOCK_CONVERTERS.md) covers lifecycle; actual inventory/network transfers need integration checks.
|
||||
- Raw trait classes become interfaces at runtime. ProjectRed should query `IRedstoneTile.openConnections` while
|
||||
preserving rotation/masks; OpenComputers should use `refreshPartSlots` while preserving validation and subsequent
|
||||
sound/notify/packet/schedule order; AE2 should call `refreshInventorySlots` before its neighbor notification. Keep their legacy runtime interfaces until adoption. See
|
||||
[stable tile access](../api/TILE_TRAIT_ACCESS.md).
|
||||
- The [custom tile-trait guide](../api/CUSTOM_TILE_TRAITS.md) covers a top-level Java input, separate marker/capability
|
||||
interfaces and ordinary helpers. Stateful extensions still own copy, persistence, synchronization and lifecycle
|
||||
behavior. No direct custom multipart tile-trait registration was found in supplied consumer source; built-in traits,
|
||||
pass-through interfaces and ProjectRed's microblock registration are distinct paths. Example coverage does not
|
||||
authorize retirement of any existing consumer contract.
|
||||
@@ -0,0 +1,224 @@
|
||||
# Java migration divergences
|
||||
|
||||
Current intentional differences from the `1.7.12` Scala reference. Upstream `master` fixes merged since then
|
||||
(through `1.8.0`) are ported; rows naming an upstream PR record whether the Java fix matches it.
|
||||
This is a compatibility ledger, not a port diary.
|
||||
An unchanged implementation needs no entry. Track remaining work in [migration status](README.md), client gaps in
|
||||
[manual release checks](MANUAL_CHECKS.md), and use the [performance protocol](MAINTAINERS.md#performance-validation)
|
||||
for measurements. Superseded decisions and per-port narratives remain in git history.
|
||||
|
||||
“No audited consumer” means the frozen GTNH binary inventory and consumer-source audit, not every possible
|
||||
third-party mod. Removed members can still break unaudited consumers. Check
|
||||
`docs/migration/COMPATIBILITY.md`, which holds both the binary inventory and the consumer-source
|
||||
audit, before extending this list.
|
||||
|
||||
## Runtime and error behavior
|
||||
|
||||
The multipart block intentionally retains the pre-PR #54 unlocalized name `tile.multipart`.
|
||||
PR #54 (`2d050bd`) renamed it to `tile.codechicken/multipart`; `cb3bef7` reverted that part to preserve
|
||||
the established name. The block registry ID remains `ForgeMultipart:block`. This is an intentional rollback
|
||||
of the later upstream rename, not a divergence from the `1.7.12` reference.
|
||||
|
||||
| Area | Difference and consequence |
|
||||
| --- | --- |
|
||||
| Raw microblock recipe material lookup | Skips `MissingMicroMaterial`, whose recovery item is stone, so sawing stone selects the real stone material. Existing missing-material microblocks retain their recovery behavior. This fixes a pre-existing Scala bug, also fixed upstream in PR #61. |
|
||||
| `BlockMicroMaterial.icont()` after a texture stitch | `loadIcons` still builds icons eagerly, then marks them stale; the first `icont()` read after the stitch re-reads the block's icons once. Icons that another mod finishes in a later `TextureStitchEvent.Post` handler (Chisel's CTMLib `-v4` submaps) are picked up instead of rendering as missing or previous-stitch textures. Icons assigned through `icont_$eq` are kept. Upstream PR #63 targets the same bug by lowering the stitch handler to `EventPriority.LOW`; this port does not need that ordering. |
|
||||
| Client part additions | Reuses an existing multipart tile or creates one without converting the stale client block. Conversion and its outgoing packets remain server-side, avoiding duplicate parts and client disconnects. Matches upstream PR #62. |
|
||||
| `BlockMicroMaterial.createAndRegister(Block, Seq, String)` | Registers every supplied metadata value instead of only zero, including dark-oak logs and leaves and their legacy-name remaps. This fixes a pre-existing Scala bug; material IDs are rebuilt through the existing registry mapping. |
|
||||
| Chunk scheduled-tick restoration | Reactivates chunks with restored scheduled ticks so their callbacks resume at the saved deadlines. The Scala implementation restored entries without activating their chunk. NBT layout and duplicate-scheduling behavior are unchanged. |
|
||||
| Scheduled ticks of moved tiles | `TileMultipart.onMoved` hands its parts' pending scheduled and random ticks to the chunk that now contains the tile, keeping their deadlines; moves requested from a tick callback apply after that tick's processing. The Scala implementation left them in the source chunk, so they were lost if it unloaded first, and were saved at the wrong position. Same-world moves only. This fixes a pre-existing Scala bug. |
|
||||
| World scheduler clock loading | Retains successfully loaded `schedTime` instead of overwriting it with total world time. Missing or unreadable files still fall back to world time. This fixes a pre-existing Scala bug and preserves the clock used by saved absolute tick deadlines; the file format is unchanged. |
|
||||
| Converted tile loading | Copies the source tile coordinates to a replacement produced by `MultipartSaveLoad.loadTiles` before assigning its world and validating it. The Scala implementation left converted replacements at their default coordinates. |
|
||||
| Placement-modifier player lifecycle | Removes cached control-key state when a player logs out and transfers it from the old player object to its replacement on clone. The Scala implementation retained entries until server shutdown. |
|
||||
| `IDWriter` before `setMax` | `read`/`write` throw `IllegalStateException` instead of `NullPointerException`. Uninitialized use is unsupported. |
|
||||
| `PacketScheduler` invalid `maskWidth` | Throws `IllegalArgumentException` instead of `scala.MatchError`. Valid widths remain 1, 2, 4 and 8. |
|
||||
| `NormalOcclusionTest.apply(Traversable, Traversable)` | Materializes both inputs into Java lists before testing instead of nested Scala `forall`. Finite, side-effect-free collections give the same result; eager traversal can change side effects, failure timing and termination for unusual inputs. |
|
||||
| `MultipartRenderer` dynamic-part guard | Uses short-circuit `\|\|` instead of `\|`; the second getter is no longer evaluated when the first operand succeeds. Ordinary getters give the same render decision. |
|
||||
| `ControlKeyModifer.map()` | The exposed Java map has no Scala default-value wrapper: an absent key returns null from `get`, not false from Scala `apply`. Use `isControlDown` for the unchanged absent-means-false behavior. |
|
||||
| Public companion constructors, including `ASMImplicits.ExtBitSet$` / `ExtClass$` | Explicit construction creates an independent instance instead of replacing `MODULE$`. Java initializes the retained final module field in its static initializer; use `MODULE$` for singleton identity. |
|
||||
| `registerJavaTrait` abstract inputs | Abstract Java classes are accepted instead of throwing `IllegalArgumentException`. Declared abstract methods become generated-interface contracts without helper bodies; a later mixin must implement them before those members can be invoked. A no-argument abstract-mixin constructor may call an argument-taking superclass constructor; registration discards that direct call and its argument evaluation because the composite invokes the real base constructor first. This enables Java microblock mixins without changing existing concrete registrations. |
|
||||
| `registerJavaTrait` members annotated `@SideOnly` | The old Java path ignored the annotation. It now omits opposite-side fields and methods from generated metadata and output, matching Forge and the Scala-trait path; visible and invisible annotation tables are both accepted. If the no-argument constructor is absent, including after Forge has already stripped it, an empty `$init$` preserves the generated initializer contract without running its body. Current-side members are unchanged. No audited Java registration relied on the old retention. |
|
||||
|
||||
Concrete collection implementations also change without changing the declared `java.lang.Iterable`/`List` contracts:
|
||||
|
||||
| Return path | Reference → Java |
|
||||
| --- | --- |
|
||||
| `JCuboidPart.getSubParts` / `getCollisionBoxes` | Scala `Seq` adapter → immutable `Collections.singletonList` |
|
||||
| `MultipartHelper.IPartTileConverter.convertMulti` default | Scala `Seq` adapter → `Collections.emptyList` / `singletonList` |
|
||||
| `Microblock.getDrops` | Java view of Scala `ListBuffer` → mutable `ArrayList` |
|
||||
|
||||
Code depending on concrete collection classes or their exact mutation failure behavior must adapt.
|
||||
|
||||
## Removed or changed binary surface
|
||||
|
||||
These removals were accepted because neither audit identified a consumer of the removed surface. This does not
|
||||
authorize removing other members of the same type.
|
||||
|
||||
| Area | Removed or changed surface |
|
||||
| --- | --- |
|
||||
| `IDWriter` | Removed `write()`, `write_$eq(Function2)`, `read()` and `read_$eq(Function1)`. Use the Java methods listed below. |
|
||||
| Both registries | `MicroMaterialRegistry.readIDMap` and `MultiPartRegistry$.readIDMap` return `java.util.List<String>` instead of `scala.collection.Seq<String>`; the return descriptor changes. |
|
||||
| Registry compiler accessors | Removed `MicroMaterialRegistry`'s public mangled `$$idMap()`, `$$typeMap()` and `$$nameMap()` accessors, and the five `codechicken$multipart$MultiPartRegistry$$...()` accessors. Schematica's separate private `MultiPartRegistry$.$$typeMap` **field is retained** as a live Scala-map view; it is not one of the removed methods. |
|
||||
| `NormallyOccludedPart` | Removed the inferred `getType(): scala.runtime.Null$` overload; the `String` method remains. |
|
||||
| `MissingMicroMaterial` | Removed static `canRenderInPass(int)` and `isSolid()` forwarders. The companion no longer declares these methods but inherits the interface defaults. |
|
||||
| `TileMultipart` | Removed compiler accessor `protected$worldObj(TileMultipart)`. |
|
||||
| `BlockMultipart` | Removed `hasTileEntity$default$1()`; source callers must supply metadata explicitly. |
|
||||
| `TileCache` | `map()` now returns Java `Map`; `add`/`remove` return `void` instead of Scala `Option`; `apply(BlockCoord)` returns a nullable `FlaggedTile` instead of `Option`. |
|
||||
| `TileCache.FlaggedTile` | Dropped Scala case-class `copy`, copy-default getters, `canEqual`, value `equals`/`hashCode`/`toString`, product methods, and `scala.Product`/`scala.Serializable`. It now has ordinary object identity semantics; `t()` and `removed()` remain. |
|
||||
| `ControlKeyModifer` | Replaced `isClientPressing_$eq(boolean)` with `setClientPressing(boolean)`; `map()` returns Java `Map<EntityPlayer, Boolean>` instead of Scala mutable `Map`; removed `playerControlValue(EntityPlayer)` and its implicit wrapper type. |
|
||||
| `ControlKeyHandler` | Former static facade is now a `KeyBinding` subclass with `INSTANCE`. `wasPressed`/`tick` are instance methods, and the twelve inherited-KeyBinding static forwarders disappear. Initializing this client-only class now initializes its binding. |
|
||||
| `MultipartRenderer` | Removed inherited-TESR static forwarders `func_147498_b`, `func_147496_a` and `func_147497_a`. |
|
||||
|
||||
Removed named helpers and companions (besides private compiler artifacts covered below):
|
||||
|
||||
- `JPartialOcclusion$class`, including `allowCompleteOcclusion` and `$init$`.
|
||||
- `MicroMaterialRegistry$IMicroMaterial$class` and its four statics.
|
||||
- `TRandomUpdateTick$class`, including `onWorldJoin` and `$init$`.
|
||||
- `TScheduledPacketPart$class` and `PacketScheduler$`.
|
||||
- `IconHitEffects$`.
|
||||
- `TileCache$` and `TileCache$FlaggedTile$`.
|
||||
- `ControlKeyModifer$`, `ControlKeyModifer$ControlKeyValue` and `ControlKeyHandler$`.
|
||||
- `codechicken.multipart.package` / `package$` and `codechicken.microblock.package` / `package$`.
|
||||
Their logger aliases are replaced by the corresponding proxy's `logger()`.
|
||||
|
||||
Generated-tile helpers removed only from the **raw artifact** are listed separately below; Forge recreates them.
|
||||
Other retained `$class` bridges and `MODULE$` companions are not covered by this removal decision.
|
||||
|
||||
## Additions and default-method changes
|
||||
|
||||
| Area | Additive Java entry points |
|
||||
| --- | --- |
|
||||
| `IDWriter` | `write(MCDataOutput, int)` and `read(MCDataInput)` |
|
||||
| `JCuboidPart` | Static `subParts`, `collisionBoxes` and `renderBreaking` implementations for explicit forwarding |
|
||||
| `JItemMultiPart` | Static `hitDepth` and `onItemUse(part, ...)` implementations |
|
||||
| `MicroMaterialRegistry` | Static `setupIDMap`, `calcMaxCuttingStrength` and `loadIcons` forwarders |
|
||||
| `PacketScheduler` / `TScheduledPacketPart` | Static `sendScheduled()` on the facade and `readMask(part, packet)` on the interface |
|
||||
| `TileMultipart` | `hasDynamicParts` (false by default), `renderStatic`, `renderDynamic` and `randomDisplayTick` hooks for dispatching generated overrides through a stable superclass |
|
||||
| `MultipartMixinFactory` | Four additional static forwarders: `onCompiled`, `autoCompleteJavaTrait` and the two mangled `ASMMixinFactory` parent helpers. Scala emitted them when the base became Java with its original public JVM access; the Java facade retains them. Existing facade entries are unchanged. |
|
||||
| `MultipartEventHandler` / `MultipartEventHandler$` | Public `playerLoggedOut(PlayerLoggedOutEvent)` and `playerCloned(PlayerEvent.Clone)` event handlers for placement-modifier state cleanup and transfer |
|
||||
| `MultipartHelper` | `createPreviewTileFromNBT(World, NBTTagCompound)` builds an uninstalled client composite directly from saved multipart NBT and rejects unsupported parts as a whole |
|
||||
|
||||
Previously abstract JVM interface methods now have Java defaults, allowing inheritance without Scala forwarders:
|
||||
|
||||
| Interface | Default methods |
|
||||
| --- | --- |
|
||||
| `JPartialOcclusion` | `allowCompleteOcclusion` |
|
||||
| `TFacePart` | `solid`, `redstoneConductionMap` |
|
||||
| `JIconHitEffects` | `getBreakingIcon` |
|
||||
| `TItemMultiPart` | `getHitDepth` |
|
||||
| `TEdgePart` | `conductsRedstone` |
|
||||
| `Saw` | `getMaxCuttingStrength` |
|
||||
| `MicroMaterialRegistry.IMicroMaterial` | `loadIcons`, `canRenderInPass`, `isSolid` |
|
||||
| `TScheduledPacketPart` | `writeScheduled`, `readScheduled` |
|
||||
| `PlacementGrid` | `render`, `drawLines`, `glTransformFace` |
|
||||
| `MultiPartRegistry.IPartFactory2` | `createPartForClientPreview`; defaults to unsupported, while legacy Boolean/function adapters and built-in microblock factories construct their client variant |
|
||||
|
||||
`ItemSaw` consequently no longer declares `getMaxCuttingStrength`; ordinary calls still resolve to the default,
|
||||
but declared-member reflection differs. The same distinction applies to the two `MissingMicroMaterial$` methods above.
|
||||
|
||||
The `TNormalOcclusion` super accessor
|
||||
`codechicken$multipart$TNormalOcclusion$$super$occlusionTest(TMultiPart)` additionally loses `ACC_SYNTHETIC` and
|
||||
becomes a default returning true, so javac can see and implement it. `NormallyOccludedPart` inherits it rather than
|
||||
declaring its own. Existing Scala binaries retain their explicit super-chain overrides.
|
||||
|
||||
## Recompiling Scala consumers
|
||||
|
||||
Binary descriptors alone do not preserve Scala source semantics after `ScalaSignature` metadata is removed.
|
||||
|
||||
### Trait composition
|
||||
|
||||
A Java interface cannot supply a Scala trait's class supertype or its linearization. A superclass method wins over
|
||||
an interface default, so recompiling `extends TMultiPart with TCuboidPart` silently selects the empty superclass
|
||||
methods. Explicit forwarding is required where the implementation remains abstract:
|
||||
|
||||
| Trait | Source migration |
|
||||
| --- | --- |
|
||||
| `TCuboidPart` | Extend `JCuboidPart`, or forward subparts, collision boxes and breaking rendering to its statics. |
|
||||
| `TNormalOcclusion` | Explicitly combine `NormalOcclusionTest.apply(this, other)` with the intended super chain. Audit existing `super.occlusionTest` calls too: they no longer route through the old trait. |
|
||||
| `TIconHitEffects` | Explicitly forward `addHitEffects` and `addDestroyEffects` to `IconHitEffects`. |
|
||||
| `TItemMultiPart` | Explicitly forward `onItemUse` to `JItemMultiPart`; the inherited Item method otherwise wins. |
|
||||
| `TRandomUpdateTick` | Explicitly implement `onWorldJoin` with `TickScheduler.loadRandomTick(this)`. |
|
||||
| `TScheduledPacketPart` | Explicitly forward `read` to `TScheduledPacketPart.readMask(this, packet)`. |
|
||||
| `ScratchBitSet` | Implement both methods and storage accessors, and initialize storage explicitly; the retained `$class` helper supplies the original implementations. |
|
||||
|
||||
Previously compiled calls to **retained** `$class` bridges still link. This does not apply to the removed helpers above.
|
||||
|
||||
### Source syntax and generic signatures
|
||||
|
||||
- An object used as a value now needs `X$.MODULE$` where that companion is retained (event handlers, proxies,
|
||||
recipes, packet handlers, materials and generators). Static calls alone do not supply a singleton value.
|
||||
- Object-application sugar becomes explicit `.apply(...)`, e.g. `NormalOcclusionTest.apply(...)` and
|
||||
`MicroblockPlacement$.MODULE$.apply(...)`.
|
||||
- `ASMImplicits` no longer provides Scala implicit/value-class syntax. Use `nodeName(clazz.getName)` and
|
||||
`ExtBitSet$.MODULE$.copy$extension(bits)` explicitly, or construct its retained Java wrappers. Existing boxed and
|
||||
`$extension` binary entry points remain; implicit conversion requires Scala metadata Java cannot emit.
|
||||
- Scala property assignment needs the explicit Java-authored `_$eq(...)` method, e.g. `renderID`, `loadingWorld`,
|
||||
`angelicaCompat` and microblock `shape`.
|
||||
- `ByteCodeReader.advance(length)(value)` becomes `advance(length, value)` when recompiling Scala. Argument
|
||||
evaluation remains eager, and previously compiled calls retain the same binary descriptor.
|
||||
- `ASMMixinFactory` constructor parameters and `construct` arguments need an explicit Scala `Seq`, not Scala
|
||||
varargs syntax. Overrides of `onCompiled` and `autoCompleteJavaTrait` must be public: Java preserves their original
|
||||
public JVM access without Scala's protected-source metadata.
|
||||
- `tile.partList(i)` becomes `tile.partList.apply(i)`. Static bounds getters on Face, Corner, Edge and Post factories
|
||||
need `aBounds()(index)` instead of `aBounds(index)`; Java no-argument methods may need explicit parentheses.
|
||||
- `TileMultipart.getOrConvertTile2` exposes `Tuple2<TileMultipart, Object>` instead of a Scala-typed Boolean second
|
||||
element; source callers need a cast. Scala 2.11 callbacks to `operate(Function1<..., BoxedUnit>)` need an explicit
|
||||
`AbstractFunction1` instead of the previous Unit-returning lambda adaptation.
|
||||
- The Face, Corner, Edge, Post and Hollow factory **companions** widen `baseTrait` to
|
||||
`Class<? extends Microblock>` from their specific trait type. Their static facades retain the specific generic
|
||||
type, and the raw JVM return descriptor remains `Class`.
|
||||
- `MultiPartRegistry.registerParts(IPartFactory, String[])` and the `IPartFactory2` array overload gain Java varargs
|
||||
flags. `BlockMultipart.addCollisionBoxesToList` uses raw `List` rather than `List<?>` to override vanilla. Neither
|
||||
changes its raw JVM descriptor.
|
||||
|
||||
## Generated tile traits: raw artifact versus Forge runtime
|
||||
|
||||
These ports replace Scala interfaces/helpers with concrete Java mixin inputs. Forge rewrites the inputs back into
|
||||
interfaces and generates implementation helpers. Existing binaries retain the runtime interface calls, but code
|
||||
recompiled against the **untransformed dev jar** may emit `invokevirtual` or `getfield` against a type that becomes
|
||||
an interface, causing verification/linkage failures. A transformed compile stub or explicit source guidance is
|
||||
required before claiming source-compatible downstream rebuilds.
|
||||
|
||||
| Raw artifact change | Affected types |
|
||||
| --- | --- |
|
||||
| Interface + `$class` → concrete `TileMultipart` subclass | `TSlottedTile`, `TRedstoneTile`, `TTileChangeTile`, `TFluidHandlerTile`, `TileMultipartClient` |
|
||||
| Interface + `$class` → concrete child mixin input | `TRandomDisplayTickTile` (extends the registered `TileMultipartClient` input) |
|
||||
| Removed raw `TIInventoryTile$class`; moved implementation into `JInventoryTile` input | `TIInventoryTile` itself remains a Java interface. Source consumers should target it, not the transformed `JInventoryTile` class. |
|
||||
|
||||
Inherited/foreign-field and callback workarounds add package-private access shims for redstone, tile-change,
|
||||
fluid, inventory and both client traits; they are not new consumer APIs. Transformer constraints and shim recipes
|
||||
are documented in the [maintainer guide](MAINTAINERS.md#trait-and-dispatch-rules).
|
||||
|
||||
The client-trait port also deliberately extends the Java-trait transformer:
|
||||
|
||||
- Registered Java traits may extend an already registered Java trait; the parent runtime interface participates in
|
||||
hierarchy and linearization. A child's `super` call dispatches to the parent trait's implementation, or to the
|
||||
base class when the parent trait does not override that method.
|
||||
- Explicit field accessors are recognized rather than duplicated.
|
||||
- Transient input fields are excluded from automatic `copyFrom`. Client render caches use this opt-out; their
|
||||
generated runtime fields remain ordinary private fields.
|
||||
|
||||
## Shared classfile differences
|
||||
|
||||
These are accepted once for the migration, not repeated for every otherwise equivalent port:
|
||||
|
||||
- Java-authored types lose Scala signature/marker attributes and use Java source-file/debug metadata. Static facades
|
||||
and helper classes gain private constructors where Scala emitted none. Java class initializers lack Scala's
|
||||
`ACC_PUBLIC`, and singleton publication follows Java initialization rather than Scala's constructor assignment.
|
||||
- Unreferenced Scala `$$anonfun$`/anonymous implementation classes and private compiler accessors disappear or are
|
||||
replaced by Java helpers/lambdas. Their names are not supported API. This does **not** include named compatibility
|
||||
bridges or reflective fields: audit those individually. Retained Scala traits still emit their required helpers.
|
||||
- The `Object[]` renderer bridges on `ItemMicroPartRenderer$` and `ItemSawRenderer$` are ordinary Java methods rather
|
||||
than synthetic Scala methods; signatures and dispatch remain available.
|
||||
- The private scratch `ThreadLocal` fields on `MicroblockGenerator$` and `MultipartGenerator$` lose `ACC_FINAL` so
|
||||
their public Scala-trait setters can still replace storage.
|
||||
- The private `ItemSaw.harvestLevel` field loses `ACC_FINAL` so `setHarvestLevel(int)` can update the same storage as
|
||||
the retained getter and old Iguana reflection. Its name, type and visibility remain unchanged.
|
||||
- TickScheduler's private Scala scheduler types become package-private static nested Java classes, retaining their
|
||||
binary names.
|
||||
|
||||
## Updating this ledger
|
||||
|
||||
Add only a new effective runtime, binary, source or classfile difference, with its consequence and reason for
|
||||
acceptance. Amend an existing row when a later change supersedes it. Do not add passing test counts, unchanged
|
||||
behavior, build observations, performance claims or a “no divergence” section for each new port.
|
||||
@@ -0,0 +1,149 @@
|
||||
# ForgeMultipart maintainer constraints
|
||||
|
||||
These constraints explain the retained build and runtime machinery. Consumer migration belongs in the
|
||||
[adoption ledger](COMPATIBILITY.md#java-api-adoption-ledger); remaining release checks belong in
|
||||
[MANUAL_CHECKS.md](MANUAL_CHECKS.md). Keep this guide about current mechanisms, not completed-port history.
|
||||
|
||||
## Build and runtime boundaries
|
||||
|
||||
- Preserve a Java 8 artifact with equivalent startup, gameplay, serialization and network behavior. The target
|
||||
modern-runtime policy spans Java 17–26; validate packaged releases on the selected supported runtime. Equal
|
||||
throughput across Java versions is not required. The deobfuscated Forge test runner uses Java 8; the current
|
||||
modern dedicated-server run tasks are not a substitute for packaged validation.
|
||||
- Keep `enableModernJavaSyntax = false` while Scala 2.11.5 remains. Normal Java and joint Scala/Java compilation
|
||||
use Java 8. Helpers importing retained Scala models belong in the joint `src/main/scala` source set because
|
||||
`compileJava` runs before those Scala types exist.
|
||||
- `scalaCompileOptions.force = true` prevents stale `Tags.VERSION` constants in joint-compiled Java `@Mod`
|
||||
annotations. Zinc otherwise misses those consumers when the generated constant changes. Verify all five mod
|
||||
annotations in dev/release artifacts against their artifact version; replace the guard only with equivalent coverage.
|
||||
- Keep registered trait inputs and compatibility facades conservative. Moving `RedstoneInteractions$` or
|
||||
`BlockMultipart` pulls transformer-sensitive dependencies; `RenderPartResolver` is needed by joint compilation
|
||||
before Java helpers that use it. The explicit `Microblock` cast in `PostMicroblockTraitLogic` is required by the
|
||||
retained Scala declaration.
|
||||
- GTNHLib is compile-only here. Its fastutil compile classpath does not grant a runtime dependency. Declare that
|
||||
dependency explicitly before using fastutil in ordinary code; require profiling evidence for such a change.
|
||||
|
||||
## Retained compiler constraints
|
||||
|
||||
- Scala multiple-trait inheritance still needs metadata. Java registration incorporates an already registered
|
||||
superclass trait, not implemented Scala interfaces. `CommonMicroblockClient` combines three parents, including
|
||||
`TMicroOcclusionClient`. Preserve state/accessor/super bridges until a characterized replacement exists.
|
||||
- ProjectRed's external `LightMicroblock` requires ScalaSignature ingestion, `$class` helpers and generated
|
||||
dispatch until its replacement is released and adopted. Abstract Java mixins and side filtering do not remove
|
||||
that requirement, nor FMP's internal Scala trait inputs.
|
||||
- ScalaSignature primitive literal `value()` methods coexist with erased `Object value()` bridges that Java
|
||||
source cannot declare together. Five generic inner-construction branches require exact outer-instance bindings.
|
||||
Preserve inferred Scala return types too: an explicit type can alter ScalaSignature without changing a JVM descriptor.
|
||||
- Javac interprets nested `ClassInfo$` names and `IterableLike.view()` differently from scalac. Keep construction
|
||||
callbacks, the initial Scala `.view`, lazy builders and virtual dispatch; avoid path-dependent symbols or generated
|
||||
companion classes in Java-callable signatures. Joint helpers resolve `ASMMixinCompiler$.MODULE$` internally.
|
||||
- Scala 2.11.5 rejects a Java class beside its same-name Scala object. Port `StackAnalyser`'s class, companion,
|
||||
model and serialization contracts together, rather than splitting their public shapes mechanically.
|
||||
- Preserve characterized algorithm quirks during mechanical conversion: primitive `NEWARRAY` throws
|
||||
`MatchError: 188`, wide arguments can misindex `getSuper`, and Scala `String` aliases decode as
|
||||
`Lscala/Predef/String;`. Successful external fixtures use `java.lang.String`; fix these separately with regressions.
|
||||
- Metadata keys distinguish dotted/slashed names; byte-cache publication normalizes and invalidates only that key.
|
||||
Parse failures retain bytes, null results are cached, load failures retry, and dump failures follow publication.
|
||||
Ordinary duplicate `define` errors remain reflection-wrapped; direct LinkageError handling is case-sensitive and
|
||||
its null-message behavior is characterized. Do not silently alter these during extraction.
|
||||
|
||||
## Trait and dispatch rules
|
||||
|
||||
- A superclass method wins over a Java interface default, silently bypassing former Scala trait behavior. Audit
|
||||
implementors and existing `super` call sites; `PostMicroblock.occlusionTest` is a concrete example. Recompiled
|
||||
implementors may also lose Scala-generated forwarders when a trait gains a default.
|
||||
- A Scala trait extending a class is only an interface in bytecode. Synthetic super accessors are invisible to
|
||||
javac. Preserve required non-synthetic bridges; retained Scala super calls can stay in Scala using the existing
|
||||
result-code pattern instead of eager callbacks. `TScheduledPacketPart.readMask` is the static-helper pattern for
|
||||
a trait method shadowed by a superclass.
|
||||
- `private[multipart]` reaches sibling packages, so Java package-private is not equivalent. Keep required public
|
||||
descriptors and companion-only methods. Check reflective string names as well as bytecode references before
|
||||
removing companions; `MultipartHelper$` is a reflective dependency.
|
||||
- Common Java must not use a side-stripped static facade. `MultipartProxy$.MODULE$.postInit()` retains virtual
|
||||
server fallback; the corresponding static forwarder is stripped on dedicated servers.
|
||||
- Registered Java trait classes become interfaces at runtime. Consumer calls must use stable base/capability
|
||||
types, not raw class/field opcodes. See [tile access](../api/TILE_TRAIT_ACCESS.md) and
|
||||
[custom trait authoring](../api/CUSTOM_TILE_TRAITS.md).
|
||||
- Put inherited calls, inherited field access, argument-owned field access and primitive-array allocation in an
|
||||
ordinary helper outside the trait transformer. Use `Object` parameters when a trait-to-base cast must survive
|
||||
javac; a raw subclass parameter can cause javac to omit the required cast.
|
||||
- Trait inputs cannot carry an `InnerClasses` attribute; anonymous classes, lambdas and string switches need
|
||||
transformer-specific scrutiny. Keep callbacks in named helper classes. Register parent Java traits first.
|
||||
Mark runtime-only fields `transient` when generated `copyFrom` must not copy them.
|
||||
- Abstract mixin methods remain interface contracts until implemented by a later mixin. Source constructors must
|
||||
be no-argument; registration removes the superclass call and its argument evaluation but retains field initialization.
|
||||
- Java API examples must compile against the packaged dev jar with Scala excluded. Merely removing imports does
|
||||
not prove this: overloaded `loadParts`/`registerParts` still required Scala during resolution, motivating distinct
|
||||
`loadPartList`/`registerPartFactory` names. Preserve legacy override dispatch underneath the Java adapters.
|
||||
|
||||
## Verification
|
||||
|
||||
For a source conversion, characterize the untouched implementation first and preserve the compiled reference
|
||||
consumers. Compare names and descriptors together, modifiers, generic signatures, reflective private fields,
|
||||
class inventory, serialized models, packets/NBT and generated interfaces. Keep behavior fixes separate from
|
||||
mechanical ports. Coverage percentages and signature counts alone are insufficient.
|
||||
|
||||
```powershell
|
||||
.\gradlew.bat spotlessApply checkstyleTest build
|
||||
.\gradlew.bat runFunctionalTestServer
|
||||
.\gradlew.bat --stop
|
||||
.\gradlew.bat clean spotlessApply checkstyleTest build
|
||||
.\gradlew.bat runFunctionalTestServer
|
||||
```
|
||||
|
||||
A Scala-to-Java replacement needs clean verification: Zinc can retain the removed Scala class and package it
|
||||
instead of exercising the new source. Stop the daemon if Windows holds build outputs open. Verify packaged
|
||||
class version 52 and mod-version freshness, including after the release commit.
|
||||
|
||||
JUnit reports are under `build/test-results/test/` and `run/server/junit-out/`; inspect counts, failures, errors and
|
||||
skips. The Forge task rejects missing/failed reports. Keep that CI gate required. Generated dumps are under
|
||||
`run/server/asm/multipart/`; assert a nonzero expected inventory and investigate differences before normalizing
|
||||
proven debug/private-name changes. Headless client-body probes do not validate actual client loading or GPU output.
|
||||
|
||||
Use Forge for world/registry initialization and FakePlayer cases. Error-path logging needs initialized registries;
|
||||
shared global state must be restored between tests. Headless class-initialization failures can differ between the
|
||||
first and subsequent calls, so probes use `LinkageError` rather than one exact subclass. Archived test mods lacking
|
||||
current registered content need disposable worlds to avoid missing-mapping prompts; restore server configuration.
|
||||
|
||||
Run `java tools/AbiScan.java "<instance>/.minecraft/mods" ForgeMultipart` on JDK 17+ and compare full rows with
|
||||
`src/test/fixtures/abi/gtnh-2.9.0-rc2-consumers.txt` (and `gtnh-daily-678-consumers.txt` for row history).
|
||||
Then check that every scanned type and member still resolves against the compiled port: a static resolver flags
|
||||
runtime-generated `scalatraits` accessors such as `TSlottedTile.v_partMap()`, which the Forge smoke test covers
|
||||
instead. Preserve audited source revisions separately from pack versions.
|
||||
Compile frozen Scala fixtures with Scala 2.11.5 on Java 8 against the reference artifact using
|
||||
`scala.tools.nsc.Main -target:jvm-1.8`, not against the replacement. Store bytes under `src/test/resources/compat/`
|
||||
and provenance/hashes in `src/test/fixtures/README.md`.
|
||||
|
||||
## Performance validation
|
||||
|
||||
Profile typical, busy and explicitly labeled stress scenes: mixed ticking/redstone tiles, placement/occlusion,
|
||||
chunk transitions and previews, frame moves, client microblocks/halos, multiplayer packets, startup and first-use
|
||||
class generation. Historical focused results do not establish current whole-pack gains.
|
||||
|
||||
Record world/snapshot, pack and consumer/FMP revisions, hardware, JVM/flags/heap, graphics/view distance, part/trait
|
||||
counts and repeatable actions. Restore equivalent state. Compare baseline versus changed FMP with consumers fixed,
|
||||
then old versus migrated consumer calls on the same FMP artifact; include a compatible Scala reference if possible.
|
||||
Keep runtime/configuration fixed and separate cold startup from warmed play, CPU-bound from GPU-bound scenes.
|
||||
|
||||
Start with five independent runs per variant, alternate order, match warm-up/measurement/profiling overhead, and
|
||||
extend noisy runs. Report medians and variability, absolute units and relative differences; derive p95/p99 from
|
||||
sufficient within-run samples. Include allocation, GC, retained/peak heap, cold latency and packet costs where relevant.
|
||||
Confirm timing without profiling if overhead matters. A helper ratio is not an FPS/TPS claim.
|
||||
|
||||
Before editing, define the hypothesis, measured site and benefit above noise. Keep raw baselines and record commands,
|
||||
commits, correctness checks, controls, regressions and acceptance decisions. Validate representative pack scenes after
|
||||
consumer adoption. Below-noise results are valid; no fixed speedup target or speculative optimization is required.
|
||||
|
||||
The existing focused harness runs with an accepted local server EULA:
|
||||
|
||||
```powershell
|
||||
.\gradlew.bat runFunctionalTestServer "-Pforgemultipart.profileFunctionalTests=true"
|
||||
jfr summary run/server/forgemultipart-baseline.jfr
|
||||
jfr view --width 220 hot-methods run/server/forgemultipart-baseline.jfr
|
||||
jfr view thread-allocation run/server/forgemultipart-baseline.jfr
|
||||
```
|
||||
|
||||
Profile mode overwrites ignored `run/server/forgemultipart-profile.txt` and `forgemultipart-baseline.jfr`.
|
||||
The text's `startEpochMillis`/`nanos` identify phase windows; allocation counts use HotSpot per-thread counters.
|
||||
Java 8 recordings expose TLAB events, not `ObjectAllocationSample`, so recent JDK `allocation-by-site` views are
|
||||
not a valid summary. Consult `ForgeMultipartProfileWorkload` for current workload sizes and phases.
|
||||
@@ -0,0 +1,156 @@
|
||||
# Manual compatibility checklist
|
||||
|
||||
Behavior that the automated layers cannot assert. Plain-JVM tests cannot reach a world, a client or a renderer, and
|
||||
the Forge server suite is headless, so everything below needs a human in a running client unless stated otherwise.
|
||||
|
||||
Each entry names what to do, what should happen, and which port put it here. Run the relevant entries before any
|
||||
release that includes those ports.
|
||||
|
||||
Change `[ ]` to `[x]` after a successful check. If a check fails, leave it unchecked and add a dated note immediately
|
||||
below its table.
|
||||
|
||||
Item examples below use English NEI names, checked against the supplied consumer clones' `en_US.lang` files and
|
||||
registration code on 2026-09-03. Use the mod name to distinguish similarly named items. Sizes/colours add suffixes;
|
||||
an OpenComputers print can have a custom label. Record the tested FMP build, pack version and item/setup with results.
|
||||
|
||||
For ProjectRed's external Scala-trait path, start with **Inverted White Lamp** (or another inverted colour), then saw
|
||||
it into microblocks. `LightMicroMaterial.register` registers only lamp metadata 16–31; ordinary lamps and the
|
||||
**White Illumar** crafting ingredient do not exercise this path. Useful resulting names include **Inverted White
|
||||
Lamp Cover**, **Hollow Inverted White Lamp Cover**, **Inverted White Lamp Nook**, **Inverted White Lamp Strip** and
|
||||
**Inverted White Lamp Post**.
|
||||
|
||||
## Rendering and particles
|
||||
|
||||
| Done | Check | Concrete example / setup | Expected | From |
|
||||
| --- | --- | --- | --- | --- |
|
||||
| [ ] | Break a cover or microblock part and watch the break overlay | Forge Multipart **Stone Cover** | The breaking texture is drawn on the part's own cuboid, not the full block | `TCuboidPart.drawBreaking` |
|
||||
| [ ] | Hit a part repeatedly without breaking it | Forge Multipart **Grass Cover**; its top, side and bottom icons make a wrong face visible | Hit particles spawn on the struck face, using that face's icon | `IconHitEffects.addHitEffects` |
|
||||
| [ ] | Break a part fully | ProjectRed Expansion **Solar Panel** placed horizontally; it has thin bounds and distinct top/side icons | Destroy particles query sides 0–5 and are scaled to the part's bounds | `IconHitEffects.addDestroyEffects` |
|
||||
| [ ] | Break a hollow cover | Forge Multipart **Hollow Stone Cover** | Destroy particles use the full block bounds, not the part bounds | `addDestroyEffects` scaleDensity false |
|
||||
| [ ] | Hover face, hollow, edge and corner microblock placement targets | Forge Multipart **Stone Cover**, **Hollow Stone Cover**, **Stone Strip** and **Stone Nook**; for a consumer override, hold a Stone Cover over ProjectRed **Framed Red Alloy Wire** to preview its jacket | The highlight and guide lines match each placement region, and a mod supplying its own highlight renderer overrides them | `PlacementGrid` / `MicroblockRender.renderHighlight` / `MicroblockEventHandler.drawBlockHighlight` / `MicroMaterialRegistry.renderHighlight` |
|
||||
| [ ] | Reload client resources after placing several microblock materials | Place **Stone**, **Glass**, **Grass** and ProjectRed **Inverted White Lamp Covers**, then press `F3+T` | The texture atlas reloads every material icon without missing textures | `MicroblockEventHandler.postTextureStitch` / `BlockMicroMaterial.loadIcons` |
|
||||
| [ ] | Render microblocks of a block whose icons another mod finishes in `TextureStitchEvent.Post` | Saw Chisel **Stone Bricks** variants that use `-v4` textures (2x2 submaps) into covers; check them on world load and again after `F3+T` | Covers show the Chisel texture, never the missing texture, both times | `BlockMicroMaterial.icont` stale re-resolve (GTNH issue 27183) |
|
||||
| [ ] | Look at a **Stone Saw**, **Iron Saw** and **Diamond Saw** in inventory and in hand | All three items are supplied by Forge Multipart | The saw item renders with its custom transform | `ItemSaw` `IItemRenderer` |
|
||||
| [ ] | Place microblocks of several materials, including glass | Compare Forge Multipart **Stone Cover** and **Glass Cover** | Transparent materials render in the correct pass and are not opaque | `BlockMicroMaterial` / `IMicroMaterial.canRenderInPass` |
|
||||
| [ ] | Place grass and mycelium covers at several thicknesses and biomes | Forge Multipart **Grass Cover** and **Mycelium Cover**, preferably 1/8 and 1/2 thicknesses | Grass has an untinted base plus a tinted, height-aligned side overlay and tinted top; mycelium uses its top texture on horizontal faces and height-aligned side texture elsewhere | `GrassMicroMaterial` / `TopMicroMaterial` |
|
||||
| [ ] | Load a saved microblock whose material is no longer installed | In a disposable instance, add `"minecraft:coal_ore"` to `microblocks.cfg`, create and save a **Coal Ore Cover**, remove that line, then reload | The part remains present and renders the magenta/black missing texture instead of becoming material ID 0 | `MissingMicroMaterial` |
|
||||
| [ ] | Put a **Stone Cover** and a ProjectRed **Inverted White Lamp Cover** on opposite faces of one block space, then add/remove another part | Use another Stone Cover or ProjectRed **Red Alloy Wire** as the part that triggers cache updates | Static parts remain in the block render, dynamic parts remain in the TESR pass, and neither disappears after a part update | `TileMultipartClient` render caches |
|
||||
| [ ] | Watch a multipart torch long enough to emit display particles | Add a **Stone Cover** to a vanilla **Torch** to convert it into a multipart; an active **Redstone Torch** is another useful case | Only parts implementing `IRandomDisplayTick` emit particles, with no duplicate or missing callbacks | `TRandomDisplayTickTile.randomDisplayTick` |
|
||||
| [ ] | Start a client, join a server, place/update a multipart and use the multipart control key | Assign Forge Multipart's **Switch block disposition** key, then place and reorient a **Stone Cover** | Block and generated-tile rendering work, client packets arrive, and control-key state changes are sent once without duplicate registrations | `MultipartProxy_clientImpl.postInit` / `onTileClassBuilt` |
|
||||
| [ ] | Move into view of a chunk containing several multipart tiles, then add, update and remove parts | Use mixed tiles containing an AE2 **ME Glass Cable**, a **Stone Cover**, and ProjectRed **Red Alloy Wire** on different faces | The initial chunk description reconstructs every tile and compressed updates apply without missing, duplicated or ghost parts | `MultipartCPH` / `MultipartSPH` |
|
||||
| [ ] | Start a client with 3D saws enabled, inspect all three saw tiers and the microblock item, then repeat with Angelica installed | Set `useSawIcons=false`; inspect Forge Multipart's **Stone**, **Iron** and **Diamond Saws** and any Stone microblock | Each renderer is registered once, saw models use the correct tier, microblock icons load, client packets register, and the Angelica hook initializes without errors | `MicroblockProxy_clientImpl.init` / `postInit` |
|
||||
| [ ] | Render several block micro-materials with Angelica shaders enabled, then render an unrelated block | Render **Stone**, **Grass** and **Glass Covers**, then an unrelated vanilla Stone block | Each face receives the matching block/meta shader material and the override is reset after the microblock draw | `MaterialRenderHelper.blockAndMeta` / `render` |
|
||||
| [ ] | Inspect face, hollow, edge and corner microblocks in inventory and as dropped entities | Forge Multipart Stone **Cover**, **Hollow Cover**, **Strip**, **Post** and **Nook** at several sizes | Every size/material combination uses the correct localized name and centered shape/material render | `ItemMicroPart` / `ItemMicroPartRenderer` / `MicroblockRender.renderItem` |
|
||||
| [ ] | Saw **Stone**, **Glass** and a ProjectRed **Inverted White Lamp** into face covers; place them on all six faces beside other microblocks, then inspect their inventory renders | The named Forge Multipart and ProjectRed microblocks are the concrete cases | Opaque covers retain their outer face while internal faces follow the shrink mask; transparent covers use the shrunk bounds, and inventory renders show the complete shape without missing or doubled faces | `FaceMicroblockClient.render` / `FaceMicroblockTraitLogic.render` |
|
||||
| [ ] | Saw **Stone**, **Glass** and a ProjectRed **Inverted White Lamp** into strip/post shapes; place crossing posts on all three axes between face covers, then add and remove neighbours | The named Forge Multipart and ProjectRed microblocks are the concrete cases | Compare both split segments with the reference, including the second segment's use of physical bounds; removal resets the split without stale geometry or missing sections | `PostMicroblockClient.recalcBounds` / `PostMicroblockClientLogic` / `shrinkFace` / `shrinkPost` |
|
||||
| [ ] | Run connected AE2 **ME Glass Cable**, **ME Covered Cable** and **ME Dense Smart Cable**, plus ProjectRed **Framed Red Alloy Wire**, through hollow stone/glass covers on all six faces | The named AE2, ProjectRed and Forge Multipart parts are the concrete cases | Each opening follows the connector size; opaque and transparent rims, breaking overlay and highlight have no missing, doubled or stale sections after neighbour changes | `HollowMicroblockClient` / `HollowMicroblockClientLogic` |
|
||||
| [ ] | Place touching **Stone Cover**, **Glass Cover**, corner/edge counterparts and ProjectRed **Inverted White Lamp** microblocks at mixed sizes; add/remove neighbours, then rejoin the server | The named Forge Multipart and ProjectRed microblocks are the concrete cases | Intersections choose the same winner, opaque covered faces stay masked, and every surviving segment refreshes without gaps or stale bounds | `MicroOcclusion` / `TMicroOcclusionClient` / `TMicroOcclusionClientLogic` |
|
||||
|
||||
2026-09-03: Placing a ProjectRed part with `1.7.12-algent-java.186+60d060a3ff` crashed in
|
||||
`MultipartRenderer$.renderTileEntityAt`: its class call to `TileMultipartClient.hasDynamicParts()` encountered the
|
||||
transformed runtime interface. The renderer now calls the generated getter through a stable `TileMultipart` base
|
||||
hook. Four headless Forge cases cover the actual renderer bytecode's guards and dispatch; both nonempty cases
|
||||
reproduced the original crash. The user retested with the supplied fix and confirmed that placement no longer
|
||||
crashes. Static/dynamic drawing and part updates still need their full client checks before marking the rendering
|
||||
entries complete.
|
||||
|
||||
## Placement and interaction
|
||||
|
||||
| Done | Check | Concrete example / setup | Expected | From |
|
||||
| --- | --- | --- | --- | --- |
|
||||
| [ ] | Right-click a block face with ProjectRed **Red Alloy Wire** at a shallow angle | ProjectRed **Red Alloy Wire** | The part is placed in the clicked block | `TItemMultiPart.onItemUse` depth below 1 |
|
||||
| [ ] | Repeat with **Red Alloy Wire**, clicking deep into a face | ProjectRed **Red Alloy Wire** | The part is placed in the neighbouring block on that side | `TItemMultiPart.onItemUse` offset path |
|
||||
| [ ] | Place a part where it would overlap an existing one | Place a **Stone Cover**, then force a second Stone or Hollow Stone Cover into the same face slot using **Switch block disposition** if needed | Placement is refused rather than silently replacing | `NormalOcclusionTest`, `PartialOcclusionTest` |
|
||||
| [ ] | Pass redstone through a hollow cover on a multipart face | Put ProjectRed **Framed Red Alloy Wire** in the centre and a **Hollow Stone Cover** between it and an external redstone source | Redstone still passes through the hollow centre | `TFacePart.redstoneConductionMap` |
|
||||
| [ ] | Place **Hollow Stone Cover** and **Hollow Inverted White Lamp Cover** parts at several thicknesses around ProjectRed **Framed Red Alloy Wire** on all six faces; add/remove the wire, select the rim, then save and reload | The named Forge Multipart and ProjectRed parts are the concrete cases | The opening follows the connector, selection/collision respect the hollow centre, incompatible overlaps are refused, and shape/material survive reload | `HollowMicroblock` / `HollowMicroblockTraitLogic` |
|
||||
| [ ] | Run ProjectRed **Red Alloy Wire** across a **Stone Strip** edge microblock | ProjectRed **Red Alloy Wire** and Forge Multipart **Stone Strip** | Conduction matches the pre-port behavior | `TEdgePart.conductsRedstone` |
|
||||
| [ ] | Cut materials with saws of different harvest levels | Try **Stone Saw → Iron Block**, **Iron Saw → Diamond Block**, and **Diamond Saw → Obsidian**; confirm weaker saws reject the higher-tier cases | Only materials at or below the saw's strength can be cut | `Saw.getMaxCuttingStrength` |
|
||||
| [ ] | Place the same microblock in survival and creative, including onto an existing multipart tile | Use a **Stone Cover** in empty space and beside ProjectRed **Framed Red Alloy Wire** | Valid placements play the material sound; survival consumes the expected amount while creative does not | `ItemMicroPart.onItemUse` |
|
||||
| [ ] | With a second client watching, convert a vanilla torch by adding a cover, then add/remove compatible ProjectRed **Red Alloy Wire**, ProjectBlue **Control Panel**, or AE2 **ME Glass Cable** parts | Start with a vanilla **Torch + Stone Cover**, then use any named consumer part that fits | Both clients see each part exactly once, with no ghost block, stale render or missing part after tile replacement | `MultipartGenerator` conversion packet order and generated tile upgrade/downgrade |
|
||||
|
||||
## Downstream integration
|
||||
|
||||
| Done | Check | Concrete example / setup | Expected | From |
|
||||
| --- | --- | --- | --- | --- |
|
||||
| [ ] | Saw a ProjectRed **Inverted White Lamp** into cover, hollow cover, nook/corner and strip/post shapes; test face, corner, edge and centre-post placement | ProjectRed **Inverted White Lamp**; ordinary lamps and **White Illumar** do not exercise this registration path | The lamps generate, use the correct bounds, render and light correctly | `MicroblockGenerator.registerTrait` Scala trait path / shape factory facades |
|
||||
| [ ] | Place and break OpenComputers **Cable** and a **3D Print**, ProjectBlue **Control Panel** (size suffix varies), and AE2 **ME Glass Cable**; share their block space with a compatible cover | Use a **Stone Cover** with each named consumer part | No `NoSuchMethodError` or `AbstractMethodError` in the log | retained `$class` bridges |
|
||||
| [ ] | Load and render a schematic containing an ordered mixed multipart tile | Schematica; capture an AE2 **ME Glass Cable** with a **Stone Cover** and ProjectRed **Red Alloy Wire** on different faces | Every part appears in the preview in the saved order; the integration does not silently disable itself | `createPreviewTileFromNBT`, factory preview callbacks and `MultipartRenderer.renderWorldBlock` |
|
||||
| [ ] | Open a GuideNH scene containing a multipart tile and export its part/material data | GuideNH; use the same **ME Glass Cable + Stone Cover + Red Alloy Wire** composite | The preview, material data and part statistics are complete | `createPreviewTileFromNBT`, typed part/material traversal and `MultipartRenderer.renderWorldBlock` |
|
||||
| [ ] | Place FMP buttons on every supported face with Et Futurum loaded | Convert a vanilla **Stone Button** by adding a **Stone Cover**; repeat its supported orientations with Et Futurum Requiem installed | Button orientation matches the fixed vanilla behavior | supported `ButtonPart.setOrientation`; legacy arrays until consumer adoption |
|
||||
| [ ] | With Iguana harvest-level tweaks enabled, inspect and use the Stone, Iron, Diamond, Ardite, Cobalt and Manyullyn saws against materials spanning their configured tiers | Forge Multipart supplies the first three saws; Iguana Tweaks for Tinkers' Construct supplies **Ardite**, **Cobalt** and **Manyullyn Saws** | Tooltips, saw textures and cutting recipes use the remapped tier; weaker saws do not gain the cached strongest-saw exemption | supported `ItemSaw.setHarvestLevel`; legacy field until consumer adoption |
|
||||
| [ ] | Use OpenComputers **3D Printer** to make a **3D Print** with different off/on shapes that both fit beside a cover; place it with the cover and right-click to toggle | OpenComputers **3D Printer**, its resulting **3D Print**, and a Forge Multipart **Stone Cover** | Its slots are rebuilt without losing, hiding or disconnecting either part | external mutation of `TSlottedTile.v_partMap` plus `bindPart` |
|
||||
| [ ] | Move the same composite tile using a ProjectRed **Frame Motor** with MCFrames **Frame** blocks, then a **Matter Manipulator MKIII** in move mode | Move the **ME Glass Cable + Stone Cover + Red Alloy Wire** composite with the named ProjectRed, MCFrames and Matter Manipulator items | Coordinates, part-to-tile references, generated interfaces and rendering remain correct after `onMoved` | ForgeRelocationFMP / MatterManipulator live multipart move lifecycle |
|
||||
| [ ] | Capture and rebuild a mixed multipart tile with a BuildCraft **Builder**, then with a **Matter Manipulator MKIII** copy/paste | Blueprint and copy the **ME Glass Cable + Stone Cover + Red Alloy Wire** composite plus a Stone Strip, Hollow Cover and FMP torch or button; rebuild it elsewhere, rotated | Every part returns once with its material, shape, orientation and connections; microblocks land before other parts and no extra description packet is needed | Part `save`/`loadPart`, core type IDs and microblock NBT read by BuildCraftCompat and MatterManipulator |
|
||||
| [ ] | Inspect a mixed multipart tile with Waila | Waila; inspect the **ME Glass Cable + Stone Cover + Red Alloy Wire** composite | Providers receive every saved part ID and show the expected part data | reflected block identity and tile NBT `parts`/`id` layout |
|
||||
| [ ] | Spray ProjectRed wires that share blocks with covers, once normally and once sneaking to chain | GregTech **Spray Can** on ProjectRed **Insulated Wire** and **Bundled Cable** runs, each block also holding a **Stone Cover** placed before the wire | Only the struck wire, and when chaining its same-type neighbours, recolor; the cover is never selected | GT5U `BlockMultipart.reduceMOP` `Tuple2` index plus `jPartList`/`partMap` order |
|
||||
| [ ] | Look at a ThaumicEnergistics vis interface on a covered AE2 cable with Waila | ThaumicEnergistics **Vis Relay Interface** part on an AE2 **ME Glass Cable** with a **Stone Cover** | The vis-link Waila lines still appear once the cover has turned the cable into a multipart tile | reflected `TileMultipart` class name plus AE2 part-host pass-through |
|
||||
| [ ] | Load a world saved before the port | Use a pre-port save containing **Stone Covers**, ProjectRed lamp microblocks and an AE2 cable | All microblocks and covers keep their material and shape | `Microblock` shape/material NBT and `MicroMaterialRegistry` id map |
|
||||
| [ ] | Join a server whose material set differs from the client | In disposable client/server instances, add `"minecraft:coal_ore"` only to the server's `microblocks.cfg` | The client is disconnected with the missing material list, not a crash | `readIDMap` |
|
||||
| [ ] | Join a server whose multipart type set differs from the client | Setup-only: use a small test addon that registers a part on only one side; stock consumer removal may be rejected earlier by Forge's mod handshake | The client is disconnected with the ordered missing-part list, not a crash | `MultipartCPH.handlePartRegistration` |
|
||||
|
||||
The [Java illuminated extension example](../api/MICROBLOCK_EXTENSIONS.md) has dedicated-server and headless halo
|
||||
coverage. When adopting it in ProjectRed, rerun the illuminated shape/lighting checks above on a physical client,
|
||||
including hollow connector widths and all sides, pass filtering and the existing halo queue/configuration. Neither
|
||||
its callback-side input tests nor its retained client-body probe validates actual client generation or GPU output.
|
||||
|
||||
## Not yet covered anywhere
|
||||
|
||||
- [ ] Follow the [performance protocol](MAINTAINERS.md#performance-validation); historical focused measurements are not full-pack evidence. A representative
|
||||
full-pack capture and the matching post-optimization comparison still need to be performed. Example setup: a loaded
|
||||
chunk containing many AE2 cables, ProjectRed wires/lamps and assorted Forge Multipart microblocks.
|
||||
- [ ] Shape-specific microblock NBT and packet payloads. Core `Microblock` shape/material NBT, description bytes and
|
||||
one-byte shape updates are complete, along with compact core tile/part NBT and logical chunk-description fixtures.
|
||||
Example setup: Stone Cover, Hollow Cover, Nook, Strip and Post; save/rejoin and mutate each shape.
|
||||
|
||||
- [ ] Add UtilitiesInExcess as a compile/runtime fixture before it enters the pack: its `IPartFactory2`
|
||||
registration, fence/wall/sphere parts and `getIdMap` / `materialCount` enumeration against the built port jar.
|
||||
Fix its `mat` / `material` NBT key mismatch first; see the
|
||||
[consumer finding](COMPATIBILITY.md#utilitiesinexcess---future-replacement-already-a-substantial-consumer).
|
||||
|
||||
## Item-name references
|
||||
|
||||
Resource paths below are relative to each consumer's `src/main/resources` in its source checkout.
|
||||
Code locations identify the matching source packages/methods. Registration/behavior was checked in addition to
|
||||
translation keys; these are examples for running the checks, not claims that the checks have passed.
|
||||
|
||||
| Consumer | Translation key / source |
|
||||
| --- | --- |
|
||||
| ProjectRed | `assets/projectred/lang/en_US.lang`: `tile.projectred.illumination.lamp\|16`, `item.projectred.transmission.wire\|0`, `framewire\|0`, `item.projectred.expansion.solar_panel`, `tile.projectred.expansion.machine2\|8`; `illumination/lightmicroblocks.scala` registers inverted lamp materials, `expansion/TileSolarPanel.scala` supplies a thin part with top/side particle icons, and `expansion/TileFrameMotor.scala` uses the relocation API |
|
||||
| OpenComputers | `assets/opencomputers/lang/en_US.lang`: `tile.oc.cable`, `tile.oc.print`, `tile.oc.printer`; `integration/fmp/PrintPart.scala` toggles state and rebuilds slots |
|
||||
| ProjectBlue | `assets/projectblue/lang/en_US.lang`: `item.gcewing_projectblue:controlPanel`; `ControlPanelItem.getItemStackDisplayName` appends its grid size |
|
||||
| AE2 | `assets/appliedenergistics2/lang/en_US.lang`: `item.appliedenergistics2.ItemPart.CableGlass`, `CableCovered`, `CableDense`; `appeng/fmp/CableBusPart.getHollowSize` supplies connected cable bounds |
|
||||
| ForgeRelocation / MatterManipulator | `assets/mcframes/lang/en_US.lang`: `tile.mcframes.frame`; `assets/matter-manipulator/lang/en_US.lang`: `item.itemMatterManipulator3`; the MKIII tier permits moving |
|
||||
| Chisel | `compat/fmp/PartChiselTorch.java` and `FMPCompat.java`: any Chisel torch can be converted while preserving its variant and orientation |
|
||||
| Iguana Tweaks for Tinkers' Construct | `modcompat/fmp`: Ardite, Cobalt and Manyullyn saws plus harvest-level remapping for Forge Multipart saws |
|
||||
| FMP shapes and saws | This repository's `src/main/resources/assets/multipart/lang/en_US.lang`: `mcr_face`, `mcr_hllw`, `mcr_edge`, `mcr_cnr`, and `item.microblock:sawStone/sawIron/sawDiamond` |
|
||||
|
||||
## Converter integration follow-up
|
||||
|
||||
The [converter guide](../api/BLOCK_CONVERTERS.md) and Forge fixtures establish registration, discarded probes,
|
||||
committed callback order and example state round trips. Before adopting consumer changes:
|
||||
|
||||
- [ ] On a physical client/server, preview and cancel conversion of Chisel torches, OpenComputers cables/prints,
|
||||
AE2 cable buses and supported converter blocks; the source state/network must remain intact. Concrete cases: any
|
||||
**Chisel Torch**, OpenComputers **Cable** and **3D Print**, and AE2 **ME Glass Cable**.
|
||||
- [ ] Commit conversion, reconnect/reload, and confirm metadata, inventory and network state survive exactly once,
|
||||
without duplicate drops, lost contents or ghost connections. Exercise rejection as well as successful placement
|
||||
with the same Chisel, OpenComputers and AE2 cases.
|
||||
- [ ] Recheck consumer side-specific constructors and descriptions; the headless example packet test does not cover
|
||||
physical-client class selection or rendering. Record consumer release and actual pack adoption separately. Reuse
|
||||
the Chisel Torch, OpenComputers Cable/3D Print and AE2 ME Glass Cable cases on both client and server.
|
||||
|
||||
## Stable tile capability adoption
|
||||
|
||||
- [ ] Rebuild ProjectRed's open-connection query against `IRedstoneTile`, retaining its rotation/mask logic; validate
|
||||
face/framed wires with face covers and edge blockers on a physical client/server, including part changes and moves.
|
||||
Concrete setup: ProjectRed **Red Alloy Wire** and **Framed Red Alloy Wire** with Stone Covers and Stone Strips.
|
||||
- [ ] Verify consumer bytecode uses the stable interface/base owner rather than raw transformed trait class calls or
|
||||
fields. The [Forge fixture](../api/TILE_TRAIT_ACCESS.md) proves server linkage, not all client-side capabilities.
|
||||
This is a `javap`/ASM inspection check; no in-game item exercises the bytecode owner directly.
|
||||
- [ ] Rebuild OpenComputers `PrintPart.toggleState` using `tile.refreshPartSlots(this)`, then exercise inactive/active
|
||||
and button modes on client/server. Confirm old slots clear, new slots occupy, rejected changes leave caches intact,
|
||||
and sound, part notification, description update and scheduled reset still occur once in the original order.
|
||||
Concrete setup: an OpenComputers **3D Print** with different compact off/on shapes beside a Stone Cover.
|
||||
- [ ] Verify the migrated OpenComputers bytecode no longer names `TSlottedTile`/`v_partMap`; retain the old accessor
|
||||
until its released version is present in the target pack. This is also a `javap`/ASM inspection check, not an
|
||||
additional in-game item test.
|
||||
@@ -0,0 +1,71 @@
|
||||
# ForgeMultipart migration status
|
||||
|
||||
The core runtime implementation and the audited consumer-facing Java replacements are implemented.
|
||||
Consumer patches, released versions and target-pack adoption are still pending; API availability does not
|
||||
mean a consumer has migrated. The first Java release retains supported legacy binaries and FMP's Scala bridges.
|
||||
|
||||
## Documentation
|
||||
|
||||
| Document | Purpose |
|
||||
| --- | --- |
|
||||
| [Java API](../API.md) and [release notes](../RELEASE_NOTES.md) | Supported replacements, examples and source migration hazards |
|
||||
| [Compatibility audit](COMPATIBILITY.md) | Frozen ABI inventory, source revisions, reflective contracts and consumer findings |
|
||||
| [Consumer adoption ledger](COMPATIBILITY.md#java-api-adoption-ledger) | Legacy contract, replacement, source patch, release and target-pack adoption |
|
||||
| [Divergences](DIVERGENCES.md) | Intentional effective compatibility differences |
|
||||
| [Manual release checks](MANUAL_CHECKS.md) | Outstanding client, pack and release validation |
|
||||
| [Maintainer guide](MAINTAINERS.md) | Build boundaries, compiler constraints, verification and performance protocol |
|
||||
|
||||
Use this page for remaining work, not a running diary. Record consumer progress in the adoption ledger and
|
||||
release results in the manual checklist. Completed-work narratives remain in git history. Test counts and
|
||||
artifact inventories should come from the reports for the revision being reviewed.
|
||||
|
||||
## Remaining work
|
||||
|
||||
1. **Migrate consumers.** Use the existing typed APIs, with optional integrations gated on presence/version.
|
||||
Preserve each consumer's state, ordering, failure policy and initialization timing. Record the source revision,
|
||||
first released version, minimum FMP dependency and actual target-pack artifact for each legacy contract.
|
||||
Consumer mods may remain Scala internally. Reference checkouts are not evidence of a shipped migration.
|
||||
2. **Validate client and pack behavior.** Complete the manual checklist, including illuminated microblock
|
||||
construction/halos, previews, rendering, particles, lighting, interactions, old worlds, multiplayer and movement.
|
||||
Test optional dependencies both absent and present. The successful MCPC hook needs an actual patched World
|
||||
where that platform is supported. Headless Forge tests do not establish GPU or full-pack correctness.
|
||||
3. **Measure performance.** Once representative API/extension workloads are stable, profile realistic scenes and
|
||||
make only justified changes. Separate FMP implementation gains from consumer API migration gains. Follow the
|
||||
[measurement protocol](MAINTAINERS.md#performance-validation); historical focused results are not whole-pack claims.
|
||||
4. **Finish repository/release preparation.** Relocate Java sources only where remaining Scala dependencies allow
|
||||
it; reassess the forced Scala compilation/version guard after relocation, and update the root README's source
|
||||
layout note. Validate Java 8 artifacts and packaged/obfuscated artifacts on the supported modern runtime. Modern syntax
|
||||
expansion is optional and must respect the [build boundary](MAINTAINERS.md#build-and-runtime-boundaries).
|
||||
5. **Remove FMP's Scala requirement last.** Complete the gates below before retiring bridges, compiler support
|
||||
or dependencies. Other mods' independent Scala requirements are outside this target.
|
||||
|
||||
Extra Utilities 1.2.12 remains an active supported consumer. Switching support to UtilitiesInExcess requires an
|
||||
explicit support decision and actual pack adoption, including migration of the replacement's FMP contracts.
|
||||
GTNHLib/fastutil, Sponge Mixins and a replacement runtime generator are conditional choices, not migration tasks
|
||||
in themselves. Add them only for a demonstrated need.
|
||||
|
||||
## Scala removal gates
|
||||
|
||||
- Every affected adoption-ledger row is verified against the actual target-pack jars, including reflective fields,
|
||||
mixin targets, compiler-generated helpers and external Scala traits. Unmodifiable consumers must be retained or replaced.
|
||||
- A deprecation/removal window and a release permitted to break the old ABI are agreed. That window is still open;
|
||||
adding a replacement or deprecation is not permission to delete a bridge.
|
||||
- FMP's own Scala storage, retained models, trait inputs and legacy callers are replaced or retired. In particular,
|
||||
ProjectRed's released Java extension alone does not eliminate FMP's internal need for Scala-signature decoding.
|
||||
- Shipped and generated FMP classes, descriptors and runtime loading paths contain no remaining Scala requirements;
|
||||
Scala compilation and compiler/runtime dependencies can then be removed.
|
||||
- Migrated consumers pass old-world, packet, client and dedicated-server validation against the resulting artifact.
|
||||
|
||||
## Retained implementation
|
||||
|
||||
| Sources under `src/main/scala/codechicken` | Remaining dependency |
|
||||
| --- | --- |
|
||||
| `multipart/asm/ASMMixinCompiler.scala` | Nested models, construction callbacks and Scala entry shell |
|
||||
| `multipart/asm/ScalaSignature.scala` | Named models, primitive/erased bridges and generic inner construction |
|
||||
| `multipart/asm/StackAnalyser.scala` | Coordinated class/companion/models, state and handler callbacks |
|
||||
| `microblock/MicroblockTraits.scala`, `FaceMicroblockTraits.scala`, `CornerMicroblockTraits.scala`, `EdgeMicroblockTraits.scala` | State, inheritance, accessor and super-call shells over Java behavior |
|
||||
| `microblock/HollowMicroblockTraits.scala`, `TMicroOcclusion.scala` | Server/client inheritance, initializers, state and lifecycle bridges |
|
||||
|
||||
Java sources also retain Scala-backed storage and compatibility references. A source-file count does not measure
|
||||
removal readiness. Further extraction should enable a consumer migration, fix a demonstrated issue or provide a
|
||||
measured benefit; mechanical shell conversion is not the next milestone.
|
||||
Reference in new issue
Block a user