示例#1
0
 public void OnSceneLoaded(Scene arg, LoadSceneMode hiBrian)
 {
     try
     {
         if (arg.name == "MenuCore")
         {
             MenuUI.CreateUI();
         }
     }catch (Exception e)
     {
         Log(e.ToString(), LogInfo.Fatal, "Install your dependencies!");
     }
 }
示例#2
0
        public void OnApplicationStart()
        {
            try
            {
                harmonyInstance = new Harmony(harmonyId);
                harmonyInstance.PatchAll(System.Reflection.Assembly.GetExecutingAssembly());
            }
            catch (Exception ex)
            {
                Log($"{ex.Message}", LogInfo.Fatal, "Unable to apply Harmony patches. Did you even install BSIPA correctly?");
            }

            CountersController.OnLoad();
            MenuUI.CreateUI();
        }