Equivalent to an ArrayList?

w4ffl35's icon

Is there any combination of objects that will produce the equivalent of an ArrayList? I'm dealing with dynamically creating [jit.gl.gridshape] objects and coming from a more standard coding background it makes sense to track the attributes in a database-y fashion.

Attached is my attempt at this problem. I'm using a [dict] and passing in the object's name and position, then retrieving them later. It's just the [dict] needs to be constantly updated with these position values, and I feel it could get a bit unwieldy if I wanted to track more than just the position.

I'm evening entertaining the thought of creating an mxj object or external, though I'd like to stay within the bounds of Max/MSP if I can.

Max Patch
Copy patch and select New From Clipboard in Max.

Thanks!

Roman Thilenius's icon

for bigger projects maybe think of using a "real" database such as with the mysql object.