Created
March 23, 2018 20:41
-
-
Save aferriss/3bb9f3fe26c581b9ff130644c98d52f2 to your computer and use it in GitHub Desktop.
Countdown timer expression in AE in minutes and secs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rate = -1; | |
clockStart = 420; // num seconds | |
function padZero(n){ | |
if (n < 10) return "0" + n else return "" + n | |
} | |
clockTime = Math.max(clockStart + rate*(time - inPoint),0); | |
t = Math.floor(clockTime); | |
min = Math.floor((t%3600)/60); | |
sec = Math.floor(t%60); | |
min + ":" + padZero(sec) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
idk why this isn't work for me because of the syntax problem
can anyone help me?