Refactor Ship processing