Commit 166527ce authored by limingzhe's avatar limingzhe

fix: debug

parent a51eee09
...@@ -1231,7 +1231,7 @@ cc.Class({ ...@@ -1231,7 +1231,7 @@ cc.Class({
this.initVideoNode(); this.initVideoNode();
this.startTiming();
...@@ -1263,10 +1263,7 @@ cc.Class({ ...@@ -1263,10 +1263,7 @@ cc.Class({
if (script.showTipRemoveCard) { if (script.showTipRemoveCard) {
script.showTipRemoveCard(() => { script.showTipRemoveCard(() => {
this.checkVideoCanPlay(); this.startTesting();
// this.startTesting();
// this.startTiming();
}) })
} }
...@@ -1279,7 +1276,7 @@ cc.Class({ ...@@ -1279,7 +1276,7 @@ cc.Class({
} }
}) })
} else { } else {
this.checkVideoCanPlay();
} }
}, },
...@@ -1433,11 +1430,10 @@ cc.Class({ ...@@ -1433,11 +1430,10 @@ cc.Class({
const quesBg = getSprNode("ques_bg"); const quesBg = getSprNode("ques_bg");
const quesBgSpr = quesBg.getComponent(cc.Sprite); const quesBgSpr = quesBg.getComponent(cc.Sprite);
quesBgSpr.type = cc.Sprite.Type.SLICED; quesBgSpr.type = cc.Sprite.Type.SLICED;
this.bgLayer.addChild(quesBg, 5); // this.bgLayer.addChild(quesBg, 5);
quesBg.y = this.canvas.height / 5; quesBg.y = this.canvas.height / 5;
this.quesPanel = quesBg; this.quesPanel = quesBg;
quesBg.opacity = 0;
quesBg.baseW = quesBg.width; quesBg.baseW = quesBg.width;
...@@ -1641,9 +1637,16 @@ cc.Class({ ...@@ -1641,9 +1637,16 @@ cc.Class({
if (!this.video) { if (!this.video) {
return; return;
} }
this.isFristPlayEnd = false;
this.video.remoteURL = this.video_url; this.video.remoteURL = this.video_url;
this.appearAnim(this.videoNode, 0.3);
this.appearAnim(this.videoNode, 0.3, () => {
this.toMaxVideo();
this.video.play();
});
}, },
...@@ -1652,7 +1655,7 @@ cc.Class({ ...@@ -1652,7 +1655,7 @@ cc.Class({
this.quesPanel.opacity = 0; this.quesPanel.opacity = 0;
this.refreshQuesLabel(); this.refreshQuesLabel();
this.refreshVideo(); this.refreshVideo();
// this.appearAnim(this.quesPanel, 0.3); this.appearAnim(this.quesPanel, 0.3);
this.isCanEmitBubble = true; this.isCanEmitBubble = true;
}, },
...@@ -2029,8 +2032,8 @@ cc.Class({ ...@@ -2029,8 +2032,8 @@ cc.Class({
if (!this.isFristPlayEnd) { if (!this.isFristPlayEnd) {
//首次结束 //首次结束
this.startTesting();
this.startTiming(); this.showTipRemoveCard();
this.isFristPlayEnd = true; this.isFristPlayEnd = true;
} }
...@@ -2898,6 +2901,8 @@ cc.Class({ ...@@ -2898,6 +2901,8 @@ cc.Class({
async changeNextQues() { async changeNextQues() {
this.endTesting();
this.isCanCheck = false; this.isCanCheck = false;
this.quesArrIndex ++; this.quesArrIndex ++;
...@@ -3058,19 +3063,25 @@ cc.Class({ ...@@ -3058,19 +3063,25 @@ cc.Class({
this.jumpBtn.active = false; this.jumpBtn.active = false;
}, },
appearAnim(node, time=1) { appearAnim(node, time=1, callback=null) {
node.active = true; node.active = true;
node.opacity = 0 node.opacity = 0
cc.tween(node) cc.tween(node)
.to(time, {opacity: 255}, {easing: "cubicIn"}) .to(time, {opacity: 255}, {easing: "cubicIn"})
.call(() => {
callback && callback();
})
.start(); .start();
}, },
disappearAnim(node, time=1) { disappearAnim(node, time=1, callback) {
node.active = true; node.active = true;
node.opacity = 255 node.opacity = 255
cc.tween(node) cc.tween(node)
.to(time, {opacity: 0}, {easing: "cubicOut"}) .to(time, {opacity: 0}, {easing: "cubicOut"})
.call(() => {
callback && callback();
})
.start(); .start();
}, },
...@@ -8302,6 +8313,7 @@ cc.Class({ ...@@ -8302,6 +8313,7 @@ cc.Class({
changeNextQuestion() { changeNextQuestion() {
console.log(' in changeNextQuestion') console.log(' in changeNextQuestion')
this.curQuestionIndex ++ ; this.curQuestionIndex ++ ;
this.setCurQuestionData(); this.setCurQuestionData();
......
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