private static void btnResetGrid_Click(object sender, RoutedEventArgs e) { try { if (BotMain.IsRunning) { BotMain.Stop(); } if (!ZetaDia.IsInGame || !ZetaDia.Me.IsValid) { return; } Thread.Sleep(500); GridSegmentation.Reset(); GridSegmentation.Update(); BrainBehavior.DungeonExplorer.Reset(); BrainBehavior.DungeonExplorer.GetBestRoute(); } catch (Exception ex) { Logger.Log("Could not reset grid: {0}", ex); } }
internal static void UpdateGridSegmentation() { if (_navigateToCoroutine == null || _navigateToCoroutine.IsFinished) { _navigateToCoroutine = new Coroutine(async() => await GridSegmentation.Update()); } _navigateToCoroutine.Resume(); }
void btnResetGrid_Click(object sender, RoutedEventArgs e) { if (BotMain.IsRunning) { BotMain.Stop(); } if (!ZetaDia.IsInGame || !ZetaDia.Me.IsValid) { return; } System.Threading.Thread.Sleep(500); GridSegmentation.Reset(); GridSegmentation.Update(); BrainBehavior.DungeonExplorer.Reset(); BrainBehavior.DungeonExplorer.GetBestRoute(); }