From e84a8b71d8e4811c32e025856a1b6ed244f10156 Mon Sep 17 00:00:00 2001
From: stephenlucerne <48700284+stephenlucerne@users.noreply.github.com>
Date: Wed, 6 Jul 2022 14:54:59 +1000
Subject: [PATCH] changed the global root directory to be the same across PC
and mobile
---
.../Android/ModIO.Implementation.Platform/AndroidDataService.cs | 2 +-
.../LINUX/ModIO.Implementation.Platform/LinuxDataService.cs | 2 +-
Platform/OSX/ModIO.Implementation.Platform/OsxDataService.cs | 2 +-
.../Windows/ModIO.Implementation.Platform/WindowsDataService.cs | 2 +-
Platform/iOS/ModIO.Implementation.Platform/iOSDataService.cs | 2 +-
5 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/Platform/Android/ModIO.Implementation.Platform/AndroidDataService.cs b/Platform/Android/ModIO.Implementation.Platform/AndroidDataService.cs
index d9e0360..c2a8b81 100644
--- a/Platform/Android/ModIO.Implementation.Platform/AndroidDataService.cs
+++ b/Platform/Android/ModIO.Implementation.Platform/AndroidDataService.cs
@@ -13,7 +13,7 @@ internal class AndroidDataService : IUserDataService, IPersistentDataService, IT
{
/// Root directory for all data services.
public readonly static string GlobalRootDirectory =
- $@"{System.IO.Directory.GetCurrentDirectory()}/mod.io";
+ $@"{Application.persistentDataPath}/mod.io";
#region Data
diff --git a/Platform/LINUX/ModIO.Implementation.Platform/LinuxDataService.cs b/Platform/LINUX/ModIO.Implementation.Platform/LinuxDataService.cs
index e15e619..94d6008 100644
--- a/Platform/LINUX/ModIO.Implementation.Platform/LinuxDataService.cs
+++ b/Platform/LINUX/ModIO.Implementation.Platform/LinuxDataService.cs
@@ -14,7 +14,7 @@ internal class LinuxDataService : IUserDataService, IPersistentDataService, ITem
{
/// Root directory for all data services.
public readonly static string GlobalRootDirectory =
- $@"{System.IO.Directory.GetCurrentDirectory()}/mod.io";
+ $@"{Application.persistentDataPath}/mod.io";
#region Data
diff --git a/Platform/OSX/ModIO.Implementation.Platform/OsxDataService.cs b/Platform/OSX/ModIO.Implementation.Platform/OsxDataService.cs
index 8e61bb5..2996a0c 100644
--- a/Platform/OSX/ModIO.Implementation.Platform/OsxDataService.cs
+++ b/Platform/OSX/ModIO.Implementation.Platform/OsxDataService.cs
@@ -14,7 +14,7 @@ internal class OsxDataService : IUserDataService, IPersistentDataService, ITempD
{
/// Root directory for all data services.
public readonly static string GlobalRootDirectory =
- $@"{System.IO.Directory.GetCurrentDirectory()}/mod.io";
+ $@"{Application.persistentDataPath}/mod.io";
#region Data
diff --git a/Platform/Windows/ModIO.Implementation.Platform/WindowsDataService.cs b/Platform/Windows/ModIO.Implementation.Platform/WindowsDataService.cs
index c750f03..b33877d 100644
--- a/Platform/Windows/ModIO.Implementation.Platform/WindowsDataService.cs
+++ b/Platform/Windows/ModIO.Implementation.Platform/WindowsDataService.cs
@@ -13,7 +13,7 @@ internal class WindowsDataService : IUserDataService, IPersistentDataService, IT
{
/// Root directory for all data services.
public readonly static string GlobalRootDirectory =
- $@"{System.IO.Directory.GetCurrentDirectory()}/mod.io";
+ $@"{Application.persistentDataPath}/mod.io";
#region Data
diff --git a/Platform/iOS/ModIO.Implementation.Platform/iOSDataService.cs b/Platform/iOS/ModIO.Implementation.Platform/iOSDataService.cs
index c4ee825..37e26ed 100644
--- a/Platform/iOS/ModIO.Implementation.Platform/iOSDataService.cs
+++ b/Platform/iOS/ModIO.Implementation.Platform/iOSDataService.cs
@@ -13,7 +13,7 @@ internal class iOSDataService : IUserDataService, IPersistentDataService, ITempD
{
/// Root directory for all data services.
public readonly static string GlobalRootDirectory =
- $@"{System.IO.Directory.GetCurrentDirectory()}/mod.io";
+ $@"{Application.persistentDataPath}/mod.io";
#region Data