Code: Select all
			local gridinventory = armor.grid.take_all()
			for gear, cnt in pairs(gridinventory) do
				if player.can_insert({name=gear, count=cnt}) then
					player.insert({name=gear, count=cnt})
				else
					--player.print("WARNING: Inventory full.")
					player.surface.spill_item_stack(player.position,{name=gear, count=cnt})
				end
			endSpeculatively, this may happen because of slots available in the quickbar or other specialized inventory slots.

