Legacy Documentation: Version 5.2
LanguageEnglish
  • C#
  • JS

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

AssetDatabase.ImportAsset

Switch to Manual
public static void ImportAsset(string path, ImportAssetOptions options = ImportAssetOptions.Default);
public static void ImportAsset(string path, ImportAssetOptions options = ImportAssetOptions.Default);

Parameters

Description

Import asset at path.

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

See Also: ImportAssetOptions.