[DatFile] Add other standalone statuses

This commit is contained in:
Matt Nadareski
2016-10-04 13:54:47 -07:00
parent 5d4f19738d
commit 65fc747353

View File

@@ -1401,7 +1401,8 @@ namespace SabreTools.Helper
{
continue;
}
// Special cases for item statuses
// Special cases for standalone item statuses
else if (gc[i] == "baddump" && attrib != "name" && attrib != "status" && attrib != "flags")
{
if (item.Type == ItemType.Rom)
@@ -1413,6 +1414,17 @@ namespace SabreTools.Helper
((Disk)item).ItemStatus = ItemStatus.BadDump;
}
}
else if (gc[i] == "good" && attrib != "name" && attrib != "status" && attrib != "flags")
{
if (item.Type == ItemType.Rom)
{
((Rom)item).ItemStatus = ItemStatus.Good;
}
else if (item.Type == ItemType.Disk)
{
((Disk)item).ItemStatus = ItemStatus.Good;
}
}
else if (gc[i] == "nodump" && attrib != "name" && attrib != "status" && attrib != "flags")
{
if (item.Type == ItemType.Rom)
@@ -1424,6 +1436,18 @@ namespace SabreTools.Helper
((Disk)item).ItemStatus = ItemStatus.Nodump;
}
}
else if (gc[i] == "verified" && attrib != "name" && attrib != "status" && attrib != "flags")
{
if (item.Type == ItemType.Rom)
{
((Rom)item).ItemStatus = ItemStatus.Verified;
}
else if (item.Type == ItemType.Disk)
{
((Disk)item).ItemStatus = ItemStatus.Verified;
}
}
// Even number of quotes, not in a quote, not in attribute
else if (Regex.Matches(gc[i], "\"").Count % 2 == 0 && !quote && attrib == "")
{