Finished crude spacing. Code is embarassingly ugly
Reworked to be more functional.