示例#1
0
        private void OnEnable()
        {
            if (!AvatarMakerInitializer.IsPlatformSupported())
            {
                Debug.LogError("Avatar plugin supports only Windows platform and works in the Editor mode.");
                return;
            }

            if (!AvatarMakerInitializer.IsInitialized)
            {
                AvatarMakerInitializer.StartInitialization();
            }

            avatarProvider = AvatarMakerInitializer.AvatarProvider;

            UpdateAvatarList();
        }
示例#2
0
        private void OnEnable()
        {
            if (!AvatarMakerInitializer.IsPlatformSupported())
            {
                Debug.LogError("Avatar plugin supports only Windows platform and works in the Editor mode.");
                return;
            }

            if (!AvatarMakerInitializer.IsInitialized)
            {
                AvatarMakerInitializer.StartInitialization();
            }

#if UNITY_2018_1_OR_NEWER
            EditorApplication.hierarchyChanged += OnHierarchyChanged;
#else
            EditorApplication.hierarchyWindowChanged += OnHierarchyChanged;
#endif
            OnHierarchyChanged();
        }