Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Complete crafting jobs on networks without discretizer #225

Merged
merged 1 commit into from
Aug 27, 2024

Conversation

Demiu
Copy link

@Demiu Demiu commented Aug 25, 2024

Allows for this:
image
Only red network has the discretizer.

Previously, without a discretizer in the green network you could start jobs, but fluid products were never registered in crafting. Discretizer was a dual-purpose block. The item inventory (FluidDiscretizingInventory) provided droplet representations of fluids in the network + conversion on droplet inject/extract. The fluid inventory (FluidCraftingInventory) converted injected fluids to droplets and attempted to inject them into the crafting grid.

This PR replaces the CraftingGridCache::getCellArray function responsible for getting the inventory handlers which are part of StorageGrid. On channel ITEMS there is no functional change, on channel FLUIDS instead of nothing it now returns a proxy to the CraftingGridCache which performs the same work as discretizer's fluid inventory (conversion to fluid and back).
As a bonus with no need for second discretizer the droplets no longer need to be doubled on green net.

The FluidDiscretizingInventory of discretizer is still needed
FluidCraftingInventory and FluidCraftingInventoryHandler of discretizer I think could be removed

Removed some static methods in CoreModHooks which were unused

@Dream-Master Dream-Master requested a review from a team August 26, 2024 06:25
@Dream-Master Dream-Master merged commit b2e74d8 into GTNewHorizons:master Aug 27, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants