Fixed some stupid errors with ints not being doubles.