Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Countdown from AD to BC

  • Countdown from AD to BC

    Posted by Alokin Sugar on May 7, 2015 at 2:59 pm

    Hi everyone longtime reader of the forum first time poster.
    As the title says im stuck on how to make a counter/slider combo to output a number with the letters AD on the left side of the number, when this number counts down past zero it shows a – sign and I’d like to hide or remove that and continue to count. Is it even possible to replace the AD with BC after it passes zero?

    John Cuevas replied 11 years, 4 months ago 2 Members · 1 Reply
  • 1 Reply
  • John Cuevas

    May 8, 2015 at 5:27 pm

    Sure, you would use a slider to create the numbers then input them into a text field using:

    Math.round(Math.abs(thisComp.layer("Controls").effect("Slider Control")("Slider")))

    Round just rounds the slider number and Math.abs uses just absolute value of the number, ignoring whether it’s postive or negative.

    For the AD/BC, you connect to the same slider and use an If/Else statement.

    var date = ["AD","BC"]
    myInput = thisComp.layer("Controls").effect("Slider Control")("Slider");

    if (myInput > 0) date[0] else date[1]

    Here’s a simple project with it all worked out: 8822_datecountdown.aep.zip

    Johnny Cuevas, Editor
    Thinkck.com

    “I have not failed 700 times. I have succeeded in proving that those 700 ways will not work. When I have eliminated the ways that will not work, I will find the way that will work.”
    —THOMAS EDISON on inventing the light bulb.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy