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

Breaking a storage connected using a Storage Bus causes it's contents to be lost, if anything tries to add them back to the System immediatelly #3688

Closed
bothie opened this Issue Aug 23, 2018 · 2 comments

Comments

Projects
None yet
2 participants
@bothie

bothie commented Aug 23, 2018

Setup:

Creative Energy Source
ME Controller
ME Security Terminal
ME Wireless Access Point
ME Crafting Terminal
ME Drive + (extra storage) Cell
ME Storage Bus, Priority 2 (ME Drive stayed on default 0)
Vanilla Chest connected to ME Storage Bus with 27 Stacks of highly valuable Creative Cheated Diamonds

Experiment:
Place a ME Annihilation Plane facing the Chest

Expected behavior:
The Chest will be broken down and added to the ME System.
The Diamonds will drop and at least a few of them touching the Annihilation Plane will be added to the ME System

Observed behavior:
The Chest will be added to the Storage Cell.
The Diamonds drop and get instantly deleted.

Originally posted as a bug report against WirelessCraftingTerminal, but this experiment revealed, that vanilla ME also causes the issues without the WCT.
-> p455w0rd/WirelessCraftingTerminal#279

@bothie bothie changed the title from Breaking a storage connected using a Storage Bus causes it's contents to be lost, if anything tried to add them back to the System immediatelly to Breaking a storage connected using a Storage Bus causes it's contents to be lost, if anything tries to add them back to the System immediatelly Aug 23, 2018

@bothie

This comment has been minimized.

bothie commented Aug 23, 2018

Setting the Storage Bus priority to -1 and placing the Annihilation Plane afterwards will correctly cause both, the Chest and it's contents to be added to the storge cell. My assumption is, that the ME System adds the Items to the already broken down Chest, meaning the ME System keeps a Reference to it's Tile Entity and even thou the block is already dead and the Tile Entity being invalid, the ME System just adds the items there anyway.

@yueh

This comment has been minimized.

Member

yueh commented Aug 30, 2018

Could be the reason for it. The inventory code in forge is a mess and can be a massive performance issue when being used on a larger scale. E.g. with AE. And for now they don't seem to care about providing a better implementation at any point in the future.

So we currently have to cut a few corners to not completely obliterate any performance, which cannot be fixed in a sane way currently. There should be a few things we could try, but it could easily be a regression for most users by solving a seemingly pretty rare edge case. Thus currently not sure, if it would be worth to fix it now.

@yueh yueh added the type-bug label Aug 30, 2018

yueh added a commit that referenced this issue Sep 26, 2018

@yueh yueh closed this in 038ca23 Sep 28, 2018

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