Add in support for python 3. Still works with python 2

I didn't do much. It works now. It also fixed that weird v-sync like issue I was getting before, even in python 2.