Skip to content

Commit

Permalink
Fix GR2 conversion in CLI
Browse files Browse the repository at this point in the history
  • Loading branch information
Norbyte committed Oct 7, 2018
1 parent 0c5e5d4 commit 9cee358
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 12 deletions.
23 changes: 11 additions & 12 deletions Divine/CLI/CommandLineArguments.cs
Expand Up @@ -100,7 +100,7 @@ public class CommandLineArguments
[EnumeratedValueArgument(typeof(string), "gr2-options",
Description = "Set extra options for GR2/DAE conversion",
AllowMultiple = true,
AllowedValues = "export-normals;export-tangents;export-uvs;export-colors;deduplicate-vertices;deduplicate-uvs;filter-uvs;recalculate-normals;recalculate-tangents;recalculate-iwt;flip-uvs;force-legacy-version;compact-tris;build-dummy-skeleton;apply-basis-transforms;conform",
AllowedValues = "export-normals;export-tangents;export-uvs;export-colors;deduplicate-vertices;deduplicate-uvs;recalculate-normals;recalculate-tangents;recalculate-iwt;flip-uvs;force-legacy-version;compact-tris;build-dummy-skeleton;apply-basis-transforms;conform",
ValueOptional = false,
Optional = true
)]
Expand Down Expand Up @@ -310,21 +310,20 @@ public static PackageVersion GetPackageVersion(string packageVersion)
{
Dictionary<string, bool> results = new Dictionary<string, bool>
{
{ "export-normals", false },
{ "export-tangents", false },
{ "export-uvs", false },
{ "export-colors", false },
{ "deduplicate-vertices", false },
{ "deduplicate-uvs", false },
{ "filter-uvs", false },
{ "export-normals", true },
{ "export-tangents", true },
{ "export-uvs", true },
{ "export-colors", true },
{ "deduplicate-vertices", true },
{ "deduplicate-uvs", true },
{ "recalculate-normals", false },
{ "recalculate-tangents", false },
{ "recalculate-iwt", false },
{ "flip-uvs", false },
{ "flip-uvs", true },
{ "force-legacy-version", false },
{ "compact-tris", false },
{ "build-dummy-skeleton", false },
{ "apply-basis-transforms", false },
{ "compact-tris", true },
{ "build-dummy-skeleton", true },
{ "apply-basis-transforms", true },
{ "conform", false }
};

Expand Down
4 changes: 4 additions & 0 deletions Divine/Program.cs
Expand Up @@ -10,6 +10,10 @@ internal class Program

private static void Main(string[] args)
{
System.Globalization.CultureInfo customCulture = (System.Globalization.CultureInfo)System.Threading.Thread.CurrentThread.CurrentCulture.Clone();
customCulture.NumberFormat.NumberDecimalSeparator = ".";
System.Threading.Thread.CurrentThread.CurrentCulture = customCulture;

CommandLineParser.CommandLineParser parser = new CommandLineParser.CommandLineParser
{
IgnoreCase = true,
Expand Down

0 comments on commit 9cee358

Please sign in to comment.