Skip to content
This repository was archived by the owner on May 12, 2020. It is now read-only.

Conversation

@yvt
Copy link

@yvt yvt commented Dec 20, 2015

Now nodes can be built and passed around as a single object, and no name collisions would occur.

jsonLoader.load( 'meshes/level.nav.js', function( geometry, materials ) {
    var zoneNodes = patrol.buildNodes(geometry);

    // Set the player's navigation mesh group
    playerNavMeshGroup = zoneNodes.getGroup(player.position);

    // Calculate a path to the target
    calculatedPath = zoneNodes.findPath(player.position, target.position, playerNavMeshGroup);
}, null);

The old API is preserved for compatibility.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant