通过路径获取控件

界面
Both Server and Client
Both Mobile and PC

从自定义UI中使用路径获取一个UI控件

声明

func GetWidgetByPath(owner entity<Player>, target entity<CustomUI>, path string) entity<UIWidget>
go

参数

输入

名称 类型 描述
所属者 Player UI所属的玩家实体
目标 CustomHud 自定义UI
路径 String 控件路径

返回

类型 描述
HudWidget UI控件实体