Commit 36ffd349 authored by 范雪寒's avatar 范雪寒

feat: autoPlay

parent 7577d3c2
...@@ -63,7 +63,7 @@ export default class SceneComponent extends MyCocosSceneComponent { ...@@ -63,7 +63,7 @@ export default class SceneComponent extends MyCocosSceneComponent {
} }
} }
if (this.data.audio && this.data.audio !== '') { if (this.data.audio && this.data.audio !== '' && this.data.autoPlay) {
let girl_ske = cc.find('Canvas/girl_ske').getComponent(dragonBones.ArmatureDisplay); let girl_ske = cc.find('Canvas/girl_ske').getComponent(dragonBones.ArmatureDisplay);
girl_ske.playAnimation('speak', 0); girl_ske.playAnimation('speak', 0);
this.audioId = this.playAudioByUrl(this.data.audio, () => { this.audioId = this.playAudioByUrl(this.data.audio, () => {
......
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