最美情侣中文字幕电影,在线麻豆精品传媒,在线网站高清黄,久久黄色视频

歡迎光臨散文網(wǎng) 會(huì)員登陸 & 注冊(cè)

【易次元2.0代碼參考】點(diǎn)擊式/隨機(jī)封面

2023-02-17 16:41 作者:L-折骨  | 我要投稿

//看清楚兩個(gè)不一樣的

//用到的變量(單張封面不需要用到這個(gè)變量)

var 隨機(jī)封面=0;


//綁定的事件(三種方式綁定事件是一樣的)

async function SJ_jinru() {

await ac.replaceUI({name: 'UI_jindu',uiId: '-gr_sad6',});

}


//單張封面

await ac.createImage({name: 'DT_fengmian',index: 1,inlayer: 'window',resId: '$50016217',pos: {x: 640,y: 360,},anchor: {x: 50,y: 50,},opacity: 100,visible: true,verticalFlip: false,horizontalFlip: false,dynaScale: 'cover',});

ac.addEventListener({type: ac.EVENT_TYPES.onTouchBegan,listener: SJ_jinru,target: 'DT_fengmian',});


//隨機(jī)封面多少只需要增加隨機(jī)范圍和條件數(shù)量即可

//隨機(jī)封面方式一

隨機(jī)封面= await ac.random({ min:1, max:5});

if (ac.var.隨機(jī)數(shù) === 1) {

await ac.createImage({name: 'DT_fengmian',index: 1,inlayer: 'window',resId: '$50016217',pos: {x: 640,y: 360,},anchor: {x: 50,y: 50,},opacity: 100,visible: true,verticalFlip: false,horizontalFlip: false,dynaScale: 'cover',});

} else if (ac.var.隨機(jī)數(shù) === 2) {

await ac.createImage({name: 'DT_fengmian',index: 1,inlayer: 'window',resId: '$50016217',pos: {x: 640,y: 360,},anchor: {x: 50,y: 50,},opacity: 100,visible: true,verticalFlip: false,horizontalFlip: false,dynaScale: 'cover',});

} else if (ac.var.隨機(jī)數(shù) === 3) {

await ac.createImage({name: 'DT_fengmian',index: 1,inlayer: 'window',resId: '$50016217',pos: {x: 640,y: 360,},anchor: {x: 50,y: 50,},opacity: 100,visible: true,verticalFlip: false,horizontalFlip: false,dynaScale: 'cover',});

} else if (ac.var.隨機(jī)數(shù) === 4) {

await ac.createImage({name: 'DT_fengmian',index: 1,inlayer: 'window',resId: '$50016217',pos: {x: 640,y: 360,},anchor: {x: 50,y: 50,},opacity: 100,visible: true,verticalFlip: false,horizontalFlip: false,dynaScale: 'cover',});

} else if (ac.var.隨機(jī)數(shù) === 5) {

await ac.createImage({name: 'DT_fengmian',index: 1,inlayer: 'window',resId: '$50016217',pos: {x: 640,y: 360,},anchor: {x: 50,y: 50,},opacity: 100,visible: true,verticalFlip: false,horizontalFlip: false,dynaScale: 'cover',});

}

ac.addEventListener({type: ac.EVENT_TYPES.onTouchBegan,listener: SJ_jinru,target: 'DT_fengmian',});


//隨機(jī)封面方式二

隨機(jī)封面= await ac.random({ min:1, max:5});


await ac.createPicDisplay({name: 'DT_fengmian',index: 1,inlayer: 'window',picGroup: [

{resId: '$50016217',condition: () => ac.var.隨機(jī)數(shù) === 1,clickFunc: SJ_jinru,},?

{resId: '$50016217',condition: () => ac.var.隨機(jī)數(shù) === 2,clickFunc: SJ_jinru,},?

{resId: '$50016217',condition: () => ac.var.隨機(jī)數(shù) === 3,clickFunc: SJ_jinru,},?

{resId: '$50016217',condition: () => ac.var.隨機(jī)數(shù) === 4,clickFunc: SJ_jinru,},?

{resId: '$50016217',condition: () => ac.var.隨機(jī)數(shù) === 5,clickFunc: SJ_jinru,},?

],pos: {x: 640,y: 360,},size: {width: 1920,height: 886,},anchor: {x: 50,y: 50,},opacity: 100,visible: true,verticalFlip: false,horizontalFlip: false,dynaScale: 'cover',});


【易次元2.0代碼參考】點(diǎn)擊式/隨機(jī)封面的評(píng)論 (共 條)

分享到微博請(qǐng)遵守國(guó)家法律
鄯善县| 黔西县| 正宁县| 旌德县| 武川县| 团风县| 石泉县| 舒兰市| 六枝特区| 徐水县| 建阳市| 陆良县| 壶关县| 金寨县| 聊城市| 固始县| 郧西县| 平乐县| 龙川县| 炉霍县| 革吉县| 金昌市| 岗巴县| 商南县| 庄浪县| 福贡县| 麻江县| 邻水| 岳阳市| 峨眉山市| 若羌县| 荔波县| 施甸县| 长顺县| 丽江市| 永平县| 蒙自县| 平昌县| 政和县| 游戏| 东兴市|