SetParentWithoutLosingInfo() публичный статический Метод

Set the transform to onther transform in the hierarchy and without losing the info. Info: position, rotation, scale, etc.
public static SetParentWithoutLosingInfo ( Transform trans, Transform parent ) : void
trans Transform transform to set to parent transform
parent Transform parent transform
Результат void
        /// <summary>
        /// Spawn the text pool base on number of handle.
        /// </summary>
        private void SpawnTextPool()
        {
            if (mLogText == null)
            {
                JCS_Debug.LogReminder( 
                    "No log text assign in the text pool...");

                return;
            }


            // NOTE(JenChieh): this might change in
            // the future.
            // Get the log system from the 
            // same transfrom/node.
            JCS_IGLogSystem logSystem = this.GetComponent<JCS_IGLogSystem>();


            mLogTexts = new JCS_Vector<JCS_LogText>(mNumberOfHandle);

            for (int count = 0;
                count < mNumberOfHandle;
                ++count)
            {
                // spawn a new game object, 
                // and get the component
                JCS_LogText logText = (JCS_LogText)JCS_Util.SpawnGameObject(mLogText);

                // add to array
                mLogTexts.set(count, logText);

                // set parent
                JCS_Util.SetParentWithoutLosingInfo(logText.transform, this.transform);

                // NOTE(JenChieh): this might change in
                // the future.
                // set the log system if there is one.
                logText.SetIGLogSystem(logSystem);
            }
        }