private void ExportObjExecuted(object sender, ExecutedRoutedEventArgs e) { FolderBrowserDialog.FolderBrowserDialog dialog = new FolderBrowserDialog.FolderBrowserDialog { ShowEditBox = true, BrowseShares = true }; dialog.RootType = FolderBrowserDialog.RootType.Path; //dialog.RootPath = Engine.Instance.GetBaseDirectory(); if (dialog.ShowDialog() != true) { return; } string dirPath = dialog.SelectedPath; M2SceneNode node = ModelSceneService.Instance.MainM2SceneNode; bool success = mwTool.Instance.ExportM2SceneNodeToOBJ(node, dirPath); if (success) { NativeMethods.ShellExecute( IntPtr.Zero, "open", "Explorer.exe", dirPath, "", NativeMethods.ShowCommands.SW_NORMAL); } }
private void exportAsTgaNoAlphaExecuted(object sender, ExecutedRoutedEventArgs e) { FolderBrowserDialog.FolderBrowserDialog dialog = new FolderBrowserDialog.FolderBrowserDialog { ShowEditBox = true, BrowseShares = true }; dialog.RootType = FolderBrowserDialog.RootType.Path; //dialog.RootPath = Engine.Instance.GetBaseDirectory(); if (dialog.ShowDialog() != true) { return; } string dirPath = dialog.SelectedPath; bool success = mwTool.Instance.ExportBlpAsTgaDir( ModelSceneService.Instance.CurrentTextureName, dirPath, false); if (success) { NativeMethods.ShellExecute( IntPtr.Zero, "open", "Explorer.exe", dirPath, "", NativeMethods.ShowCommands.SW_NORMAL); } }