I am using a bpatcher for a widget, and it’s driven by a js object. I need the loadbang() method to execute when i copy and paste the widget, but it doesn’t seem to … loadbang() only happens when I create the bpatcher from scratch. Why is that? Is there an alternate method I should be using?
Loadbang() only gets called when the patch initally opens. There might be an easier way to do it, but I’d probably do something like this:
//whatever you had in loadbang()
//this will call the function whenever a new js instance is created in your patch
I haven’t used Globals for a while (I kinda try to stay away from them in m4l due to threading issues), and my syntax might be wrong, but the general idea should work.