Tasharen Entertainment Forum
Support => NGUI 3 Support => Topic started by: noob22 on July 02, 2012, 12:15:54 AM
-
Do I need to use U3D's API "FindChild"?It's not efficient!
Any suggestion?
-
How many times do you need to find it? In most cases you should, at most, need to find it once and then store a reference to it in a class variable of whatever script you are trying to utilize it.
-
How many times do you need to find it? In most cases you should, at most, need to find it once and then store a reference to it in a class variable of whatever script you are trying to utilize it.
Thanks for your reply!
If I need to clone much UI sprite at random position.Sometimes they are visiable and sometimes they are invisiable.Do I use "Instantiate" and "Destroy"?It is not efficient!Any suggestion?
-
Implementation details can vary greatly with what you're trying to do and the complexity of your UI. As Burton said though, find what you need once, and store the reference. Instantiate/destroy can be replaced with enable/disable instead.
-
Implementation details can vary greatly with what you're trying to do and the complexity of your UI. As Burton said though, find what you need once, and store the reference. Instantiate/destroy can be replaced with enable/disable instead.
Thanks for your reply!I have got it.