playMaker

Author Topic: How to create Array of other Arrays  (Read 963 times)

Aaddiction

  • Full Member
  • ***
  • Posts: 166
How to create Array of other Arrays
« on: December 30, 2020, 03:57:49 PM »
I have a logic where I select an item from an array. However at the beginning of the FSM I want to switch between different arrays and use the same FSM loop to select from different game objects of the pre-selected array. Any ideas how to do that at play mode?

As per the attached image I'd like to be able to switch between the different arrays.
If I can create an array of arrays then I will just index the car class array in the main array and voila.
« Last Edit: December 31, 2020, 06:33:51 AM by Aaddiction »

heavygunner

  • Sr. Member
  • ****
  • Posts: 344
Re: How to create Array of of other Arrays
« Reply #1 on: December 30, 2020, 08:51:33 PM »
Create new Array (String) and add all array names there.  :)

Aaddiction

  • Full Member
  • ***
  • Posts: 166
Re: How to create Array of of other Arrays
« Reply #2 on: December 31, 2020, 06:27:31 AM »
Create new Array (String) and add all array names there.  :)

But the Array Lenght action does not accept Array (String), it should be Array (GameObject)

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7616
    • jinxtergames
Re: How to create Array of other Arrays
« Reply #3 on: December 31, 2020, 09:07:33 AM »
Hi.
I would suggest looking into Array Maker
Its more advanced and easier to reference (using a string you can easily target other arrays)
Make sure to use the reset before starting a new loop.