Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
A-Frame Deadly Component
import Component from '../core/component';
export default class Deadly extends Component {
init() {
this.el.addEventListener('collide', e => this.onCollision(e));
onCollision(event) {
event.detail.body.el.emit('death', event);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment