Skip to content

Commit

Permalink
use new ContentPath constant
Browse files Browse the repository at this point in the history
  • Loading branch information
Pathoschild committed May 24, 2022
1 parent f8b2448 commit 19d9ada
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions PyTK/PyUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -130,20 +130,12 @@ internal static List<GameLocation> adjustInboundWarps(GameLocation location, Gam

public static string getContentFolder()
{
string folder = Path.Combine(Constants.ExecutionPath, Game1.content.RootDirectory);
DirectoryInfo directoryInfo = new DirectoryInfo(folder);
string folder = Constants.ContentPath;

if (directoryInfo.Exists)
if (Directory.Exists(folder))
return folder;

folder = folder.Replace("MacOS", "Resources").Replace("smapi-internal/","");

directoryInfo = new DirectoryInfo(folder);
if (directoryInfo.Exists)
return folder;
else
Monitor.Log("DebugF:" + folder);

Monitor.Log("DebugF:" + folder);
return @"failed";
}

Expand Down

0 comments on commit 19d9ada

Please sign in to comment.