Commit f8629686 authored by wjf's avatar wjf

Merge branch 'dev' of gitlab2.dui88.com:wanghongyuan/xiaoxiaole into dev

parents 3477e420 68d22009
......@@ -118,7 +118,11 @@
},
{
"key": "data.url",
"value": "turnprize_icon1_png"
"value": "common_prop3_png"
},
{
"key": "data.url2",
"value": "common_prop3_png"
}
]
},
......
......@@ -19,7 +19,7 @@
background-color: #000;
background-size: 100%;
background-position: top;
background-image: url("https://yun.duiba.com.cn/db_games/activity/game/1565600901/resource/assets/startScene/startscenebg.jpg");
background-image: url("https://yun.duiba.com.cn/db_games/activity/game/1573107320/resource/assets/startScene/startscenebg.jpg");
padding: 0;
border: 0;
margin: 0;
......@@ -60,6 +60,7 @@
<script src="libs/fileSave.js"></script>
<img id="pic" style="width:100%;position: absolute;z-index: 999;display: none;"/>
<script>
window['hbRainTime'] = 30;
window['plugs'] = [1, 2, 3]
// localStorage.clear();
window['isInvitePage'] = 0;
......
......@@ -195,6 +195,7 @@ export default class MainBase extends eui.UILayer {
// tslint:disable-next-line: cyclomatic-complexity
private async runGame() {
await this.loadResource();
RES.getResAsync('hbRule_bg_png');
RES.getResAsync('mapBg_mp3');
RES.getResAsync('sharefriend_jpg');
RES.getResAsync(`nums_png`);
......
......@@ -2,7 +2,7 @@ import getShowOffPic from "../../../src/getShowOffPic";
import { iswx } from "../../../src/iswx";
import { getlogItem } from "../../../src/Main";
import { addRankFriendList } from "../../../src/mapScene/RankFriendList";
import setGray from "../../../src/setGray";
import { showShare } from "../../../src/shareCtrl";
import { changeMapScene } from "../../../src/startScene/StartScene";
import wait from "../../new_tc/wait";
......@@ -13,10 +13,8 @@ export default class NoPrizePanel extends Panel {
_level;
start(data) {
super.start();
setGray(this['pica']);
setGray(this['picb']);
setGray(this['picc']);
this._level = parseInt(data.level + '');
this['lvTxt'].text = `关卡${this._level}`
this['shareBtn'].addEventListener(egret.TouchEvent.TOUCH_TAP, () => {
NetManager.ins.clickLog(getlogItem(16));
if (iswx()) {
......@@ -38,8 +36,7 @@ export default class NoPrizePanel extends Panel {
changeMapScene();
}, this);
addRankFriendList(84,735.52,this);
addRankFriendList(84,917.46,this);
}
showlog() {
......@@ -49,10 +46,6 @@ export default class NoPrizePanel extends Panel {
onTouchTap_closeBtn() {
super.onTouchTap_closeBtn();
changeMapScene();
// if (this._level + 1 <= 70)
// SceneCtrl.instance.change(ModuleTypes.START_SCENE, { level: this._level + 1 });
// else
// SceneCtrl.instance.change(ModuleTypes.START_SCENE);
}
protected get closeBtns(): eui.Button[] { return [this['closeBtn']] }
......@@ -79,7 +72,7 @@ export default class NoPrizePanel extends Panel {
await this.playAni3();
}
if (nums >= 1) {
this['light'].visible = true;
this['light'].visible = false;
egret.Tween.get(this['light']).set({ scaleX: 0, scaleY: 0, alpha: 0, }).to({ scaleX: 1, scaleY: 1, alpha: 1 }, 300).call(() => {
egret.Tween.get(this['light'], { loop: true }).to({ rotation: 360 }, 3000);
});
......@@ -88,7 +81,7 @@ export default class NoPrizePanel extends Panel {
async playAni1() {
return new Promise(r => {
egret.Tween.get(this['pic1']).set({ scaleX: 0, scaleY: 0 }).to({ scaleX: 1, scaleY: 1 }, 400, egret.Ease.getBackOut(1)).call(r)
egret.Tween.get(this['pic1']).set({ scaleX: 0, scaleY: 0 }).to({ scaleX: -1, scaleY: 1 }, 400, egret.Ease.getBackOut(1)).call(r)
})
}
async playAni2() {
......@@ -98,7 +91,7 @@ export default class NoPrizePanel extends Panel {
}
async playAni3() {
return new Promise(r => {
egret.Tween.get(this['pic3']).set({ scaleX: 0, scaleY: 0 }).to({ scaleX: -1, scaleY: 1 }, 400, egret.Ease.getBackOut(1)).call(r)
egret.Tween.get(this['pic3']).set({ scaleX: 0, scaleY: 0 }).to({ scaleX: 1, scaleY: 1 }, 400, egret.Ease.getBackOut(1)).call(r)
})
}
destroy() {
......
......@@ -2,7 +2,6 @@ import getShowOffPic from "../../../src/getShowOffPic";
import { iswx } from "../../../src/iswx";
import { getlogItem } from "../../../src/Main";
import { addRankFriendList } from "../../../src/mapScene/RankFriendList";
import setGray from "../../../src/setGray";
import { showShare } from "../../../src/shareCtrl";
import { changeMapScene } from "../../../src/startScene/StartScene";
import wait from "../../new_tc/wait";
......@@ -16,8 +15,11 @@ export default class PrizePanel extends Panel {
const { categoryType, img, num, propType,realValue } = option;// 2次数 3道具 4元宝 5实物 6优惠券 7虚拟商品
this['propnums'].text = 'x1';
if(num)
this['propnums2'].text = 'x1';
if(num){
this['propnums'].text = 'x' + num;
this['propnums2'].text = 'x' + num;
}
switch (categoryType) {
case 2:
this['blood'].visible = true;
......@@ -25,13 +27,14 @@ export default class PrizePanel extends Panel {
break;
case 3:
this['numsgroup'].visible = true;
this['img'].visible = true;
this.data.url = `turnprize_icon${propType}_png`;
this['img2'].visible = true;
this.data.url2 = `common_prop${propType}_png`;
break;
case 4:
this['numsgroup'].visible = true;
this['numsgroup'].visible = false;
this['propnums2'].visible = true;
this['money'].visible = true;
this['propnums'].text = 'x' + realValue;
this['propnums2'].text = realValue;
break;
default:
this['img'].visible = true;
......@@ -42,10 +45,8 @@ export default class PrizePanel extends Panel {
start(data) {
super.start();
setGray(this['pica']);
setGray(this['picb']);
setGray(this['picc']);
this._level = parseInt(data.level + '');
this['lvTxt'].text = `关卡${this._level}`
this.updateOption(data.option);
......@@ -70,7 +71,7 @@ export default class PrizePanel extends Panel {
this.setStar(hc_submitData.stars);
addRankFriendList(84,859,this);
addRankFriendList(84,889.74,this);
}
showlog() {
......@@ -100,7 +101,7 @@ export default class PrizePanel extends Panel {
await this.playAni3();
}
if (nums >= 1) {
this['light'].visible = true;
this['light'].visible = false;
egret.Tween.get(this['light']).set({ scaleX: 0, scaleY: 0, alpha: 0, }).to({ scaleX: 1, scaleY: 1, alpha: 1 }, 300).call(() => {
egret.Tween.get(this['light'], { loop: true }).to({ rotation: 360 }, 3000);
});
......@@ -110,7 +111,7 @@ export default class PrizePanel extends Panel {
async playAni1() {
return new Promise(r => {
egret.Tween.get(this['pic1']).set({ scaleX: 0, scaleY: 0 }).to({ scaleX: 1, scaleY: 1 }, 400, egret.Ease.getBackOut(1)).call(r)
egret.Tween.get(this['pic1']).set({ scaleX: 0, scaleY: 0 }).to({ scaleX: -1, scaleY: 1 }, 400, egret.Ease.getBackOut(1)).call(r)
})
}
async playAni2() {
......@@ -120,7 +121,7 @@ export default class PrizePanel extends Panel {
}
async playAni3() {
return new Promise(r => {
egret.Tween.get(this['pic3']).set({ scaleX: 0, scaleY: 0 }).to({ scaleX: -1, scaleY: 1 }, 400, egret.Ease.getBackOut(1)).call(r)
egret.Tween.get(this['pic3']).set({ scaleX: 0, scaleY: 0 }).to({ scaleX: 1, scaleY: 1 }, 400, egret.Ease.getBackOut(1)).call(r)
})
}
......@@ -132,11 +133,6 @@ export default class PrizePanel extends Panel {
onTouchTap_closeBtn(): any {
super.onTouchTap_closeBtn();
changeMapScene();
// if (this._level +1 <= 70)
// SceneCtrl.instance.change(ModuleTypes.START_SCENE, { level: this._level + 1 });
// else
// SceneCtrl.instance.change(ModuleTypes.START_SCENE);
// SceneCtrl.instance.change(ModuleTypes.MAP_SCENE, createData());
}
get picBigWidth() { return 510 };
......
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"hbcuttime","version":5,"files":["../assets/hbCutTime/hbCutTime_bg.png","../assets/hbCutTime/hbCutTime_btn_disable.png","../assets/hbCutTime/hbCutTime_btn_enable.png","../assets/hbCutTime/hbCutTime_cutLine_disable.png","../assets/hbCutTime/hbCutTime_cutLine_enable.png","../assets/hbCutTime/hbCutTime_rule_btn.png","../assets/hbCutTime/hbCutTime_btn_null.png"]}
\ No newline at end of file
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"hbcuttime","version":5,"files":["../assets/hbCutTime/hbCutTime_bg.png","../assets/hbCutTime/hbCutTime_btn_disable.png","../assets/hbCutTime/hbCutTime_btn_enable.png","../assets/hbCutTime/hbCutTime_cutLine_disable.png","../assets/hbCutTime/hbCutTime_cutLine_enable.png","../assets/hbCutTime/hbCutTime_rule_btn.png","../assets/hbCutTime/hbCutTime_btn_null.png","../assets/hbCutTime/hbCutTime_btn_soon.png"]}
\ No newline at end of file
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"map","version":5,"files":["../assets/map/宝箱.png","../assets/map/宝箱1.png","../assets/map/宝箱2.png","../assets/map/宝箱3.png","../assets/map/宝箱bg.png","../assets/map/宝箱btn.png","../assets/map/道具.png","../assets/map/关闭 拷贝.png","../assets/map/光 副本 4.png","../assets/map/设置.png","../assets/map/设置bg.png","../assets/map/声音.png","../assets/map/声音关闭.png","../assets/map/狮子.png","../assets/map/退出.png","../assets/map/问题.png","../assets/map/无星星.png","../assets/map/星星.png","../assets/map/星星bg.png","../assets/map/音乐.png","../assets/map/音乐关闭.png","../assets/map/有星星.png","../assets/map/有星星2.png","../assets/map/有星星3.png","../assets/map/元宝bg.png","../assets/map/ad_icon.png","../assets/map/animal1.png","../assets/map/avatar.png","../assets/map/friend_avatar.png","../assets/map/guideBox.png","../assets/map/guideLevel.png","../assets/map/guideLove.png","../assets/map/guideMoney.png","../assets/map/guideOver.png","../assets/map/icon.png","../assets/map/iconbg.png","../assets/map/icongray.png","../assets/map/invite_icon.png","../assets/map/invite_txtbg.png","../assets/map/lionMsgBg.png","../assets/map/map_signicon.png","../assets/map/map2+.png","../assets/map/map2+bg.png","../assets/map/map2红包大作战.png","../assets/map/map2热门引导.png","../assets/map/map2周一红包雨.png","../assets/map/map大转盘.png","../assets/map/map刮现金红包.png","../assets/map/map今日可领.png","../assets/map/map明日可领.png","../assets/map/maphot.png","../assets/map/msgTri.png","../assets/map/namebg.png","../assets/map/progress1.png","../assets/map/progress2.png","../assets/map/recordbtn.png","../assets/map/taskicon.png"]}
\ No newline at end of file
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"map","version":5,"files":["../assets/map/宝箱.png","../assets/map/宝箱1.png","../assets/map/宝箱2.png","../assets/map/宝箱3.png","../assets/map/宝箱bg.png","../assets/map/宝箱btn.png","../assets/map/道具.png","../assets/map/关闭 拷贝.png","../assets/map/光 副本 4.png","../assets/map/设置.png","../assets/map/设置bg.png","../assets/map/声音.png","../assets/map/声音关闭.png","../assets/map/狮子.png","../assets/map/退出.png","../assets/map/问题.png","../assets/map/无星星.png","../assets/map/星星.png","../assets/map/星星bg.png","../assets/map/音乐.png","../assets/map/音乐关闭.png","../assets/map/有星星.png","../assets/map/有星星2.png","../assets/map/有星星3.png","../assets/map/元宝bg.png","../assets/map/ad_icon.png","../assets/map/animal1.png","../assets/map/avatar.png","../assets/map/friend_avatar.png","../assets/map/guideBox.png","../assets/map/guideLevel.png","../assets/map/guideLove.png","../assets/map/guideMoney.png","../assets/map/guideOver.png","../assets/map/icon.png","../assets/map/iconbg.png","../assets/map/icongray.png","../assets/map/invite_icon.png","../assets/map/invite_txtbg.png","../assets/map/lionMsgBg.png","../assets/map/map_signicon.png","../assets/map/map2+.png","../assets/map/map2+bg.png","../assets/map/map2红包大作战.png","../assets/map/map2热门引导.png","../assets/map/map2周一红包雨.png","../assets/map/map大转盘.png","../assets/map/map刮现金红包.png","../assets/map/map今日可领.png","../assets/map/map明日可领.png","../assets/map/maphot.png","../assets/map/msgTri.png","../assets/map/namebg.png","../assets/map/progress1.png","../assets/map/progress2.png","../assets/map/recordbtn.png","../assets/map/taskicon.png","../assets/map/map2+bg2.png","../assets/map/mapredbagicom.png","../assets/map/maplight2.png"]}
\ No newline at end of file
{"options":{"layoutMath":"2","sizeMode":"2n","useExtension":1,"layoutGap":1,"extend":0},"projectName":"redbombtips","version":5,"files":["../assets/redbombtips/redbagtips_ele.png","../assets/redbombtips/redbagtips_ele1.png","../assets/redbombtips/redbagtips_ele2.png","../assets/redbombtips/redbagtips_ele3.png","../assets/redbombtips/redbagtips_light.png","../assets/redbombtips/redbagtips按钮.png","../assets/redbombtips/redbagtips活动规则.png","../assets/redbombtips/redbagtipsbg.png","../assets/redbombtips/redbagtips_ele7.png"]}
\ No newline at end of file
egret/resource/assets/prize/点亮.png

27.9 KB | W: | H:

egret/resource/assets/prize/点亮.png

13.6 KB | W: | H:

egret/resource/assets/prize/点亮.png
egret/resource/assets/prize/点亮.png
egret/resource/assets/prize/点亮.png
egret/resource/assets/prize/点亮.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -21,7 +21,7 @@
"name": "buy3"
},
{
"keys": "宝箱_png,宝箱1_png,宝箱2_png,宝箱3_png,宝箱bg_png,宝箱btn_png,道具_png,关闭 拷贝_png,光 副本 4_png,设置_png,设置bg_png,声音_png,声音关闭_png,狮子_png,退出_png,问题_png,无星星_png,星星_png,星星bg_png,音乐_png,音乐关闭_png,有星星_png,有星星2_png,有星星3_png,元宝bg_png,ad_icon_png,animal1_png,avatar_png,friend_avatar_png,guideBox_png,guideLevel_png,guideLove_png,guideMoney_png,guideOver_png,icon_png,iconbg_png,icongray_png,invite_icon_png,invite_txtbg_png,lionMsgBg_png,map_signicon_png,map1_jpg,map2_jpg,map2+_png,map2+bg_png,map2红包大作战_png,map2热门引导_png,map2周一红包雨_png,map3_jpg,map大转盘_png,map刮现金红包_png,map今日可领_png,map明日可领_png,maphot_png,msgTri_png,namebg_png,progress1_png,progress2_png,recordbtn_png,taskicon_png",
"keys": "宝箱_png,宝箱1_png,宝箱2_png,宝箱3_png,宝箱bg_png,宝箱btn_png,道具_png,关闭 拷贝_png,光 副本 4_png,设置_png,设置bg_png,声音_png,声音关闭_png,狮子_png,退出_png,问题_png,无星星_png,星星_png,星星bg_png,音乐_png,音乐关闭_png,有星星_png,有星星2_png,有星星3_png,元宝bg_png,ad_icon_png,animal1_png,avatar_png,friend_avatar_png,guideBox_png,guideLevel_png,guideLove_png,guideMoney_png,guideOver_png,icon_png,iconbg_png,icongray_png,invite_icon_png,invite_txtbg_png,lionMsgBg_png,map_signicon_png,map1_jpg,map2_jpg,map2+_png,map2+bg_png,map2红包大作战_png,map2热门引导_png,map2周一红包雨_png,map3_jpg,map大转盘_png,map刮现金红包_png,map今日可领_png,map明日可领_png,maphot_png,msgTri_png,namebg_png,progress1_png,progress2_png,recordbtn_png,taskicon_png,map2+bg2_png,mapredbagicom_png,maplight2_png",
"name": "map"
},
{
......@@ -29,7 +29,7 @@
"name": "noprize"
},
{
"keys": "PrizePanelX_png,prizePanelUseBtn_png,点亮_png,点亮 副本 2_png",
"keys": "PrizePanelX_png,prizePanelUseBtn_png,点亮gray_png,点亮_png,点亮 副本 2gray_png,点亮 副本 2_png",
"name": "prize"
},
{
......@@ -81,7 +81,7 @@
"name": "signprize"
},
{
"keys": "toast_png,share_btn2_png,share_btn1_png,prizePanelbg_png,nums2_png,nums2_fnt,nums_png,nums_fnt,lightani_png,common_yuanbao_png,common_prizelight_png,common_adbg_png,commmon_okbtn1_png,closeCommonBtn_png,btn_png,alertbg_png,朋友圈中间分享蒙层1_jpg,按钮 副本 4_png,按钮 副本 3_png,exchangebtn_png,turnnoprize再来一次2_png,FZY4JW_TTF,FZY3JW_1_TTF,hbGameCutTimeFont_fnt,hbGameScoreFont_fnt,hbCutTimeFont_fnt",
"keys": "turnnoprize再来一次2_png,toast_png,sharenums_png,sharenums_fnt,share_btn2_png,share_btn1_png,prizePanelbg_png,nums3_png,nums3_fnt,nums2_png,nums2_fnt,nums_png,nums_fnt,lightani_png,exchangebtn_png,cutTimeFont_png,cutTimeFont_fnt,common_yuanbao_png,common_prop3_png,common_prop2_png,common_prop1_png,common_prizelight_png,common_money_png,common_blood_png,common_adbg_png,commmon_okbtn1_png,closeCommonBtn_png,btn_png,alertbg_png,朋友圈中间分享蒙层1_jpg,按钮 副本 4_png,按钮 副本 3_png",
"name": "common"
},
{
......@@ -177,7 +177,7 @@
"name": "turntableprize"
},
{
"keys": "hbCutTime_bg_png,hbCutTime_btn_disable_png,hbCutTime_btn_enable_png,hbCutTime_cutLine_disable_png,hbCutTime_cutLine_enable_png,hbCutTime_rule_btn_png,hbCutTime_btn_null_png",
"keys": "hbCutTime_bg_png,hbCutTime_btn_disable_png,hbCutTime_btn_enable_png,hbCutTime_cutLine_disable_png,hbCutTime_cutLine_enable_png,hbCutTime_rule_btn_png,hbCutTime_btn_null_png,hbCutTime_btn_soon_png",
"name": "hbcuttime"
},
{
......@@ -199,10 +199,6 @@
{
"keys": "redbagtips_ele_png,redbagtips_ele1_png,redbagtips_ele2_png,redbagtips_ele3_png,redbagtips_light_png,redbagtips按钮_png,redbagtips活动规则_png,redbagtipsbg_png,redbagtips_ele7_png",
"name": "redbombtips"
},
{
"name": "preload",
"keys": "maplight2_png"
}
],
"resources": [
......@@ -3534,9 +3530,54 @@
"subkeys": "反馈1_00000,反馈1_00001,反馈1_00002,反馈1_00003,反馈1_00004,反馈1_00005,反馈1_00006,反馈1_00007,反馈1_00008,反馈1_00009,反馈1_00010,反馈1_00011,反馈1_00012,反馈1_00013,反馈1_00014,反馈1_00015,反馈1_00016,反馈1_00017,反馈1_00018,反馈1_00019,反馈1_00020,反馈1_00021,反馈1_00022,反馈1_00023,反馈1_00024,反馈1_00025,反馈1_00026,反馈1_00027,反馈1_00028"
},
{
"name": "maplight2_png",
"url": "assets/map/maplight2.png",
"type": "image",
"name": "maplight2_png"
},
{
"url": "assets/hbCutTime/hbCutTime_btn_soon.png",
"type": "image",
"name": "hbCutTime_btn_soon_png"
},
{
"url": "assets/map/map2+bg2.png",
"type": "image",
"name": "map2+bg2_png"
},
{
"url": "assets/prize/点亮 副本 2gray.png",
"type": "image",
"name": "点亮 副本 2gray_png"
},
{
"url": "assets/prize/点亮gray.png",
"type": "image",
"name": "点亮gray_png"
},
{
"url": "assets/common/common_blood.png",
"type": "image",
"name": "common_blood_png"
},
{
"url": "assets/common/common_money.png",
"type": "image",
"name": "common_money_png"
},
{
"url": "assets/common/common_prop2.png",
"type": "image",
"name": "common_prop2_png"
},
{
"url": "assets/common/common_prop1.png",
"type": "image",
"name": "common_prop1_png"
},
{
"url": "assets/common/common_prop3.png",
"type": "image",
"url": "assets/map/maplight2.png"
"name": "common_prop3_png"
}
]
}
\ No newline at end of file
{
"skins": {},
"autoGenerateExmlsList": true,
"exmls": [
"resource/skins/ADSkin.exml",
"resource/skins/ADSmallSkin.exml",
"resource/skins/AlertSkin.exml",
"resource/skins/AvatarSkin.exml",
"resource/skins/BackSkin.exml",
"resource/skins/BagItem2Skin.exml",
"resource/skins/BagItemSkin.exml",
"resource/skins/BagQuitSkin.exml",
"resource/skins/BagSkin.exml",
"resource/skins/Blood2Skin.exml",
"resource/skins/BloodSkin.exml",
"resource/skins/Box2Skin.exml",
"resource/skins/BoxSkin.exml",
"resource/skins/Buy1Skin.exml",
"resource/skins/Buy2Skin.exml",
"resource/skins/Buy3Skin.exml",
"resource/skins/ExchangeSkin.exml",
"resource/skins/FailSkin.exml",
"resource/skins/FriendItem2Skin.exml",
"resource/skins/FriendItemSkin.exml",
"resource/skins/FriendShareSkin.exml",
"resource/skins/FriendSkin.exml",
"resource/skins/H52Skin.exml",
"resource/skins/H5Skin.exml",
"resource/skins/HbCutTimeSkin.exml",
"resource/skins/HbGameSkin.exml",
"resource/skins/HbNoPrizeSkin.exml",
"resource/skins/HbPrizeSkin.exml",
"resource/skins/HbRuleSkin.exml",
"resource/skins/IconButtonSkin.exml",
"resource/skins/InviteCutTimePanelSkin.exml",
"resource/skins/InviteItemSkin.exml",
"resource/skins/InvitePrizePanelSkin.exml",
"resource/skins/InviteRulePanelSkin.exml",
"resource/skins/InviteRuleSkin.exml",
"resource/skins/InviteSkin.exml",
"resource/skins/Main2Skin.exml",
"resource/skins/MapBottomSkin.exml",
"resource/skins/MapRepeatSkin.exml",
"resource/skins/MapSkin.exml",
"resource/skins/MapTopSkin.exml",
"resource/skins/NoPrizeSkin.exml",
"resource/skins/OptionItemSkin.exml",
"resource/skins/OptionsSkin.exml",
"resource/skins/PlaySkin.exml",
"resource/skins/Prize2Skin.exml",
"resource/skins/PrizeSkin.exml",
"resource/skins/QuitSkin.exml",
"resource/skins/RankFriendListSkin.exml",
"resource/skins/RankItemSkin.exml",
"resource/skins/RankSkin.exml",
"resource/skins/RedBagActivitySkin.exml",
"resource/skins/RedBagAlertSkin.exml",
"resource/skins/RedBombTipsSkin.exml",
"resource/skins/ReliveSkin.exml",
"resource/skins/RuleSkin.exml",
"resource/skins/ScratchItemSkin.exml",
"resource/skins/ScratchPrizeSkin.exml",
"resource/skins/ScratchRuleSkin.exml",
"resource/skins/ScratchSkin.exml",
"resource/skins/Share2Skin.exml",
"resource/skins/Share3Skin.exml",
"resource/skins/ShareSkin.exml",
"resource/skins/ShareTipsSkin.exml",
"resource/skins/ShopSkin.exml",
"resource/skins/ShowOffSkin.exml",
"resource/skins/SignItemSkin.exml",
"resource/skins/SignPrizeSkin.exml",
"resource/skins/SignSkin.exml",
"resource/skins/StarSkin.exml",
"resource/skins/StartPanelSkin.exml",
"resource/skins/StartSkin.exml",
"resource/skins/TargetItemSkin.exml",
"resource/skins/TaskItemSkin.exml",
"resource/skins/TaskPrizeSkin.exml",
"resource/skins/TaskSkin.exml",
"resource/skins/Toast2Skin.exml",
"resource/skins/ToastSkin.exml",
"resource/skins/RedBombTipsSkin.exml",
"resource/skins/RedBombRuleSkin.exml",
"resource/skins/TurnRuleSkin.exml",
"resource/skins/TurntableNoPrizeSkin.exml",
"resource/skins/TurntablePrize2Skin.exml",
"resource/skins/TurntablePrizeSkin.exml",
"resource/skins/TurntableSkin.exml",
"resource/skins/VScrollBarSkin.exml"
],
"path": "resource/default.thm.json"
"skins": {},
"autoGenerateExmlsList": true,
"exmls": [
"resource/skins/ADSkin.exml",
"resource/skins/ADSmallSkin.exml",
"resource/skins/AlertSkin.exml",
"resource/skins/AvatarSkin.exml",
"resource/skins/BackSkin.exml",
"resource/skins/BagItem2Skin.exml",
"resource/skins/BagItemSkin.exml",
"resource/skins/BagQuitSkin.exml",
"resource/skins/BagSkin.exml",
"resource/skins/Blood2Skin.exml",
"resource/skins/BloodSkin.exml",
"resource/skins/Box2Skin.exml",
"resource/skins/BoxSkin.exml",
"resource/skins/Buy1Skin.exml",
"resource/skins/Buy2Skin.exml",
"resource/skins/Buy3Skin.exml",
"resource/skins/ExchangeSkin.exml",
"resource/skins/FailSkin.exml",
"resource/skins/FriendItem2Skin.exml",
"resource/skins/FriendItemSkin.exml",
"resource/skins/FriendShareSkin.exml",
"resource/skins/FriendSkin.exml",
"resource/skins/H52Skin.exml",
"resource/skins/H5Skin.exml",
"resource/skins/HbCutTimeSkin.exml",
"resource/skins/HbGameSkin.exml",
"resource/skins/HbNoPrizeSkin.exml",
"resource/skins/HbPrizeSkin.exml",
"resource/skins/HbRuleSkin.exml",
"resource/skins/IconButtonSkin.exml",
"resource/skins/InviteCutTimePanelSkin.exml",
"resource/skins/InviteItemSkin.exml",
"resource/skins/InvitePrizePanelSkin.exml",
"resource/skins/InviteRulePanelSkin.exml",
"resource/skins/InviteRuleSkin.exml",
"resource/skins/InviteSkin.exml",
"resource/skins/Main2Skin.exml",
"resource/skins/MapBottomSkin.exml",
"resource/skins/MapRepeatSkin.exml",
"resource/skins/MapSkin.exml",
"resource/skins/MapTopSkin.exml",
"resource/skins/NoPrizeSkin.exml",
"resource/skins/OptionItemSkin.exml",
"resource/skins/OptionsSkin.exml",
"resource/skins/PlaySkin.exml",
"resource/skins/Prize2Skin.exml",
"resource/skins/PrizeSkin.exml",
"resource/skins/QuitSkin.exml",
"resource/skins/RankFriendListSkin.exml",
"resource/skins/RankItemSkin.exml",
"resource/skins/RankSkin.exml",
"resource/skins/RedBagActivitySkin.exml",
"resource/skins/RedBagAlertSkin.exml",
"resource/skins/RedBombRuleSkin.exml",
"resource/skins/RedBombTipsSkin.exml",
"resource/skins/ReliveSkin.exml",
"resource/skins/RuleSkin.exml",
"resource/skins/ScratchItemSkin.exml",
"resource/skins/ScratchPrizeSkin.exml",
"resource/skins/ScratchRuleSkin.exml",
"resource/skins/ScratchSkin.exml",
"resource/skins/Share2Skin.exml",
"resource/skins/Share3Skin.exml",
"resource/skins/ShareSkin.exml",
"resource/skins/ShareTipsSkin.exml",
"resource/skins/ShopSkin.exml",
"resource/skins/ShowOffSkin.exml",
"resource/skins/SignItemSkin.exml",
"resource/skins/SignPrizeSkin.exml",
"resource/skins/SignSkin.exml",
"resource/skins/StarSkin.exml",
"resource/skins/StartPanelSkin.exml",
"resource/skins/StartSkin.exml",
"resource/skins/TargetItemSkin.exml",
"resource/skins/TaskItemSkin.exml",
"resource/skins/TaskPrizeSkin.exml",
"resource/skins/TaskSkin.exml",
"resource/skins/Toast2Skin.exml",
"resource/skins/ToastSkin.exml",
"resource/skins/TurnRuleSkin.exml",
"resource/skins/TurntableNoPrizeSkin.exml",
"resource/skins/TurntablePrize2Skin.exml",
"resource/skins/TurntablePrizeSkin.exml",
"resource/skins/TurntableSkin.exml",
"resource/skins/VScrollBarSkin.exml"
],
"path": "resource/default.thm.json"
}
\ No newline at end of file
......@@ -21,5 +21,5 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Image id="ok_btn" y="717" source="hbCutTime_btn_enable_png" horizontalCenter="1"/>
<e:Image id="ok_btn" y="769" source="hbCutTime_btn_enable_png" horizontalCenter="1" anchorOffsetX="179" anchorOffsetY="52"/>
</e:Skin>
\ No newline at end of file
......@@ -6,10 +6,10 @@
<e:Image y="0" source="hbGame_num_bg_png" horizontalCenter="0"/>
<e:BitmapLabel id="scoreLabel" y="33" text="0" horizontalCenter="0" font="hbGameScoreFont_fnt"/>
</e:Group>
<e:Group y="45" horizontalCenter="0" height="154">
<e:Group id="cutTimerGroup" y="45" horizontalCenter="0" height="154">
<e:Image id="timeBtn" y="0" horizontalCenter="0" x="10" source="hbGame_CutTime_btn_png"/>
<e:Image y="25" horizontalCenter="0" source="hbGame_CutTime_bg_png"/>
<e:Image y="32" source="hbGame_CutTime_progress_png" horizontalCenter="-0.5"/>
<e:Image id="cutCircle" y="32" source="hbGame_CutTime_progress_png" horizontalCenter="-0.5"/>
<e:BitmapLabel id="cutTimeLabel" y="67" text="60" font="hbGameCutTimeFont_fnt" horizontalCenter="0.5"/>
</e:Group>
<e:Group id="readyGroup" y="310.5" horizontalCenter="0" width="560" height="710" anchorOffsetY="0">
......@@ -17,6 +17,6 @@
<e:Label text="点击所有动物均可累积双份红包" y="520" fontFamily="FZY3JW" horizontalCenter="0"/>
<e:Image y="566" source="hbGame_lion_touch_png" horizontalCenter="-37.5"/>
<e:Image y="597" source="hbGame_+2_png" horizontalCenter="82"/>
<e:Image id="readyCutTime" y="95" horizontalCenter="0" x="10" source="hbGame_1_png"/>
<e:Image id="readyCutTime" y="121" horizontalCenter="0" x="10" source="hbGame_1_png"/>
</e:Group>
</e:Skin>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<e:Skin class="MapSkin" width="750" height="1206" xmlns:e="http://ns.egret.com/eui" xmlns:w="http://ns.egret.com/wing">
<e:Rect id="rectbg" width="750" height="1206"/>
<e:Rect id="rectbg" width="750" height="1206" visible="false"/>
<e:Scroller id="scroll" width="750" height="1624" x="0" y="0" scrollPolicyH="off" scrollPolicyV="on" locked="true">
<e:Group id="scrollGroup">
</e:Group>
......@@ -134,8 +134,9 @@
</e:Group>
</e:Group>
<e:Group id="activitys" x="13.4" y="620.55">
<e:Group id="actIconsGroup" x="12.12" y="0" visible="false">
<e:Image source="map2+bg_png" x="-27.15" y="0"/>
<e:Group id="actIconsGroup" x="12.12" y="0">
<e:Image id="actIconsBg1" source="map2+bg_png" x="-27.15" y="0" visible="false"/>
<e:Image id="actIconsBg2" x="-29.27" y="10" source="map2+bg2_png"/>
<e:Group id="hbRainGroup" x="4.27" y="157.5" width="120" height="120">
<e:Button id="hbRainBtn" label="" y="-1" x="0">
<e:skinName>
......@@ -146,7 +147,7 @@
</e:skinName>
</e:Button>
</e:Group>
<e:Image id="act2Btn" source="map2红包大作战_png" x="157.76" y="159"/>
<e:Image id="act2Btn" source="map2红包大作战_png" x="157.76" y="159" visible="false"/>
</e:Group>
<e:Image id="actsShowBtn" source="map2+_png" x="-7.64" y="5.45"/>
<e:Image source="maphot_png" x="91.52" y="15.72"/>
......
<?xml version="1.0" encoding="utf-8"?>
<e:Skin class="NoPrizeSkin" width="750" height="1000" xmlns:e="http://ns.egret.com/eui" xmlns:w="http://ns.egret.com/wing">
<e:Component y="735.52" skinName="ADSmallSkin" x="84" visible="false"/>
<e:Component y="917.46" skinName="ADSmallSkin" x="84" visible="false"/>
<e:Image id="light" source="common_prizelight_png" x="374.19" y="329.51" anchorOffsetX="375.76" anchorOffsetY="327.27"/>
<e:Image y="109.55" source="擦肩而过弹窗 _png" horizontalCenter="0.5"/>
<e:Button id="closeBtn" label="" x="617" y="279">
<e:Button id="closeBtn" label="" x="609" y="344.28">
<e:skinName>
<e:Skin states="up,down,disabled">
<e:Image width="100%" height="100%" source="closeCommonBtn_png" source.down="closeCommonBtn_png" source.disabled="closeCommonBtn_png"/>
......@@ -11,13 +11,7 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Image id="picb" source="点亮 副本 2_png" x="142" y="179"/>
<e:Image id="pica" source="点亮 副本 2_png" x="608" y="179" scaleX="-1"/>
<e:Image id="picc" source="点亮_png" y="130" x="280"/>
<e:Image id="pic1" source="点亮 副本 2_png" x="218" y="237" anchorOffsetX="76" anchorOffsetY="58"/>
<e:Image id="pic3" source="点亮 副本 2_png" x="534" y="235" scaleX="-1" anchorOffsetX="74" anchorOffsetY="56"/>
<e:Image id="pic2" source="点亮_png" y="200" horizontalCenter="0" anchorOffsetX="98" anchorOffsetY="70"/>
<e:Button id="shareBtn" label="" y="588" horizontalCenter="-145.5">
<e:Button id="shareBtn" label="" y="766" horizontalCenter="-145.5">
<e:skinName>
<e:Skin states="up,down,disabled">
<e:Image width="100%" height="100%" source="按钮 副本 3_png" source.down="按钮 副本 3_png" source.disabled="按钮 副本 3_png"/>
......@@ -25,7 +19,7 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Button id="goBtn" label="" y="588" horizontalCenter="144">
<e:Button id="goBtn" label="" y="766" horizontalCenter="144">
<e:skinName>
<e:Skin states="up,down,disabled">
<e:Image width="100%" height="100%" source="按钮 副本 4_png" source.down="按钮 副本 4_png" source.disabled="按钮 副本 4_png"/>
......@@ -33,5 +27,12 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Image id="picb" x="286" y="391.28" source="点亮 副本 2gray_png" scaleX="-1"/>
<e:Image id="pica" x="465.48" y="384.28" source="点亮 副本 2gray_png"/>
<e:Image id="picc" y="367.28" source="点亮gray_png" x="310"/>
<e:Image id="pic1" source="点亮 副本 2_png" x="214.18" y="443.39" anchorOffsetX="81.82" anchorOffsetY="60.61" scaleX="-1"/>
<e:Image id="pic3" source="点亮 副本 2_png" x="528.24" y="446.89" scaleX="1" anchorOffsetX="71.76" anchorOffsetY="66.61"/>
<e:Image id="pic2" source="点亮_png" y="440.01" anchorOffsetX="73.94" anchorOffsetY="74.73" x="375.94"/>
<e:Label id="lvTxt" text="关卡1" y="326" textColor="0xFF841B" horizontalCenter="0.5"/>
<w:Config id="1690063a75e"/>
</e:Skin>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<e:Skin class="PrizeSkin" width="750" height="1206" xmlns:e="http://ns.egret.com/eui" xmlns:w="http://ns.egret.com/wing">
<w:Config id="169005181d0"/>
<e:Component y="859.74" skinName="ADSmallSkin" x="84" visible="false"/>
<e:Image id="light" source="common_prizelight_png" x="374.19" y="253.76" anchorOffsetX="375.76" anchorOffsetY="327.27"/>
<e:Image source="prizePanelbg_png" y="61.15" horizontalCenter="0.5"/>
<e:Image id="img" width="508" height="225" source="{data.url}" horizontalCenter="0" y="411.76" visible="false"/>
<e:Image id="money" source="signprize元宝_png" y="402.2" horizontalCenter="0" scaleX="0.8" scaleY="0.8" visible="false"/>
<e:Image id="blood" source="singprize体力_png" y="364.8" horizontalCenter="0" visible="false"/>
<e:Group id="numsgroup" x="396.38" y="410.4" visible="false">
<e:Component y="889.74" skinName="ADSmallSkin" x="84" visible="false"/>
<e:Image id="light" source="common_prizelight_png" x="374.19" y="253.76" anchorOffsetX="375.76" anchorOffsetY="327.27" visible="false"/>
<e:Image source="prizePanelbg_png" y="61.15" scale9Grid="87,543,522,23" height="839" x="28"/>
<e:Image id="img" width="508" height="225" source="{data.url}" horizontalCenter="0" y="515.76" visible="false"/>
<e:Image id="img2" horizontalCenter="0" y="515.76" source="{data.url2}" scaleX="0.7" scaleY="0.7" visible="false"/>
<e:Image id="money" y="516.2" scaleX="0.6" scaleY="0.6" source="common_money_png" x="150" visible="false"/>
<e:Image id="blood" y="518.8" horizontalCenter="1.5" source="common_blood_png" scaleX="0.7" scaleY="0.7" visible="false"/>
<e:Group id="numsgroup" x="396.38" y="518.4" visible="false">
<e:Image id="numsbg" source="signprize_numsbg_png" x="0" y="0"/>
<e:Label id="propnums" text="X8" size="22" horizontalCenter="0" verticalCenter="0" verticalAlign="middle" textAlign="center"/>
</e:Group>
<e:Button id="closeBtn" label="" x="618" y="235.25">
<e:Label id="propnums2" text="30" textColor="0x885037" bold="true" y="651.08" width="75" textAlign="right" x="287.16" visible="false"/>
<e:Button id="closeBtn" label="" x="608" y="287.25">
<e:skinName>
<e:Skin states="up,down,disabled">
<e:Image width="100%" height="100%" source="closeCommonBtn_png" source.down="closeCommonBtn_png" source.disabled="closeCommonBtn_png"/>
......@@ -19,7 +21,7 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Button id="shareBtn" label="" y="714.28" horizontalCenter="-145.5">
<e:Button id="shareBtn" label="" y="766" horizontalCenter="-145">
<e:skinName>
<e:Skin states="up,down,disabled">
<e:Image width="100%" height="100%" source="按钮 副本 3_png" source.down="按钮 副本 3_png" source.disabled="按钮 副本 3_png"/>
......@@ -27,7 +29,7 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Button id="goBtn" label="" y="714.28" horizontalCenter="144">
<e:Button id="goBtn" label="" y="766.28" horizontalCenter="144.5">
<e:skinName>
<e:Skin states="up,down,disabled">
<e:Image width="100%" height="100%" source="按钮 副本 4_png" source.down="按钮 副本 4_png" source.disabled="按钮 副本 4_png"/>
......@@ -35,10 +37,11 @@
</e:Skin>
</e:skinName>
</e:Button>
<e:Image id="picb" source="点亮 副本 2_png" x="142" y="118.28"/>
<e:Image id="pica" source="点亮 副本 2_png" x="608" y="118.28" scaleX="-1"/>
<e:Image id="picc" source="点亮_png" y="69.28" x="280"/>
<e:Image id="pic1" source="点亮 副本 2_png" x="223.82" y="178.89" anchorOffsetX="81.82" anchorOffsetY="60.61"/>
<e:Image id="pic3" source="点亮 副本 2_png" x="532.24" y="178.89" scaleX="-1" anchorOffsetX="75.76" anchorOffsetY="60.61"/>
<e:Image id="pic2" source="点亮_png" y="142.01" x="373.94" anchorOffsetX="93.94" anchorOffsetY="72.73"/>
<e:Image id="picb" x="286" y="339.28" source="点亮 副本 2gray_png" scaleX="-1"/>
<e:Image id="pica" x="465.48" y="332.28" source="点亮 副本 2gray_png"/>
<e:Image id="picc" y="315.28" source="点亮gray_png" x="310"/>
<e:Image id="pic1" source="点亮 副本 2_png" x="214.18" y="391.39" anchorOffsetX="81.82" anchorOffsetY="60.61" scaleX="-1"/>
<e:Image id="pic3" source="点亮 副本 2_png" x="528.24" y="394.89" scaleX="1" anchorOffsetX="71.76" anchorOffsetY="66.61"/>
<e:Image id="pic2" source="点亮_png" y="388.01" anchorOffsetX="73.94" anchorOffsetY="74.73" x="375.94"/>
<e:Label id="lvTxt" text="关卡1" y="276" textColor="0xff841b" horizontalCenter="0.5"/>
</e:Skin>
\ No newline at end of file
......@@ -16,7 +16,7 @@
</e:Group>
<e:Image id="progressmask2" y="9.14" x="16" source="mask2_png" width="444" height="60" scaleX="1"/>
</e:Group>
<e:Image source="头顶树丛_png" x="0" y="0"/>
<e:Image source="头顶树丛_png" x="0" y="0" visible="false"/>
<e:Label id="tips" text="正在加载中,请稍后" y="993" textColor="0x244b00" horizontalCenter="0" size="24"/>
<e:Label id="percentTxt" text="63%" y="1110" textColor="0x244B00" horizontalCenter="0.5"/>
</e:Skin>
\ No newline at end of file
......@@ -90,6 +90,11 @@ export default class MapScene extends Scene {
async start(data?) {
super.start();
// NetManager.ins.hc_submit(()=>{
// const submitData = DataManager.ins.getData('hc_submit').data;
// PanelCtrl.instance.show(ModuleTypes.PRIZE_PANEL,{ level:1, option: submitData.option })
// },1,1,'','')
this['actIconsGroup'].x = -999;
this.addIcon(); // 添加Icon
......
......@@ -2,6 +2,7 @@ import IconBase from "./IconBase";
import PanelCtrl from "../../../libs/new_wx/ctrls/panelCtrl";
import { GDispatcher } from "../../../libs/tc/util/GDispatcher";
import { NetManager } from "../../../libs/tw/manager/NetManager";
import CutTimer from "../../CutTimer";
export default class HbRainIcon extends IconBase {
......@@ -18,11 +19,17 @@ export default class HbRainIcon extends IconBase {
private updateIcon() {
NetManager.ins.hbRainBaseInfo((success, res) => {
if(!success) {
if(res.code == "600054" || res.code == "600055"){
if(res.code == "600054" || res.code == "600055") {
this.visible = false;
}
return;
}
const data = res.data;
if(!data.currentSession && !data.nextSession) {
this.visible = false;
return;
}
this.visible = true;
})
}
......@@ -33,16 +40,20 @@ export default class HbRainIcon extends IconBase {
protected onTouchBtn(e: egret.TouchEvent) {
super.onTouchBtn(e);
PanelCtrl.instance.show("HbCutTime");
NetManager.ins.hbRainBaseInfo((success, res) => {
PanelCtrl.instance.show("HbCutTime", {res: res});
});
GDispatcher.dispatchEvent('closeActBtn');
}
protected initEvents() {
super.initEvents();
GDispatcher.addEvent('updateHbRainIcon', this.updateIcon, this);
}
protected removeEvents() {
super.removeEvents();
GDispatcher.removeEvent('updateHbRainIcon', this.updateIcon, this);
}
protected destory() {
......
......@@ -28,53 +28,69 @@ export default class HbCutTime extends Panel {
initUI() {
this.hbRainBaseInfo();
this.ok_btn.anchorOffsetX = 179;
this.ok_btn.anchorOffsetY = 52;
}
private hbRainBaseInfo() {
NetManager.ins.hbRainBaseInfo((success, res) => {
if(!success) {
this.ok_btn.source = 'hbCutTime_btn_null_png';
this.tipImage.source = 'hbCutTime_cutLine_disable_png';
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
return;
}
let data = res.data;
this.cutTimer = new CutTimer(this.cutTimeLabel, 'hh时mm分ss秒', () => this.hidePanel());
let sysTime = res.timestamp; // 当前系统事件
let time;
if(data.currentSession) {
time = data.currentSession.endTime - sysTime + 3000;
if(data.canJoin) {
this.ok_btn.source = 'hbCutTime_btn_enable_png';
this.ok_btn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
} else {
this.ok_btn.source = 'hbCutTime_btn_disable_png';
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
}
this.tipImage.source = 'hbCutTime_cutLine_enable_png';
if(!this.cutTimer.start(time)) {
this.cutTimer.stop();
this.cutTimer.start(time);
}
} else if(data.nextSession) {
time = data.nextSession.startTime - sysTime + 3000;
this.ok_btn.source = 'hbCutTime_btn_disable_png';
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
this.tipImage.source = 'hbCutTime_cutLine_disable_png';
if(!this.cutTimer.start(time)) {
this.cutTimer.stop();
this.cutTimer.start(time);
}
const success = this.data.res.success;
const res = this.data.res;
const data = this.data.res.data;
if(!success) {
this.ok_btn.source = 'hbCutTime_btn_soon_png';
this.tipImage.source = 'hbCutTime_cutLine_disable_png';
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
return;
}
this.cutTimer = new CutTimer(this.cutTimeLabel, 'hh时mm分ss秒', () => this.hidePanel());
let sysTime = res.timestamp; // 当前系统时间
let time;
if(data.currentSession) {
time = data.currentSession.endTime - sysTime + 3000;
if(data.canJoin) {
this.ok_btn.source = 'hbCutTime_btn_enable_png';
this.btnEffect();
this.ok_btn.addEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
} else {
this.ok_btn.source = 'hbCutTime_btn_null_png';
this.tipImage.source = 'hbCutTime_cutLine_disable_png';
this.ok_btn.source = 'hbCutTime_btn_disable_png';
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
}
})
this.tipImage.source = 'hbCutTime_cutLine_enable_png';
if(!this.cutTimer.start(time)) {
this.cutTimer.stop();
this.cutTimer.start(time);
}
} else if(data.nextSession) {
time = data.nextSession.startTime - sysTime + 3000;
this.ok_btn.source = 'hbCutTime_btn_soon_png';
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
this.tipImage.source = 'hbCutTime_cutLine_disable_png';
if(!this.cutTimer.start(time)) {
this.cutTimer.stop();
this.cutTimer.start(time);
}
} else {
this.ok_btn.source = 'hbCutTime_btn_null_png';
this.tipImage.source = 'hbCutTime_cutLine_disable_png';
this.ok_btn.removeEventListener(egret.TouchEvent.TOUCH_TAP, this.onTouchOK, this);
}
}
private btnEffect() {
egret.Tween.get(this.ok_btn).to({scaleX: 0.9, scaleY: 1.1}, 200, egret.Ease.quadInOut).call(() => {
egret.Tween.get(this.ok_btn).to({scaleX: 1, scaleY: 1}, 200, egret.Ease.quadInOut).call(() => {
egret.Tween.get(this.ok_btn).to({scaleX: 0.9618, scaleY: 1.0618}, 200, egret.Ease.quadInOut).call(() => {
egret.Tween.get(this.ok_btn).to({scaleX: 1, scaleY: 1}, 200, egret.Ease.quadInOut).wait(1000).call(() => {
this.btnEffect();
})
});
})
});
}
destroy() {
if(this.cutTimer){
if(this.cutTimer) {
this.cutTimer.stop();
}
super.destroy();
......@@ -112,7 +128,7 @@ export default class HbCutTime extends Panel {
}
onTouchOK() {
PanelCtrl.instance.show('HbGame');
PanelCtrl.instance.show('HbGame', {needScore: this.data.res.data.currentSession.limitScore});
}
protected get closeBtns(): eui.Button[] {
......
......@@ -8,6 +8,8 @@ import { NetName } from "../../../libs/tw/enum/NetName";
import PanelCtrl from "../../../libs/new_wx/ctrls/panelCtrl";
import SceneCtrl from "../../../libs/new_wx/ctrls/sceneCtrl";
import Utils from "../../Utils";
import Shape = egret.Shape;
import nrABIVersion = egret_native.nrABIVersion;
/**
* 红包雨主游戏
......@@ -16,7 +18,9 @@ export default class HbGame extends Panel {
public rainGroup: eui.Group;
public scoreGroup: eui.Group;
public scoreLabel: eui.BitmapLabel;
public cutTimerGroup: eui.Group;
public timeBtn: eui.Image;
public cutCircle: eui.Image;
public cutTimeLabel: eui.BitmapLabel;
public readyGroup: eui.Group;
public tipLabel: eui.Label;
......@@ -25,11 +29,14 @@ export default class HbGame extends Panel {
private rainMgr: RainMgr = null;
private cutTime: egret.Timer = null;
private time: number = 15;
private time: number = window['hbRainTime'];
private totalTime: number = window['hbRainTime'];
private score = 0;
private scoreLabelStr = 0;
private cutShape: egret.Shape;
constructor(data) {
super();
this.data = data;
......@@ -44,8 +51,15 @@ export default class HbGame extends Panel {
initUI() {
this.rainGroup.height = this.width / window.innerWidth * window.innerHeight;
this.tipLabel.textFlow = (new HtmlTextParser).parser(`抢到<b>${15}</b>个红包才有奖励哦~`);
this.cutTimeLabel.text = `${this.time}`
this.tipLabel.textFlow = (new HtmlTextParser).parser(`抢到<b>${this.data.needScore}</b>个红包才有奖励哦~`);
this.cutTimeLabel.text = `${this.time}`;
this.cutShape = new egret.Shape();
this.cutShape.graphics.beginFill(0xff0000);
this.cutShape.graphics.drawArc(63, 90, 60, -Math.PI / 180 * 90, Math.PI / 180 * 270, true);
this.cutShape.graphics.endFill();
this.cutTimerGroup.addChild(this.cutShape);
this.cutCircle.mask = this.cutShape;
}
// 加分
......@@ -61,7 +75,7 @@ export default class HbGame extends Panel {
private gameOver() {
this.cutTime.stop();
this.cutTime.removeEventListener(egret.TimerEvent.TIMER, this.timeCallFun, this);
GDispatcher.dispatchEvent('hbRainGameOver');
this.rainMgr.gameOver();
this.hbDoJoin();
}
......@@ -134,6 +148,46 @@ export default class HbGame extends Panel {
this.cutTime = new egret.Timer(1000, 0);
this.cutTime.addEventListener(egret.TimerEvent.TIMER, this.timeCallFun, this);
this.cutTime.start();
this.getSectorProgress();
}
private getSectorProgress(): egret.Shape {
let shape = this.cutShape;
let angle: number = 360;
let cTime: number = 0;
let totalTime: number = this.totalTime;
let lastT = new Date().getTime();
let dt = 0;
egret.startTick(function(timeStamp: number): boolean {
dt = (new Date().getTime() - lastT) / 1000;
cTime += dt;
if(cTime > totalTime){
cTime = 0;
}
angle = 360 * cTime / totalTime;
changeGraphics(angle);
angle = angle % 360;
lastT = new Date().getTime();
return true;
}, this);
return shape;
function changeGraphics(angle) {
angle -= 90;
shape.graphics.clear();
shape.graphics.beginFill(0xff0000);
shape.graphics.moveTo(63, 90);
shape.graphics.lineTo(100, 50);
shape.graphics.drawArc(63, 90, 60, -Math.PI / 180 * 90, angle * Math.PI / 180, true);
shape.graphics.lineTo(63, 90);
shape.graphics.endFill();
}
}
private timeCallFun() {
......@@ -141,6 +195,12 @@ export default class HbGame extends Panel {
if(this.time <= 0) {
this.gameOver();
}
if(this.time == 3) {
let _y = this.cutTimerGroup.y;
egret.Tween.get(this.cutTimerGroup, {loop: true}).to({y: _y + 10}, 100).call(() => {
egret.Tween.get(this.cutTimerGroup).to({y: _y}, 100);
})
}
}
private readyTimeEffect() {
......
import Panel from "../../../libs/new_wx/components/Panel";
import { DataManager } from "../../../libs/tw/manager/DataManager";
import { HtmlTextParser } from "../../../libs/new_wx/HtmlTextParser";
import getSkinPath from "../../../libs/new_wx/utils/getSkinPath";
......@@ -32,18 +31,20 @@ export default class HbRule extends Panel {
private addRule() {
const text =
`<br>1、用户每天邀请指定数量的新玩家参与闯关,可获得指定的现金券奖励。
2、用户发起邀请后,需在24小时内完成邀请任务;超过24小时,邀请任务失败,无法获得奖励,需重新发起邀请。
3、新用户仅包含未参与过狮狮连萌活动的用户。
4、用户不可为自己助力,或重复为好友助力。
5、完成邀请任务后,玩家可点击首页“邀请得现金券”图标领取现金券。
6、发放的奖励请在规定的有效时间内尽快领取或使用,逾期未领取或使用的会失效哦。
7、活动过程中,凡以不正当手段(包括但不限于作弊、恶意套现、扰乱系统、网络攻击等违规行为)参与本次活动的用户,苏宁易购有权终止其参加活动,并取消其获得奖励的资格。
8、极少数特殊情况下,若用户在完成活动的任务中被系统判定异常账户或风控账户,则可能导致奖励发放异常。
9、如遇不可抗力(包括但不限于重大自然灾害事件、活动受政府机关指令需要停止举办或调整的、活动遭受严重网络攻击不能正常进行的),苏宁易购有权取消、修改或暂停活动。`
`<br>1、红包雨活动在当天多个时间段开启;每个时间段,所有用户均有1次参与机会,奖励先到先得。
2、在倒计时结束后,收集红包达到目标数量可获得奖励;未达到目标数量,则无法获得奖励。
3、游戏过程中,点击1个红包记为1个红包,点击1个动物元素记为2个红包。
4、发放的奖励请在规定的有效时间内尽快领取或使用,逾期未领取或使用的会失效哦。
5、活动过程中,凡以不正当手段(包括但不限于作弊、恶意套现、扰乱系统、网络攻击等违规行为)参与本次活动的用户,苏宁易购有权终止其参加活动,并取消其获得奖励的资格。
6、极少数特殊情况下,若用户在完成活动的任务中被系统判定异常账户或风控账户,则可能导致奖励发放异常。
7、如遇不可抗力(包括但不限于重大自然灾害事件、活动受政府机关指令需要停止举办或调整的、活动遭受严重网络攻击不能正常进行的),苏宁易购有权取消、修改或暂停活动`
this.labContent.textFlow = (new HtmlTextParser).parser(text);
}
protected onSkinComplete() {
}
get skinKey() {
return 'HbRule'
}
......
......@@ -21,7 +21,7 @@ export default class RainMgr {
this.start();
}
private gameOver() {
public gameOver() {
this.timer.stop(); // 停止计时器
// 隐藏全部掉落物品
......@@ -35,7 +35,7 @@ export default class RainMgr {
GDispatcher.addEvent('hbRainGameOver', this.gameOver, this);
this.timer = new egret.Timer(1400, 0);
this.timer = new egret.Timer(1200, 0);
this.timer.addEventListener(egret.TimerEvent.TIMER, this.addRain, this);
this.timer.start();
}
......@@ -61,7 +61,11 @@ export default class RainMgr {
private addPool() {
this.rainPool = new Pooling();
for(let v of RainData.key) {
for(let i = 0; i < 10; i++) {
let num = 1;
if(v == 'hongbao'){
num = 45;
}
for(let i = 0; i < num; i++) {
let newObj = new RainObj({
key: v,
rainGroup: this.rainGroup,
......
import { GDispatcher } from "../../../libs/tc/util/GDispatcher";
import RainData from "./RainData";
import { loadSvga } from "../../loadSvga";
import getResPath from "../../../libs/new_tc/getResPath";
export default class RainObj {
private data = null;
......@@ -25,6 +27,7 @@ export default class RainObj {
}
private start() {
this.module.alpha = 1;
this.module.touchEnabled = true;
this.module.source = `hbGame_${this.data.key}_png`;
this.module.addEventListener(egret.TouchEvent.TOUCH_TAP, this.touchTap, this);
......@@ -47,12 +50,28 @@ export default class RainObj {
let _scaleY = this.module.scaleY;
egret.Tween.get(this.module).to({scaleX: _scaleX + 0.2, scaleY: _scaleY + 0.2}, 100).call(() => {
this.module.source = `hbGame_${this.data.key}_touch_png`;
egret.Tween.get(this.module).to({scaleX: _scaleX, scaleY: _scaleY}, 100);
egret.Tween.get(this.module).to({scaleX: _scaleX, scaleY: _scaleY}, 100).call(() => {
if(this.data.key == 'hongbao') {
loadSvga(getResPath() + 'resource/assets/svgas/hbRainHb.svga', this.rainGroup).then(async (mv: any) => {
mv.addEventListener(egret.Event.COMPLETE, () => {
this.rainGroup.removeChild(mv);
}, this);
mv.x = this.module.x - 180 * this.module.scaleX;
mv.y = this.module.y - 250 * this.module.scaleY;
mv.touchEnable = false;
mv.scaleX = this.module.scaleX;
mv.scaleY = this.module.scaleY;
this.rainGroup.addChild(mv);
});
}
egret.Tween.get(this.module).to({alpha: 0}, 500);
})
});
}
// 添加分数特效
private addScoreEffect() {
let timeout = (this.data.key == 'hongbao') ? 500 : 300;
setTimeout(() => {
let score = new eui.Image(`hbGame_+${RainData.data[this.data.key].score}_png`);
let _x = score.x = this.module.x - 20;
......@@ -65,7 +84,7 @@ export default class RainObj {
score.visible = false
});
});
}, 500);
}, timeout);
}
private destroy() {
......
......@@ -6,15 +6,17 @@
"currentSession": {
"endTime": 157292106000,
"sessionIndex": 1,
"limitScore": 10,
"startTime": 157292105000
},
"nextSession": {
"endTime": 157292106000,
"sessionIndex": 2,
"limitScore": 66,
"startTime": 157292105000
}
},
"desc": "OK",
"success": false,
"success": true,
"timestamp": 157292100000
}
\ No newline at end of file
This diff is collapsed.
......@@ -7,14 +7,14 @@
"option": {
"id": "41",
"day": null,
"realValue":87,
"realValue":999,
"categoryType": 5,
"title": "游戏次数2",
"rate": "10",
"minValue": null,
"maxValue": null,
"coinType": 1,
"propType": 2,
"propType": 3,
"num": null,
"img": "//yun.dui88.com/images/201910/e6pmpk2pne.png",
"appItemId": null,
......@@ -28,6 +28,6 @@
"errorMsg":null,
"success":true
},
"stars":1
"stars":3
}
}
\ No newline at end of file
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