fix haptics for dot beats
This commit is contained in:
@@ -672,7 +672,7 @@ AFRAME.registerComponent('beat', {
|
||||
}
|
||||
|
||||
// Notify for haptics.
|
||||
this.el.emit(`beatcollide${this.hitHand}`, null, true);
|
||||
this.el.emit(`beatcollide${hand}`, null, true);
|
||||
|
||||
// Sound.
|
||||
this.el.parentNode.components['beat-hit-sound'].playSound(
|
||||
@@ -688,7 +688,7 @@ AFRAME.registerComponent('beat', {
|
||||
|
||||
if (saberBoundingBox.intersectsBox(beatBoundingBox)) {
|
||||
// Notify for haptics.
|
||||
this.el.emit(`beatcollide${this.hitHand}`, null, true);
|
||||
this.el.emit(`beatcollide${hand}`, null, true);
|
||||
|
||||
// Sound.
|
||||
this.el.parentNode.components['beat-hit-sound'].playSound(this.el);
|
||||
|
||||
@@ -147,7 +147,7 @@
|
||||
bind__saber-particles="enabled: isPlaying"
|
||||
bind__trail="enabled: isPlaying"
|
||||
haptics="events: mouseenter; dur: 35; force: 0.075"
|
||||
haptics__beat="eventsFrom: #beatContainer; events: beatcollide{{ hand }}; dur: 80; force: 0.2"
|
||||
haptics__beat="eventsFrom: #beatContainer; events: beatcollide{{ hand }}; dur: 80; force: 0.3"
|
||||
haptics__draw="events: drawblade; dur: 750; force: 0.025"
|
||||
haptics-saber
|
||||
haptics-wall
|
||||
|
||||
Reference in New Issue
Block a user