change references of Global.Game.Name to Global.Game.FileSystemSafeName for situations that use it to build paths
This commit is contained in:
parent
c5b2fa8431
commit
c6a5c7e9b6
|
@ -818,11 +818,10 @@ namespace BizHawk.MultiClient
|
|||
Global.Game = game;
|
||||
SyncControls();
|
||||
|
||||
//if (game.System == "NES")
|
||||
//{
|
||||
// Global.Game.Name = (Global.Emulator as NES).GameName;
|
||||
//}
|
||||
//adelikat: Disabling this because it causes invalid characters (such as :) in file paths, why do we want these lines
|
||||
if (game.System == "NES")
|
||||
{
|
||||
Global.Game.Name = (Global.Emulator as NES).GameName;
|
||||
}
|
||||
|
||||
Text = DisplayNameForSystem(game.System) + " - " + game.Name;
|
||||
ResetRewindBuffer();
|
||||
|
|
|
@ -66,7 +66,7 @@ namespace BizHawk.MultiClient
|
|||
SaveFileDialog sfd = new SaveFileDialog();
|
||||
sfd.InitialDirectory = PathManager.MakeAbsolutePath(Global.Config.MoviesPath, "");
|
||||
sfd.DefaultExt = ".tas";
|
||||
sfd.FileName = Global.Game.Name;
|
||||
sfd.FileName = Global.Game.FilesystemSafeName;
|
||||
sfd.Filter = "Movie files (*.tas)|*.TAS";
|
||||
|
||||
Global.Sound.StopSound();
|
||||
|
|
|
@ -75,7 +75,7 @@ namespace BizHawk.MultiClient
|
|||
MakeBackup = false;
|
||||
}
|
||||
Log.Clear();
|
||||
Header = new MovieHeader(MainForm.EMUVERSION, MovieHeader.MovieVersion, Global.Emulator.SystemId, Global.Game.Name, "", 0);
|
||||
Header = new MovieHeader(MainForm.EMUVERSION, MovieHeader.MovieVersion, Global.Emulator.SystemId, Global.Game.FilesystemSafeName, "", 0);
|
||||
}
|
||||
|
||||
public void StartPlayback()
|
||||
|
|
|
@ -380,7 +380,7 @@ namespace BizHawk.MultiClient
|
|||
if (currentCheatFile.Length > 0)
|
||||
sfd.FileName = Path.GetFileNameWithoutExtension(currentCheatFile);
|
||||
else if (!(Global.Emulator is NullEmulator))
|
||||
sfd.FileName = Global.Game.Name;
|
||||
sfd.FileName = Global.Game.FilesystemSafeName;
|
||||
sfd.InitialDirectory = GetCheatsPath();
|
||||
sfd.Filter = "Cheat Files (*.cht)|*.cht|All Files|*.*";
|
||||
sfd.RestoreDirectory = true;
|
||||
|
|
|
@ -1275,7 +1275,7 @@ namespace BizHawk.MultiClient
|
|||
}
|
||||
else if (!(Global.Emulator is NullEmulator))
|
||||
{
|
||||
sfd.FileName = Global.Game.Name;
|
||||
sfd.FileName = Global.Game.FilesystemSafeName;
|
||||
sfd.InitialDirectory = PathManager.MakeAbsolutePath(Global.Config.WatchPath, "");
|
||||
}
|
||||
else
|
||||
|
|
|
@ -645,7 +645,7 @@ namespace BizHawk.MultiClient
|
|||
}
|
||||
else if (!(Global.Emulator is NullEmulator))
|
||||
{
|
||||
sfd.FileName = Global.Game.Name;
|
||||
sfd.FileName = Global.Game.FilesystemSafeName;
|
||||
sfd.InitialDirectory = PathManager.MakeAbsolutePath(Global.Config.WatchPath, "");
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue