playMaker

Author Topic: How to access child object after using "nGUI Tools Add Child"?  (Read 1753 times)

Ony

  • Playmaker Newbie
  • *
  • Posts: 8
How to access child object after using "nGUI Tools Add Child"?
« on: October 09, 2014, 09:42:24 PM »
I'm new with Playmaker and nGUI and still trying to wrap my brain around certain concepts, so forgive me if the answer to this is obvious. :)

I am using the nGUI Tools Add Child action to add spell slots (with FSMs of their own) into an nGUI grid. The grid contains the FSM with the action that adds the children.

I've got that working just fine, but I'm not sure how to access one of the child objects once it's been added, so I can do more stuff to it in the same action list that added it.

Is there a pointer variable to the child game object some where I'm missing?

Thanks!

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: How to access child object after using "nGUI Tools Add Child"?
« Reply #1 on: December 02, 2014, 11:07:16 AM »
Hi,

 It depends your search criterias, typically, in all cases I would suggest the following:

 maintain using ArrayMaker the list of spells, and directly save the ngui gameobject responsible for showing as an item in the ngui list, then you don't need to search the ngui list, indeed you search your own list, whicih is going to be much better in the long run.

 Bye,

 Jean