Bug Fix: was using int for time which was causing some errors.
- now using uint (unsigned int) for milliseconds time