-
jump to variables from slider
hey guys,
I’m trying to get a null to snap to 4 (or more) positions based on a slider value.
The script I’m using is this:
s = thisComp.layer(“COG”).effect(“Torso_Turn”)(“Slider”);
a = [250,49.5];
b = [450,49.5];
c = [380,-30.5];
if (s <10) linear(s,100,0,a,b);
else linear(s,0,100,b,c);But what i need is for the position to “jump” to the positions instead of sliding to them. What’s the best way to say:
If s = 0-25 then position “a”
if s = 25-50 then position “b”
if s = 50-75 then position “c”
etcis there a simple way to do that?