Fixing timing bugs by putting the counter on it's own variable that is set by a setter method.