Trying to make the code more python3 friendly.

Although there's still no support for pygame in python3