A stow could duplicate what it moved.
Depositor.Deposittook the trip's share out of the source by writingitem.m_stackdirectly, and only calledInventory.RemoveItemonce the stack reached zero. A raw field write is invisible to the inventory:Inventory.Changednever fires, soContainer.OnContainerChangednever runs and the post's ZDO is never saved. The destination's side does save -AddItemcallsChanged- so the post reloaded its old contents from a stale ZDO, the stack came back, and the next trip moved it again. Measured at 21 coal in the post producing 140 in the chest.Only a partial take was affected, which is every trip of a stack larger than
ItemsPerTrip, and it needs a trip to actually land - so it was invisible for as long as the two bugs above kept trips from landing at all. The removal goes throughInventory.RemoveItem(item, amount)now, and the source is checked for the item before anything is added anywhere, because an add that succeeds beside a removal that fails is the definition of this bug.
Discussion
Nothing said yet.
Sign in or make an account to join in.