fixed some pausing bugs.