Commit 5cb4b3b0 authored by wildfirecode's avatar wildfirecode

1

parent 73d3c22f
...@@ -251,7 +251,7 @@ ...@@ -251,7 +251,7 @@
"bindingDataTestObj": [ "bindingDataTestObj": [
{ {
"key": "data.url", "key": "data.url",
"value": "turnprize_icon2_png" "value": ""
} }
] ]
}, },
......
...@@ -2,10 +2,10 @@ ...@@ -2,10 +2,10 @@
<e:Skin class="BackSkin" width="750" height="1206" xmlns:e="http://ns.egret.com/eui" xmlns:w="http://ns.egret.com/wing"> <e:Skin class="BackSkin" width="750" height="1206" xmlns:e="http://ns.egret.com/eui" xmlns:w="http://ns.egret.com/wing">
<w:Config id="16e0235c541"/> <w:Config id="16e0235c541"/>
<e:Image source="backbg_png" scale9Grid="93,550,564,42" y="-107" horizontalCenter="0"/> <e:Image source="backbg_png" scale9Grid="93,550,564,42" y="-107" horizontalCenter="0"/>
<e:Image source="commom_prop_bg_png" y="456.76" horizontalCenter="0"/> <e:Image id="bg" source="commom_prop_bg_png" y="456.76" horizontalCenter="0"/>
<e:Image id="img" source="{data.url}" y="503.76" x="321" visible="false"/> <e:Image id="img" source="{data.url}" y="503.76" horizontalCenter="0"/>
<e:Image id="money" source="signprize元宝_png" y="368.2" horizontalCenter="0" scaleX="0.8" scaleY="0.8" visible="false"/>
<e:Image id="blood" y="522.8" horizontalCenter="-33.5" source="common_blood_png" locked="true" visible="false"/> <e:Image id="blood" y="522.8" horizontalCenter="-33.5" source="common_blood_png" locked="true" visible="false"/>
<e:Image id="money" y="543" horizontalCenter="-33.5" scaleX="0.8" scaleY="0.8" source="common_yuanbao_png" visible="false"/>
<e:Image id="propImg" source="{data.url}" y="507.76" x="283" visible="false"/> <e:Image id="propImg" source="{data.url}" y="507.76" x="283" visible="false"/>
<e:Label id="propnums" text="X8" size="50" horizontalCenter="58" verticalCenter="-29" verticalAlign="middle" textAlign="center" textColor="0xc17343" fontFamily="FZY3JW" x="510.38" y="534.4" bold="true" visible="false"/> <e:Label id="propnums" text="X8" size="50" horizontalCenter="58" verticalCenter="-29" verticalAlign="middle" textAlign="center" textColor="0xc17343" fontFamily="FZY3JW" x="510.38" y="534.4" bold="true" visible="false"/>
<e:Button id="closeBtn" label="" x="605" y="305"> <e:Button id="closeBtn" label="" x="605" y="305">
......
...@@ -52,6 +52,7 @@ export default class BackPanel extends Panel { ...@@ -52,6 +52,7 @@ export default class BackPanel extends Panel {
this['propnums'].text = 'x' + realValue; this['propnums'].text = 'x' + realValue;
break; break;
default: default:
this['bg'].visible = false;
this['img'].visible = true; this['img'].visible = true;
this.data.url = img; this.data.url = img;
break; break;
......
...@@ -85,11 +85,14 @@ export enum SoundType { ...@@ -85,11 +85,14 @@ export enum SoundType {
bonusTime = 'haha', bonusTime = 'haha',
} }
export const playSound = (type: SoundType) => { export const playSound = async (type: SoundType) => {
if (!soundOn) return; if (!soundOn) return;
const sound: egret.Sound = RES.getRes(type + "_mp3"); const sound: egret.Sound = RES.getRes(type + "_mp3");
if (sound) if (sound) {
sound.play(0, 1); sound.play(0, 1);
else }
RES.getResAsync(type + "_mp3") else {
const sound = await RES.getResAsync(type + "_mp3");
sound.play(0, 1);
}
} }
\ No newline at end of file
...@@ -2,17 +2,18 @@ ...@@ -2,17 +2,18 @@
"code":"0000000000", "code":"0000000000",
"data":{ "data":{
"appItemId":2322, "appItemId":2322,
"categoryType":3, "categoryType":5,
"coinType":1, "coinType":1,
"img":"1", "img":"http://yun.duiba.com.cn/db_games/activity/game/guideImage/guide2.png",
"maxValue":2, "maxValue":2,
"minValue":1, "minValue":1,
"name":"测试商品", "name":"测试商品",
"num":3, "num":3,
"propType":2, "propType":3,
"rate":"概率", "rate":"概率",
"title":"商品信息", "title":"商品信息",
"value":"虚拟商品标识符" "value":"虚拟商品标识符",
"realValue":11
}, },
"desc":"OK", "desc":"OK",
"success":true, "success":true,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment