Forums > Max For Live

Can I save the contents of global variables within js objects with my live set?

April 20, 2011 | 3:42 am

I tried linking a pattr to my js object, but no dice.

I have a global array:

var global_stuff = new Array();

And I’m adding LiveAPI instances to it.

global_stuff[0] = new LiveAPI(callback, "id 42");

The array "global_stuff" get’s built during performance, but I’d like to save/reoad it with the live set.

Suggestions?


May 18, 2011 | 6:52 pm

i pretty new to max/msp enviorement, so may be that’s not a valid solution ( may be just an insight )..

1. save the ids in a table
2. save the table using the pattr
3. when the scripts loads again, rebuild your array based on the saved table

let me know if you figure out this, i’ll need to build a solution for this soon.


Viewing 2 posts - 1 through 2 (of 2 total)