Skip to content

Item Acceptor Blocks don't respect SidedInventories when inserting items #80

Description

@myriantics

When inserting an item stack into an inventory, Item Acceptor blocks always choose the first available slot in the whole inventory, disregarding the slots that it may have declared available for the insertion side.

Steps to reproduce:

  • Place Item Acceptor and set it to input into the side of a furnace
  • Right click a compatible item onto it

Expected Behavior:

  • Item goes into the fuel slot

Result:

  • Item goes into the ingredient slot

Potential Fix:

  • Add a instanceof check for SidedInventories, which polls the getAvailableSlots() or canInsert() methods when attempting to insert an item

Relevant method:

private ItemStack addToFirstFreeSlot(Inventory inventory, ItemStack stack) {

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

bugSomething isn't working

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions