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

AE2 blocks not updating comparators #446

Closed
yueh opened this issue Nov 16, 2014 · 4 comments
Closed

AE2 blocks not updating comparators #446

yueh opened this issue Nov 16, 2014 · 4 comments
Labels
bug

Comments

@yueh
Copy link
Member

@yueh yueh commented Nov 16, 2014

Most (or all?) AE2 blocks with inventories are not updating attached comparators if the inventory is changed through any automation.

This only happens with a forced update through an adjacent block.

@yueh yueh added the bug label Nov 16, 2014
@AlgorithmX2
Copy link
Contributor

@AlgorithmX2 AlgorithmX2 commented Nov 16, 2014

Which automation? AE2 automation? I'm pretty sure that comparators update when you call "TileEntity.markDirty()" or whatever its called.

@yueh
Copy link
Member Author

@yueh yueh commented Nov 16, 2014

Currently looking through the blocks. Looks like it does not work with at least with

  • Both IO Ports
  • Grindstone
  • Interface
  • Drive
  • Vibration Chamber

Cannot really test the ME chest.

It looks like it is related to AE2 automation. Simple setup with an interface as buffer and a storage bus facing one of the AE2 blocks. If I use a hopper to insert any items it works just fine.

Already found out, that calling TileEntity.markDirty() in onChangeInventory() it will solve it.
The question is more, how could this affect the performance.
It is probably fine for things like the IO Ports or Grindstone, but chaning it for an interface might have a huge impact.

@AlgorithmX2
Copy link
Contributor

@AlgorithmX2 AlgorithmX2 commented Nov 16, 2014

Yes, sadly markDirty is pretty expensive, but it should be called without it the chunk won't be saved and item loss can occur as well. I honestly thought I already touched on this but it may have regressed or maybe I just thought I did.

@yueh
Copy link
Member Author

@yueh yueh commented Nov 17, 2014

Could this no also enable a dupe bug? @FireBall1725 mentioned something about one with a heavily loaded ME system.

I have one case in mind, but cannot check it until tomorrow.

thatsIch pushed a commit that referenced this issue Nov 19, 2014
thatsIch
Added a missing markDirty in AdaptorIInventory to update other inventories on inserting items, fixes #446
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.