Fixed item generation issues.

Fixed the issue when items generated in the laboratory sometimes
generated with stackSize of 0.