Fixed the probabilites, they now work properly. They were doing integer division instead of double division.