J ‐ Advanced Wrench - Alecsioo/MMCE-Addons GitHub Wiki

Advanced Wrench

Overview

The Advanced Wrench is a tool designed to simplify the creation of multiblock structure JSON definitions in Modular Machinery. Rather than manually defining each block's relative position to the controller, this tool automates the process by allowing users to select two opposite corners of the multiblock structure and the controller block.

This dramatically reduces the time and potential errors involved in creating large or complex multiblocks.

Functionality

Multiblock structures in Modular Machinery are defined via JSON. Each entry in the JSON defines:

  • The block.
  • Its relative position to the multiblock controller.

Manually building this JSON can be time-consuming. The Advanced Wrench improves upon the base Modular Machinery wrench, which requires clicking each block individually, by allowing for bulk selection.

Usage Instructions

  1. Select the Structure:

    • Right-click on two opposite corner blocks to define the 3D area of the multiblock.
    • These blocks must exist to be selected, but can be removed later if they're not part of the final structure.
  2. Finalize the Selection:

    • Shift-right-click on the multiblock controller to confirm your selection and generate the JSON.
  3. Clear the Selection:

    • To reset the selection, right-click on a third block.

Notes

  • Corner blocks used to define the area do not have to be part of the actual multiblock structure. The wrench only needs them temporarily to register their position, meaning once selected, you may safely remove them before finalizing the selection.
  • Sometimes, dumping the NBT of all the TEs in the multiblock might not be necessary. For this reason, there's a setting under the mod options which allows to stop NBT from being included in the machine JSON. (available since v1.1.0)