Lua Features in Foldit

Started by Tlaloc

Tony Origami Lv 1

I believe there is a missing command for a wiggle of an unselected protein. do_global_wiggle_all(num) works only on a selected protein and produces a different effect and score from the wiggle from the interface of an unselected protein. This makes it very difficult to reproduce by script a procedure which works by hand.

Rav3n_pl Lv 1

Looks like pressing one of GUI buttons making another things than lua functions.
It is very wisible on 425 where gui wiggle button on unselected is much better than select_all() go_global_wiggle_all() in lua.

We need:
gui_wiggle_all(n)
gui_local_wiggle(n)
Not sure about shake and mutate, if are different we should have ability to call them too.

Tony Origami Lv 1

How easy would it to be to extend the upper limit of clashing importance? I don't know what the limit should be because it will depend on effect - perhaps 2, perhaps 100?

If it is easy to accomplish, it would be something else we could try.

Tony Origami Lv 1

Is it possible to have a routine run on pressing the cancel button to allow us to return the environment to a desired state? Currently cancellation can leave clashing importance set wrong and bands lying about etc.

Rav3n_pl Lv 1

leave bands alone!
I often use bands created by one script to use in another (ie quake + GAB).
CI can be set to initial or "just" to 1.0 after break.

Maybe "pause script" button to mess between commands or share/screen shoot current state?

Tony Origami Lv 1

The intention would be for the programmer who wrote the script to be able to specify what was cleaned up and what was not. In other words, have an on_exit() function which will do nothing by default but in which cleanup can be done if desired.

B_2 Lv 1

Maybe you like to leave bands lying around, but some of us like to have the bands cleared, Clashing Importance re-set to 1.0, and Structures Restored when a recipe/script is cancelled.

infjamc Lv 1

Surely an even better option is to allow the user the option to designate the exact actions to take when a recipe/script is canceled (which can be set to "do nothing" by default)?