Added ability to just center window, moved some stuff into functions