mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
added defaultspecialpattern
This commit is contained in:
@@ -20,6 +20,7 @@ namespace SabreTools
|
|||||||
|
|
||||||
// Regex File Name Patterns
|
// Regex File Name Patterns
|
||||||
private static string _defaultPattern = @"^(.+?) - (.+?) \((.*) (.*)\)\.dat$";
|
private static string _defaultPattern = @"^(.+?) - (.+?) \((.*) (.*)\)\.dat$";
|
||||||
|
private static string _defaultSpecialPattern = @"^(.+?) - (.+?) \((.*) (.*)\)\.xml$";
|
||||||
private static string _mamePattern = @"^(.*)\.xml$";
|
private static string _mamePattern = @"^(.*)\.xml$";
|
||||||
private static string _maybeIntroPattern = @"(.*?) \[T-En\].*\((\d{8})\)\.dat$";
|
private static string _maybeIntroPattern = @"(.*?) \[T-En\].*\((\d{8})\)\.dat$";
|
||||||
private static string _noIntroPattern = @"^(.*?) \((\d{8}-\d{6})_CM\)\.dat$";
|
private static string _noIntroPattern = @"^(.*?) \((\d{8}-\d{6})_CM\)\.dat$";
|
||||||
@@ -163,6 +164,11 @@ namespace SabreTools
|
|||||||
fileinfo = Regex.Match(filename, _defaultPattern).Groups;
|
fileinfo = Regex.Match(filename, _defaultPattern).Groups;
|
||||||
type = DatType.Custom;
|
type = DatType.Custom;
|
||||||
}
|
}
|
||||||
|
else if (Regex.IsMatch(filename, _defaultSpecialPattern))
|
||||||
|
{
|
||||||
|
fileinfo = Regex.Match(filename, _defaultSpecialPattern).Groups;
|
||||||
|
type = DatType.Custom;
|
||||||
|
}
|
||||||
else if (Regex.IsMatch(filename, _mamePattern))
|
else if (Regex.IsMatch(filename, _mamePattern))
|
||||||
{
|
{
|
||||||
fileinfo = Regex.Match(filename, _mamePattern).Groups;
|
fileinfo = Regex.Match(filename, _mamePattern).Groups;
|
||||||
|
|||||||
Reference in New Issue
Block a user