主题
API变更说明
版本号
版本 20260929
发布日期
2026-09-29
概述
- 方法新增: 18
- 合计: 18
新增
LifeEntity.set_mesh_texture
名称:设置子模型贴图
方法:LifeEntity.set_mesh_texture(_model_id, _texture_key, _material_index)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _model_id | Int | 模型编号 |
| _texture_key | ImageKey | 贴图编号 |
| _material_index | Int | 子材质索引 |
Obstacle.get_skin_id_list
名称:获取组件皮肤ID列表
方法:Obstacle.get_skin_id_list()
参数:
无
返回:
ListSkinId 皮肤ID列表
LifeEntity.add_mesh_model
名称:添加子模型
方法:LifeEntity.add_mesh_model(_model_id)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _model_id | Int | 模型编号 |
GameAPI.obstacle_prefab_get_skin_id
名称:获取组件预设的皮肤ID
方法:GameAPI.obstacle_prefab_get_skin_id(_key)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _key | ObstacleKey | 组件编号 |
返回:
SkinId 皮肤ID
Obstacle.get_skin_id
名称:获取组件皮肤ID
方法:Obstacle.get_skin_id()
参数:
无
返回:
SkinId 皮肤ID
Obstacle.set_paint_area_color
名称:设置组件染色区域颜色
方法:Obstacle.set_paint_area_color(_paint_area, _color)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _paint_area | PaintArea | 染色区域 |
| _color | Color | 颜色 |
LifeEntity.remove_mesh_model
名称:移除子模型
方法:LifeEntity.remove_mesh_model(_model_id)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _model_id | Int | 模型编号 |
LifeEntity.set_mesh_paint_color
名称:设置子模型染色
方法:LifeEntity.set_mesh_paint_color(_model_id, _paint_area, _color, _material_index)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _model_id | Int | 模型编号 |
| _paint_area | PaintArea | 染色区域 |
| _color | Color | 颜色 |
| _material_index | Int | 子材质索引 |
Obstacle.set_skin_id
名称:设置组件皮肤
方法:Obstacle.set_skin_id(_skin_id)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _skin_id | SkinId | 皮肤ID |
GameAPI.obstacle_prefab_get_slot_skin_id
名称:获取组件预设槽位的皮肤ID
方法:GameAPI.obstacle_prefab_get_slot_skin_id(_key, _index)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _key | ObstacleKey | 组件编号 |
| _index | Int | 槽位索引 |
返回:
SkinId 皮肤ID
Obstacle.set_skin_slot_mode_enabled
名称:设置组件皮肤槽位模式开关
方法:Obstacle.set_skin_slot_mode_enabled(_enable)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _enable | Bool | 是否开启槽位模式 |
LifeEntity.play_human_face_expression
名称:播放新人形面部表情
方法:LifeEntity.play_human_face_expression(_face_expression_key, _duration)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _face_expression_key | FaceExpressionKey | 表情 |
| _duration | Fixed | 持续时间 |
Obstacle.set_slot_skin_id
名称:设置组件指定槽位皮肤id
方法:Obstacle.set_slot_skin_id(_index, _skin_id)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _index | Int | 槽位索引 |
| _skin_id | SkinId | 皮肤ID |
LifeEntity.set_texture
名称:设置模型贴图
方法:LifeEntity.set_texture(_texture_key, _material_index)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _texture_key | ImageKey | 贴图编号 |
| _material_index | Int | 子材质索引 |
LifeEntity.set_paint_color
名称:设置模型染色
方法:LifeEntity.set_paint_color(_paint_area, _color, _material_index)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _paint_area | PaintArea | 染色区域 |
| _color | Color | 颜色 |
| _material_index | Int | 子材质索引 |
Obstacle.set_slot_paint_area_color
名称:设置组件指定槽位染色区域颜色
方法:Obstacle.set_slot_paint_area_color(_index, _paint_area, _color)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _index | Int | 槽位索引 |
| _paint_area | PaintArea | 染色区域 |
| _color | Color | 颜色 |
GameAPI.obstacle_prefab_get_skin_id_list
名称:获取组件预设的皮肤ID列表
方法:GameAPI.obstacle_prefab_get_skin_id_list(_key)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _key | ObstacleKey | 组件编号 |
返回:
ListSkinId 皮肤ID列表
Obstacle.get_slot_skin_id
名称:获取组件槽位皮肤ID
方法:Obstacle.get_slot_skin_id(_index)
参数:
| 参数 | 类型 | 说明 |
|---|---|---|
| _index | Int | 槽位索引 |
返回:
SkinId 皮肤ID
