toggle off trail / bad beats when not playing

This commit is contained in:
Kevin Ngo
2018-10-13 08:57:27 -07:00
parent 40d99e5df9
commit ec306a80ae
2 changed files with 14 additions and 8 deletions

View File

@@ -63,6 +63,10 @@ AFRAME.registerComponent('trail', {
this.enabledTime = this.el.sceneEl.time;
this.mesh.visible = false;
}
if (oldData.enabled && !this.data.enabled) {
this.mesh.visible = false;
}
},
tock: function (time, delta) {