Пример #1
0
        public void OnApplicationStart()
        {
            IngameInformationsCounter.OnLoad();
            SceneManager.activeSceneChanged += SceneManagerOnActiveSceneChanged;
            SceneManager.sceneLoaded        += SceneManager_sceneLoaded;
            PluginConfig.LoadOrCreateConfig();
            HarmonyInstance harmony = HarmonyInstance.Create("com.Shoko84.beatsaber.BeatSaberDrinkWater");

            harmony.PatchAll(Assembly.GetExecutingAssembly());
        }
 public void Awake()
 {
     if (Instance == null)
     {
         Instance = this;
         SceneManager.activeSceneChanged += SceneManagerOnActiveSceneChanged;
         DontDestroyOnLoad(gameObject);
         CurrentPlaycount = 0;
         IngameTimeSpent  = new TimeSpan(0);
     }
     else
     {
         Destroy(this);
     }
 }