Page 1 of 1

Action Script from Direct Input

PostPosted: Sat Sep 08, 2018 10:10 am
by djrappa
A common workflow for me is to feed a value to a label output node, then create a label, then create an action script node to perform functions based on that label.

But all I really want to do is perform functions based on that original value. It would be great to be able to wire an input or filter node directly to an Action Script and then have it evaluate based on that input.

This saves the creation of many many extra nodes and labels and scripting.

Example of the present workflow attached.

Re: Action Script from Direct Input

PostPosted: Sat Sep 08, 2018 1:34 pm
by justyn roy
Why can you not use a "Script Node" directly for this?

Re: Action Script from Direct Input

PostPosted: Sun Sep 09, 2018 4:19 am
by djrappa
Do you mean the "Script Output" node?

If so because this relies on resolving a IF SOURCE OPERATOR COMPARISON logic to evaluate the script.

Where as the Action Script will just evaluate every time the input changes.
Unless there is something I don't know, if so I'd be keen to hear how to achieve this functionality already.

Thanks

Re: Action Script from Direct Input

PostPosted: Tue Sep 11, 2018 2:37 pm
by AViefhues
just use the input as source and comparison:
If [1 Value] = [1 Value] Then....

Everything is just performed if the input changed.

Re: Action Script from Direct Input

PostPosted: Mon Sep 17, 2018 5:04 am
by djrappa
I did not know this! Thanks for the tip.

Re: Action Script from Direct Input

PostPosted: Tue Oct 02, 2018 4:20 am
by djrappa
Additional to this... say I'm using the Script output node... How can I reference the value being fed into that node in the script?