I was fiddling around with flyout generators and I wanted this. So I 1) tried to write it then 2) realized I'm here to design cool crap and not reinvent the wheel and finally 3) found something and modified it a bit.
This is pretty basic but I made it recognize command line variables so that's nice I guess.
This is how far I got tonight, but I wanted to get this out there as I already think it can be useful. Let's make it better!
1. Use the Set User Var macro to set up some variables
2. Set $calc_string to something like "$var1+$var2*var3+6*($var1+$var3/$var2+143)"
3. No spaces! ^^^
4. Set $calc_store to the name of the user variable you would like the result stored in.
5. Call Macro "calc" or Lua "calc()"
6. Also you can just run Lua "calc('$var1+$var2*var3')" if you prefer.
1. Clamp calculations to real things
- The included Step ++ and Step -- macros should recognize when the real step value didn't change cause it's at 1 or max step +1 already.
2. Insert arbitrary MA stuff into calculations like selection width and such.
3. Run a calculation periodically based on a timer to keep vars up to date.
4. Pass variable to store result into the calc() function.