I've been trying to understand how to use it but there is no example in the documentation:
I'm making a scoring label (with a Tween Position) that is spawned above an Enemy gameObject when the enemy is destroyed.
But the "from" and "to" parameters seem to be in World coordinates where was my prefab have local coordinates.
I know I'm supposed to use AddChild() but how can I add a child to a gameObject I'm about to destroy? Any alternative to Instantiate()?
Also I tried to do something like:
scoringPrefab.transform.position = NGUIMath.OverlayPosition(
scoringPrefab.transform,
enemyInstance.transform,
theCamera,
theCamera) ;
But I get the error: : 'OverlayPosition' is not a member of 'NGUIMath'.
What can I do to make this work?
Thanks in advance