Refactors breed function to improve readability and clutter.