Example #1
0
    /// <summary>
    /// Get the list of creation functions, registering default ones as necessary.
    /// </summary>

    static public List <CachedFunc> GetRCCs()
    {
        if (rebuildMethodList)
        {
            rebuildMethodList = false;

            if (mInstance != null)
            {
                MonoBehaviour[] mbs = mInstance.GetComponentsInChildren <MonoBehaviour>();

                for (int i = 0, imax = mbs.Length; i < imax; ++i)
                {
                    MonoBehaviour mb = mbs[i];
                    AddRCCs(mb, mb.GetType());
                }
            }
            else
            {
                // Add the built-in remote creation calls
                AddRCCs <TNManager>();
            }
        }
        return(mRCCs);
    }