Guest User

Untitled

a guest
Feb 14th, 2016
154
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. countspeed = 1;
  2. clockStart = 0;
  3.  
  4. function times(n){
  5. if (n < 10) return "0" + n else return "" + n
  6. }
  7.  
  8. clockTime = clockStart +countspeed*(time - inPoint);
  9.  
  10. if (clockTime < 0){
  11. minus = "-";
  12. clockTime = -clockTime;
  13. }else{
  14. minus = "";
  15. }
  16.  
  17. t = Math.floor(clockTime);
  18. h = Math.floor(t/3600);
  19. min = Math.floor((t%3600)/60);
  20. sec = Math.floor(t%60);
  21. ms = clockTime.toFixed(3).substr(-3);
  22. minus + times(h) + ":" + times(min) + ":" + times(sec)
Advertisement
Add Comment
Please, Sign In to add comment