From fb0adaff9fe3bbb2b194f2ac73604d7ca0432cc8 Mon Sep 17 00:00:00 2001 From: RedworkDE <10944644+RedworkDE@users.noreply.github.com> Date: Sat, 4 Feb 2023 14:33:02 +0100 Subject: [PATCH] C#: Fix AppContext.BaseDirectory --- modules/mono/glue/GodotSharp/GodotPlugins/PluginLoadContext.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/mono/glue/GodotSharp/GodotPlugins/PluginLoadContext.cs b/modules/mono/glue/GodotSharp/GodotPlugins/PluginLoadContext.cs index 02d0226e903..93baf4e51c6 100644 --- a/modules/mono/glue/GodotSharp/GodotPlugins/PluginLoadContext.cs +++ b/modules/mono/glue/GodotSharp/GodotPlugins/PluginLoadContext.cs @@ -30,7 +30,7 @@ namespace GodotPlugins if (baseDirectory != null) { if (!Path.EndsInDirectorySeparator(baseDirectory)) - baseDirectory += Path.PathSeparator; + baseDirectory += Path.DirectorySeparatorChar; // This SetData call effectively sets AppContext.BaseDirectory // See https://github.com/dotnet/runtime/blob/v6.0.0/src/libraries/System.Private.CoreLib/src/System/AppContext.cs#L21-L25 AppDomain.CurrentDomain.SetData("APP_CONTEXT_BASE_DIRECTORY", baseDirectory);