FPaths 中 Dir 函数的对应路径

FPaths 提供了很多 EngineDir 等之类的函数,我在 unlua 里导出了这些符号:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
print(fmt("EngineDir: {}",UE4.FPaths.EngineDir()))
print(fmt("EngineUserDir: {}",UE4.FPaths.EngineUserDir()))
print(fmt("EngineContentDir: {}",UE4.FPaths.EngineContentDir()))
print(fmt("EngineConfigDir: {}",UE4.FPaths.EngineConfigDir()))
print(fmt("EngineSavedDir: {}",UE4.FPaths.EngineSavedDir()))
print(fmt("EnginePluginsDir: {}",UE4.FPaths.EnginePluginsDir()))
print(fmt("RootDir: {}",UE4.FPaths.RootDir()))
print(fmt("ProjectDir: {}",UE4.FPaths.ProjectDir()))
print(fmt("ProjectUserDir: {}",UE4.FPaths.ProjectUserDir()))
print(fmt("ProjectContentDir: {}",UE4.FPaths.ProjectContentDir()))
print(fmt("ProjectConfigDir: {}",UE4.FPaths.ProjectConfigDir()))
print(fmt("ProjectSavedDir: {}",UE4.FPaths.ProjectSavedDir()))
print(fmt("ProjectIntermediateDir: {}",UE4.FPaths.ProjectIntermediateDir()))
print(fmt("ProjectPluginsDir: {}",UE4.FPaths.ProjectPluginsDir()))
print(fmt("ProjectLogDir: {}",UE4.FPaths.ProjectLogDir()))

他们对应的具体路径为:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
EngineDir: ../../../Engine/
EngineUserDir: : /Users/imzlp/AppData/Local/UnrealEngine/4.22/
EngineContentDir: ../../../Engine/Content/
EngineConfigDir: ../../../Engine/Config/
EngineSavedDir: : /Users/imzlp/AppData/Local/UnrealEngine/4.22/Saved/
EnginePluginsDir: ../../../Engine/Plugins/
RootDir: : /Program Files/Epic Games/UE_4.22/
ProjectDir: ../../../../../../Users/imzlp/Documents/UnrealProjectSSD/GWorldClient/
ProjectUserDir: ../../../../../../Users/imzlp/Documents/UnrealProjectSSD/GWorldClient/
ProjectContentDir: ../../../../../../Users/imzlp/Documents/UnrealProjectSSD/GWorldClient/Content/
ProjectConfigDir: ../../../../../../Users/imzlp/Documents/UnrealProjectSSD/GWorldClient/Config/
ProjectSavedDir: ../../../../../../Users/imzlp/Documents/UnrealProjectSSD/GWorldClient/Saved/
ProjectIntermediateDir: ../../../../../../Users/imzlp/Documents/UnrealProjectSSD/GWorldClient/Intermediate/
ProjectPluginsDir: ../../../../../../Users/imzlp/Documents/UnrealProjectSSD/GWorldClient/Plugins/
ProjectLogDir: ../../../../../../Users/imzlp/Documents/UnrealProjectSSD/GWorldClient/Saved/Logs/

这些相对路径都是 相对于引擎的 exe的路径的: