forked from mirrors/NBTExplorer
Change natural comparer to respect negative numbers
This commit is contained in:
parent
db5d2a05c0
commit
7a151d3e6f
1 changed files with 2 additions and 2 deletions
|
@ -29,11 +29,11 @@ namespace NBTExplorer.Utility
|
||||||
}
|
}
|
||||||
string[] x1, y1;
|
string[] x1, y1;
|
||||||
if (!table.TryGetValue(x, out x1)) {
|
if (!table.TryGetValue(x, out x1)) {
|
||||||
x1 = Regex.Split(x.Replace(" ", ""), "([0-9]+)");
|
x1 = Regex.Split(x.Replace(" ", ""), "(-?[0-9]+)");
|
||||||
table.Add(x, x1);
|
table.Add(x, x1);
|
||||||
}
|
}
|
||||||
if (!table.TryGetValue(y, out y1)) {
|
if (!table.TryGetValue(y, out y1)) {
|
||||||
y1 = Regex.Split(y.Replace(" ", ""), "([0-9]+)");
|
y1 = Regex.Split(y.Replace(" ", ""), "(-?[0-9]+)");
|
||||||
table.Add(y, y1);
|
table.Add(y, y1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue