made the necessary for version 3 + changed my variables to be floats in stead of integers. I have to start thinking 'float'...