Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ CollapseParentDirectory()

static int ReLogic.Content.AssetPathHelper.CollapseParentDirectory ( ref string path,
int position,
int removeLength )
inlinestaticprivate

Definition at line 48 of file AssetPathHelper.cs.

49 {
50 int num = path.LastIndexOf("\\", position - 1, StringComparison.Ordinal) + 1;
51 path = path.Remove(num, position - num + removeLength);
52 return Math.Max(num - 1, 1);
53 }
static byte Max(byte val1, byte val2)
Definition Math.cs:738

References System.Math.Max().

Referenced by ReLogic.Content.AssetPathHelper.CleanPath().