是一个编辑器类,编辑器类在UnityEditor命名空间下。所以当使用C#脚本时,需要在脚本前面加上 "using UnityEditor"
引用。
这样你可以在导入的设置中重载默认值或修改导入的数据,如纹理或网格。
assetPath
The path name of the asset being imported.
被导入的资源的路径名
assetImporter
Reference to the asset importer
引用资源导入器
Functions
函数
LogWarning
Logs an import warning to the console.
记录一个导入警告到控制台
LogError
Logs an import error message to the console.
记录一个导入错误消息到控制台
GetPostprocessOrder
Override the order in which importers are processed.
重载导入器执行的次序
Messages Sent
发送消息
OnPreprocessTexture
Add
this
function
in
a
subclass
to
get
a
notification
just
before
the
texture
importer
is run.
在子类中重载这个函数以便在纹理导入器运行之前获取通知
OnPostprocessTexture
Add this function in a subclass to get a notification when a texture has completed
importing just before the texture is saved to disk.
在子类中加入这个函数,以便在纹理载入存入磁盘之前获得一个通知。
OnPreprocessModel
Add
this
function
in
a
subclass
to
get
a
notification
just
before
a
model
(.fbx,
.mb
file etc.) is being imported.
在子类中加入这个函数,以便在模型载入之前获得一个通知。
OnPostprocessModel
Add this function in a subclass to get a notification when a model has completed
importing
在子类中加入这个函数,以便在模型载入之后获得一个通知。
OnPostprocessGameObjectW...
Gets called for each GameObject that had at least one userpropery attached to it
in the imported file.
在导入文件中,为每个至少附加了一个用户属性的游戏物体调用。
[
狗刨学习网
]
OnAssignMaterialModel
Feeds a source material
获取一个源材质
OnPostprocessAudio
Add
this
function
in
a
subclass
to
get
a
notification
when
an
audio
clip
has
completed
importing.
在子类中加入这个函数,以便在一个声音剪辑载入后获得一个通知。
OnPreprocessAudio
Add this function in a subclass to get a notification just before an audio clip is
being imported.
在子类中加入这个函数,以便在一个声音剪辑载入之前获得一个通知。
OnPostprocessAllAssets
This
is
called
after
importing
of
any
number
of
assets
is
complete
(when
the
Assets
progress bar has reached the end).
在一些资源被导入后调用
(
当资源进度条到达末端