Created loops and main SDL stuff