(question) is it possible to have a list of arrays, to become editable or target?

not exactly 2D arrays, but like having a list that can add new arrays to be created in an editable? and/or how you would target new editable arrays, like device array?

like if one can’t x+1 for each name/variable for creating an array and cycling through new arrays, or if one has to set a new array row inside a 2D array?

or putting it another way

create y array, get to use y array with other arrays/groups etc.

create Y in B =(B + Y +..), able to access or use Y.

Because I really want to use multiple different array connections on the same device rather than multiple devices, and if its more or less is going to do the same thing for each editable class or editable containers?

I guess another thing would be calling it inserting an array to a list.

Hello @1-DUCK-1 how are you?

If I understood it well, you can create a class with the different types of array you want to use and then add arrays of that type to your device. you should end with something like this:

# Custom class with your editable array
ArrayGroup := class :
    @editable
    var Elements_Triggers : []trigger_device = array{}

# Your device
Array_of_Arrays := class(creative_device):
    @editable
    var DeviceGroups : []ArrayGroups = array{}

This device will look like this:

You can also add more than one type of array in your class:

# Custom class with my editable arrays
ArrayGroups := class :
    @editable
    var Elements_Triggers : []trigger_device = array{}
    @editable
    var Elements_Ints : []int = array{}

# A Verse-authored creative device that can be placed in a level
Array_of_Arrays := class(creative_device):

    @editable
    var DeviceGroups : []ArrayGroups = array{}

Ending with something like this in the editor:

But if you want to separate the type of data of each array, you will need to create a new class for each type:

# Custom class with my editable arrays
ArrayGroup_Trigger := class :
    @editable
    var Elements_Triggers : []trigger_device = array{}

ArrayGroup_Int := class :
    @editable
    var Elements_Ints : []int = array{}

# A Verse-authored creative device that can be placed in a level
Array_of_Arrays := class(creative_device):

    @editable
    var TriggerGroup : []ArrayGroup_Trigger = array{}
    @editable
    var IntGroup : []ArrayGroup_Int = array {}

Which looks like this:

Hope this helps you with what you are trying to do!

2 Likes

oh I see now, so its an array editable class inside another editable class with editable array. I guess one can’t separate when a new array is created? would think this is my only solution, thanks for the help :slight_smile: like if one had an “endless” wave tool, so if setting up 5 spawner arrays would become 5 waves, etc. could just be silly thinking.