Fixed bug where items don't go into inventory in the right order.