private void Button_Click_Tree(object sender, RoutedEventArgs e) { mcts.PauseSearching(); mcts.WaitCycle(); Button button = sender as Button; if (button.Tag == null) { return; } Node node = button.Tag as Node; show(node); mcts.ResumeSearching(); }
void PauseSearching() { if (mcts != null) { mcts.PauseSearching(); } Dispatcher.Invoke(() => { ButtonStartAI.Content = "AI 생각 시작"; }); }
public void Load(Mcts mcts) { this.mcts = mcts; mcts.PauseSearching(); mcts.WaitCycle(); if (mcts.root.parent != null) { listUpTree(mcts.root.parent); show(mcts.root.parent); } else { listUpTree(mcts.root); show(mcts.root); } mcts.ResumeSearching(); }