-
Is it possible for a value to only be influenced by rising input?
I hope I titled that right. I’ve searched the forums but haven’t found anything, perhaps because I’m not using the right terminology.
The problem is simply this, can and how would I write and expression that rises when the input it’s referencing rises, but stays static when that referenced input lowers?
I’ve included the code I’m using currently below. Predictably, it resets to 0 when the referenced value decreases. I would like it to stay at the last value it was at, rather than resetting. Basically it would be as if the downward shift never occurred.
Thank you all in advance.
x = value[0];
y = value[1];
rot = thisComp.layer("Null 1").transform.rotation;
rotPast = rot.valueAtTime(time-1);if (rot - rotPast >= 0){
rise = rot
}else{
rise = 0
}ny = y + (rise*-10);
[x,ny];