Skip to content

When AE crafting a processing pattern, make AE reuse/replace non-consumed ingredients/circuit configurations #4618

@alfuken

Description

@alfuken

Cross-mod Integration

Applied Energistics 2

Minecraft Version

1.20.1 Forge

Feature Description

Currently, in order to be able to actually effectively use AE2 autocraft, a separate machine for each circuit configuration and casting mold/extruder mold/laser cutter lens needs to be set up. Obviously, this eventually becomes quite a mess.

There is currently some integration exists with AE2 in the form of multiblock hatches (and even those are gated by EV tier, which is waaaay beyond reasonable, btw), but that's just clutches.

It would be nice to have an integration layer between GTCEU<->AE2 that would allow for following mechanics:

1. Crafting with non-consumed ingredients

When AE2 is about to start crafting a processing recipe
  that uses a non-consumed ingredient (mold, lens, etc),
Then check content of target machine input slots:
  - If machine inputs contain a non-consumed ingredient,
    And it's is *different* to the one in the recipe,
    Then:
    - Either extract that *different* non-consumed ingredient
      directly back into AE2 storage,
      (if there are no space in AE2 storage to store it, then abort crafting attempt)
    - Or simply move it to an empty machine output slot,
      so it can be circled back into AE2 storage;
      (if there are no empty output slots, then abort crafting attempt)
    - Or try both, first extract, then move to output, then abort.
  - If inputs contain a non-consumed ingredient,
    And it's *the same as* the one in the recipe,
    Then:
    - proceed with pushing only the regular ingredients into the machine inputs;
  - If inputs do not contain any non-consumed ingredients,
    Then:
    - proceed as usual

2. Crafting with circuit configuration

When AE2 is about to start crating a processing recipe
  that uses a specific circuit configuration,
Then set machine's circuit configuration to match that of the processing recipe;
When AE2 is about to start crating a processing recipe
  that does NOT use any specific circuit configuration,
Then set machine's circuit configuration to "empty";

This will also require changing the AE2 processing recipe handling (including when clicking on the "+" button in the EMI/JEI/etc) to store the configuration value in the processing recipe pattern. Either as a special free "ghost" item, or some additional data/NBT field, or smth like that.

This will make everyone's lives soooo much easier, and builds cleaner — which means fewer machines -> fewer updates -> fewer ticking entities -> lower TPS impact, and having no lags makes everyone's happy! ;)

UPD.: "machine" means not only actual machines, but buses/hatches as well.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions