mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Fix import and generation by fixing how game names and file names are processed and stored.
This commit is contained in:
@@ -514,14 +514,13 @@ namespace DATabase
|
|||||||
|
|
||||||
private bool AddRomHelper(string machinename, string romtype, long gameid, string name, string date, int size, string crc, string md5, string sha1)
|
private bool AddRomHelper(string machinename, string romtype, long gameid, string name, string date, int size, string crc, string md5, string sha1)
|
||||||
{
|
{
|
||||||
|
// WOD origninally stripped out any subdirs from the imported files, we do the same
|
||||||
|
name = Path.GetFileName(name);
|
||||||
|
|
||||||
// Run the name through the filters to make sure that it's correct
|
// Run the name through the filters to make sure that it's correct
|
||||||
name = Style.NormalizeChars(name);
|
name = Style.NormalizeChars(name);
|
||||||
name = Style.RussianToLatin(name);
|
name = Style.RussianToLatin(name);
|
||||||
name = Style.SearchPattern(name);
|
name = Regex.Replace(name, @"(.*) \.(.*)", "$1.$2");
|
||||||
|
|
||||||
// WOD origninally stripped out any subdirs from the imported files, we do the same
|
|
||||||
string[] fullname = name.Split('\\');
|
|
||||||
name = fullname[fullname.Length - 1];
|
|
||||||
|
|
||||||
if (romtype != "rom" && romtype != "disk")
|
if (romtype != "rom" && romtype != "disk")
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user