private void Open(object sender, RoutedEventArgs e)
{
e.Handled = true;
if (this.PreGameLobby.Visibility == Visibility.Visible) return;
if (Player.LocalPlayer.Spectator) return;
var loadDirectory = Program.GameEngine.Definition.GetDefaultDeckPath();
// Show the dialog to choose the file
var ofd = new OpenFileDialog
{
Filter = "Octgn deck files (*.o8d) | *.o8d",
InitialDirectory = loadDirectory
};
//ofd.InitialDirectory = Program.Game.Definition.DecksPath;
if (ofd.ShowDialog() != true) return;
// Try to load the file contents
LoadDeck(ofd.FileName);
}