Tasharen Entertainment Forum
Support => NGUI 3 Support => Topic started by: qn9663 on September 04, 2013, 01:06:00 AM
-
// change by qn
// first center One GameObject
// last void OnEnable () { Recenter(); } but mDrag.panel == null
void OnEnable () { StartCoroutine(YieldStart());}
//first OnEnable can't find mDrag.panel == null
IEnumerator YieldStart(){
yield return null;
Recenter();
}
-
Why is it null? You might have a script execution order issue. Just set it to execute after the standard time.