feat: dynamically configure slot counts for Industrial Agglomeration … #77
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi, there, excellent work!
I've been playing some modpacks and find out some custom recipes of Terrestrial Agglomeration Plate require more than three types of input items, while Industrial Agglomeration Factory only has 3 input slots, which is a bit of inconvenient, so I made some modifications to the code to enable changes to the number of input slots. Following is the detailed PR content. Additionally, since I am not very familiar with GUI rendering and drawing operations, I did not make corresponding modifications to the GUI. Considering that multi-slot usage scenarios are mostly related to automation integrated with AE, modifying the GUI might not be particularly important.
This pull request includes several changes to the
ContainerMenuIndustrialAgglomerationFactory
andBlockEntityIndustrialAgglomerationFactory
classes, mainly focusing on making the slot count configurable viaLibXServerConfig
. The changes also involve updating the slot handling logic to accommodate the new configurable slot counts.Configuration Updates:
src/main/java/de/melanx/botanicalmachinery/config/LibXServerConfig.java
: Added new configuration options for the number of input and output slots in the Industrial Agglomeration Factory.Slot Handling Updates:
src/main/java/de/melanx/botanicalmachinery/blocks/containers/ContainerMenuIndustrialAgglomerationFactory.java
: Modified the constructor to use the configurable slot counts and updated the slot addition logic to dynamically create input slots based on the configuration.src/main/java/de/melanx/botanicalmachinery/blocks/tiles/BlockEntityIndustrialAgglomerationFactory.java
: Updated the constructor to initialize the inventory with configurable slot counts and added logic to handle input and output slots dynamically.src/main/java/de/melanx/botanicalmachinery/blocks/tiles/BlockEntityIndustrialAgglomerationFactory.java
: Updated thegetExtracts
method to use the new output slot configuration.Import Statements:
src/main/java/de/melanx/botanicalmachinery/blocks/containers/ContainerMenuIndustrialAgglomerationFactory.java
: Added import forLibXServerConfig
.