Beispiel #1
0
        void Awake()
        {
            VRCModLogger.Log("[ModComponent] Awake called");
            DontDestroyOnLoad(gameObject);
            Instance = this;

            try
            {
                ModManager.LoadMods();
            }
            catch (Exception e)
            {
                VRCModLogger.Log("An error occured while loading mods: " + e);
            }

            mods = new CompositeModCaller(ModManager.ModControllers);
            mods.OnApplicationStart();

            SceneManager.sceneLoaded += (scene, method) =>
            {
                VRCModLogger.Log("[ModComponent] Scene Loaded: " + scene.name);
                if (scene.name == "ui")
                {
                    StartCoroutine(StartVRModules());
                }
            };
        }
Beispiel #2
0
 void OnDestroy()
 {
     try
     {
         ModComponent.Create();
     }
     catch (Exception e)
     {
         VRCModLogger.LogError(e.ToString());
     }
 }
Beispiel #3
0
        void Awake()
        {
            VRCModLogger.Log("[ModComponent] Awake called");
            DontDestroyOnLoad(gameObject);
            Instance = this;

            if (VRCToolsUpdater.CheckForVRCToolsUpdate())
            {
                VRCToolsUpdater.SheduleVRCToolsUpdate();
            }
            else
            {
                mods = new CompositeModCaller(ModManager.ModControllers);
                mods.OnApplicationStart();
            }
        }
Beispiel #4
0
 private static void Bootstrapper_Destroyed()
 {
     ModComponent.Create();
 }