[F] Set ForceAsSserver to default ON (#92)

* Set ForceAsSserver to default ON

* work as origin

---------

Co-authored-by: Clansty <i@gao4.pw>
This commit is contained in:
Menci
2024-11-30 14:43:25 +08:00
committed by GitHub
parent d5a9c98ff9
commit 6225390b7f
2 changed files with 7 additions and 2 deletions

View File

@@ -125,7 +125,10 @@ public class ConfigMigration_V1_0_V2_0 : IConfigMigration
{
dst.SetValue("GameSystem.RemoveEncryption.Disabled", true); // Enabled by default in V2
}
MapBooleanTrueToSectionEnable(src, dst, "Fix.ForceAsServer", "GameSettings.ForceAsServer");
if (!src.GetValueOrDefault<bool>("Fix.ForceAsServer", true))
{
dst.SetValue("GameSettings.ForceAsServer.Disabled", true); // Enabled by default in V2
}
if (src.GetValueOrDefault<bool>("Fix.ForceFreePlay"))
{
dst.SetValue("GameSettings.CreditConfig.IsFreePlay", true);
@@ -297,6 +300,7 @@ public class ConfigMigration_V1_0_V2_0 : IConfigMigration
// Default enabled in V2
dst.EnsureDictionary("GameSystem.RemoveEncryption");
dst.EnsureDictionary("GameSettings.ForceAsServer");
return dst;
}