コード例 #1
0
        public void OnPulse()
        {
            if (ZetaDia.CurrentQuest == null || ZetaDia.CurrentQuest.QuestSnoId == -1)
            {
                Core.Logger.Debug("Waiting while Quest is invalid (-1)");
                BotMain.PauseFor(TimeSpan.FromSeconds(1));
            }

            HookManager.CheckHooks();
            GameUI.SafeClickUIButtons();
            VisualizerViewModel.Instance.UpdateVisualizer();
        }
コード例 #2
0
 public void OnDisabled()
 {
     IsEnabled        = false;
     BotMain.OnStart -= OnStart;
     BotMain.OnStop  -= OnStop;
     TabUi.RemoveTab();
     HookManager.CheckHooks();
     Navigator.PlayerMover               = new DefaultPlayerMover();
     Navigator.StuckHandler              = new DefaultStuckHandler();
     CombatTargeting.Instance.Provider   = new DefaultCombatTargetingProvider();
     LootTargeting.Instance.Provider     = new DefaultLootTargetingProvider();
     ObstacleTargeting.Instance.Provider = new DefaultObstacleTargetingProvider();
     ItemManager.Current             = new BlankItemManager();
     Zeta.Bot.RoutineManager.Current = null;
     ModuleManager.Disable();
     s_logger.Information($@"{Name} v{Version} is now DISABLED.");
 }
コード例 #3
0
        public void OnEnabled()
        {
            using (ZetaDia.Memory.AcquireFrame())
            {
                if (IsEnabled || !Application.Current.CheckAccess())
                {
                    return;
                }

                Core.Init();
                BotMain.OnStart += OnStart;
                BotMain.OnStop  += OnStop;
                TrinitySettings.InitializeSettings();
                SkillUtils.UpdateActiveSkills();
                HookManager.CheckHooks();
                TabUi.InstallTab();
                SetupDemonBuddy();
                UILoader.PreLoadWindowContent();
                ModuleManager.Enable();
                s_logger.Information($@"{Name} v{Version} is now ENABLED.
{Description}");
                IsEnabled = true;
            }
        }
コード例 #4
0
 private void OnStart(IBot bot)
 {
     HookManager.CheckHooks();
 }