Fixed button bugs. However, rounding errors cause problems. #2