Moved SDL init stuff to its own function