Basically, the reverse of abs. If I have:
if ($this.find(\'.pdxslide-activeSlide\').index() < slideNum - 1) { slideNum = -slideNum } console.log(slideNu
To get a negative version of a number in JavaScript you can always use the ~ bitwise operator.
~
For example, if you have a = 1000 and you need to convert it to a negative, you could do the following:
a = 1000
a = ~a + 1;
Which would result in a being -1000.
a
-1000