Commit 665312e1 authored by yu's avatar yu

1

parent 8510c2f9
...@@ -66,6 +66,10 @@ export default class LayerBack extends cc.Component { ...@@ -66,6 +66,10 @@ export default class LayerBack extends cc.Component {
}); });
} }
playVoiceRunning() { playVoiceRunning() {
if(!this.img_npc_voice){
this.unschedule(this.playVoiceRunning)
return;
}
this.playVoiceCount++; this.playVoiceCount++;
let p1 = this.img_npc_voice.getChildByName('p1') let p1 = this.img_npc_voice.getChildByName('p1')
let p2 = this.img_npc_voice.getChildByName('p2') let p2 = this.img_npc_voice.getChildByName('p2')
......
...@@ -32,6 +32,10 @@ export default class ImgVoice extends cc.Component { ...@@ -32,6 +32,10 @@ export default class ImgVoice extends cc.Component {
this.schedule(this.playVoiceRunning, 0.3) this.schedule(this.playVoiceRunning, 0.3)
} }
playVoiceRunning() { playVoiceRunning() {
if(!this.img_npc_voice){
this.unschedule(this.playVoiceRunning)
return;
}
this.playVoiceCount++; this.playVoiceCount++;
let p1 = this.img_npc_voice.getChildByName('p1') let p1 = this.img_npc_voice.getChildByName('p1')
let p2 = this.img_npc_voice.getChildByName('p2') let p2 = this.img_npc_voice.getChildByName('p2')
......
...@@ -113,6 +113,10 @@ export default class LayerRecord extends cc.Component { ...@@ -113,6 +113,10 @@ export default class LayerRecord extends cc.Component {
this.schedule(this.playVoiceRunning, 0.3) this.schedule(this.playVoiceRunning, 0.3)
} }
playVoiceRunning() { playVoiceRunning() {
if (!this.layout_record) {
this.unschedule(this.playVoiceRunning)
return;
}
this.playVoiceCount++; this.playVoiceCount++;
let btn_play = pg.view.find(this.layout_record, 'btn_play'); let btn_play = pg.view.find(this.layout_record, 'btn_play');
let p0 = btn_play.getChildByName('p0') let p0 = btn_play.getChildByName('p0')
......
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