Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
const { Pathfinding } = require('three-pathfinding');
const pathfinder = new Pathfinding();
const ZONE = 'level';
/**
* nav
*
* Pathfinding system, using PatrolJS.
*/
module.exports = AFRAME.registerSystem('nav', {
init: function () {
this.navMesh = null;
this.agents = new Set();
},
/**
* @param {THREE.Geometry} geometry
*/
init: function() {
this.pathfinder = new Pathfinding();
},