Beispiel #1
0
        void OnEnable()
        {
            //Store a reference to the AI Controller script
            manager  = (CandiceAIManager)target;
            soTarget = new SerializedObject(manager);

            guiStyle.fontSize  = 14;
            guiStyle.fontStyle = FontStyle.Bold;
        }
Beispiel #2
0
        static bool ManagerExists()
        {
            bool isExists = false;

            GameObject[] arrGO = FindObjectsOfType <GameObject>();
            int          count = 0;

            while (!isExists && count < arrGO.Length)
            {
                GameObject       go        = arrGO[count];
                CandiceAIManager aiManager = go.GetComponent <CandiceAIManager>();
                if (aiManager != null)
                {
                    isExists = true;
                }
                count++;
            }
            return(isExists);
        }