Put snes profile setting into savestates since savestates are incompatible among profiles

This commit is contained in:
adelikat 2014-05-04 13:43:29 +00:00
parent e99b370654
commit 6b2ea2e7a6
1 changed files with 8 additions and 0 deletions

View File

@ -4,6 +4,7 @@ using System.IO;
using System.Reflection;
using BizHawk.Emulation.Common;
using BizHawk.Emulation.Cores.Nintendo.SNES;
namespace BizHawk.Client.Common
{
@ -264,11 +265,18 @@ namespace BizHawk.Client.Common
{
var name = FilesystemSafeName(game);
// Neshawk and Quicknes have incompatible savestates, store the name to keep them separate
if (Global.Emulator.SystemId == "NES")
{
name += "." + Global.Emulator.Attributes().CoreName;
}
// Bsnes profiles have incompatible savestates so save the profile name
if (Global.Emulator is LibsnesCore)
{
name += "." + ((LibsnesCore.SnesSyncSettings)Global.Emulator.GetSyncSettings()).Profile;
}
if (Global.MovieSession.Movie.IsActive)
{
name += "." + Path.GetFileNameWithoutExtension(Global.MovieSession.Movie.Filename);