// Clear All Hook public void clearHooking() { if (hooker != null) { hooker.Clear(); } debugLog("[Action] Hooks cleared"); }
private void ButtonConfig_Click(object sender, RoutedEventArgs e) { ConfigEditorWindow configWindow = new(DataPath, AmeisenBot, AmeisenBot.Config, AmeisenBot.AccountName); configWindow.ShowDialog(); if (configWindow.SaveConfig) { AmeisenBot.ReloadConfig(configWindow.Config); File.WriteAllText(AmeisenBot.Config.Path, JsonSerializer.Serialize(configWindow.Config, new() { WriteIndented = true })); KeyboardHook.Clear(); LoadHotkeys(); } }