summaryrefslogtreecommitdiff
path: root/platform/windows/os_windows.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'platform/windows/os_windows.cpp')
-rw-r--r--platform/windows/os_windows.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp
index 7f86f3bb98..a12cd67403 100644
--- a/platform/windows/os_windows.cpp
+++ b/platform/windows/os_windows.cpp
@@ -1835,7 +1835,11 @@ String OS_Windows::get_data_dir() const {
if (has_environment("APPDATA")) {
- return (OS::get_singleton()->get_environment("APPDATA")+"\\"+an).replace("\\","/"); // windows path to unix path to be consistent with get_resource_path
+ bool use_godot = Globals::get_singleton()->get("application/use_shared_user_dir");
+ if (use_godot)
+ return (OS::get_singleton()->get_environment("APPDATA")+"/"+an).replace("\\","/");
+ else
+ return (OS::get_singleton()->get_environment("APPDATA")+"/Godot/app_userdata/"+an).replace("\\","/");
}
}