50
社区成员




一个方形的UI,在gts3上
75:为了避开方形屏幕上的title
22.5:为了剧中显示
const back = hmUI.createWidget(hmUI.widget.IMG)
back.setProperty(hmUI.prop.MORE, {
x: 22.5,
y: 75,
w: 345,
h: 345,
src:'image/logo.png'
})
一个方形的UI,在gtr3上
const back = hmUI.createWidget(hmUI.widget.IMG)
back.setProperty(hmUI.prop.MORE, {
x: 54.5,
y: 54.5,
w: 345,
h: 345,
src:'image/logo.png'
})
最终结果
一个圆型UI
//gts3
var arcProgress = hmUI.createWidget(hmUI.widget.ARC_PROGRESS)
arcProgress.setProperty(hmUI.prop.MORE, {
center_x: 195,
center_y: 256,
radius: 171,
start_angle: 0,
end_angle: 360,
color: 0xc08eaf,
line_width: 45,
level: progress
})
//gts3
//gtr3
var arcProgress = hmUI.createWidget(hmUI.widget.ARC_PROGRESS)
arcProgress.setProperty(hmUI.prop.MORE, {
center_x: 227,
center_y: 227,
radius: 200,
start_angle: 0,
end_angle: 360,
color: 0xc08eaf,
line_width: 50,
level: progress
})
//gtr3
具体效果:
以供参考