Legacy Documentation: Version 2018.2 (Go to current version)
LanguageEnglish
  • C#

AssetDatabase.LoadMainAssetAtPath

public static Object LoadMainAssetAtPath(string assetPath);

Parameters

assetPathFilesystem path of the asset to load.

Description

Returns the main asset object at assetPath.

All paths are relative to the project folder, for example: "Assets/MyTextures/hello.png".

See Also: AssetDatabase.LoadAssetAtPath, AssetDatabase.LoadAllAssetsAtPath, AssetDatabase.LoadAllAssetRepresentationsAtPath.

Did you find this page useful? Please give it a rating: