mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2025-01-31 04:40:55 +00:00
OBJ Exporter: fixed a bug where the .mtl file also had .obj in its name
This commit is contained in:
parent
7e5c407722
commit
385338ec42
1 changed files with 4 additions and 2 deletions
|
@ -264,8 +264,10 @@ namespace CodeImp.DoomBuilder.BuilderModes.IO
|
|||
// Make sure the directory is there
|
||||
Directory.CreateDirectory(Path.GetDirectoryName(savePath));
|
||||
|
||||
string mtlPath = Path.Combine(Path.GetDirectoryName(savePath), Path.GetFileNameWithoutExtension(savePath) + ".mtl");
|
||||
|
||||
// Write mtl (only if not exporting for GZDoom, since it will be ignored anyway
|
||||
using (StreamWriter sw = new StreamWriter(savePath + ".mtl", false))
|
||||
using (StreamWriter sw = new StreamWriter(mtlPath, false))
|
||||
sw.Write(mtl.ToString());
|
||||
}
|
||||
else
|
||||
|
@ -348,7 +350,7 @@ namespace CodeImp.DoomBuilder.BuilderModes.IO
|
|||
}
|
||||
|
||||
//done
|
||||
General.Interface.DisplayStatus(StatusType.Warning, "Geometry exported to \"" + savePath + ".obj\"");
|
||||
General.Interface.DisplayStatus(StatusType.Warning, "Geometry exported to \"" + savePath);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
|
Loading…
Reference in a new issue