Example usage for com.badlogic.gdx.ai.pfa.indexed IndexedAStarPathFinder IndexedAStarPathFinder

List of usage examples for com.badlogic.gdx.ai.pfa.indexed IndexedAStarPathFinder IndexedAStarPathFinder

Introduction

In this page you can find the example usage for com.badlogic.gdx.ai.pfa.indexed IndexedAStarPathFinder IndexedAStarPathFinder.

Prototype

public IndexedAStarPathFinder(IndexedGraph<N> graph) 

Source Link

Usage

From source file:com.mygdx.game.pathfinding.NavMesh.java

License:Apache License

public NavMesh(Model model) {
    btTriangleIndexVertexArray vertexArray = new btTriangleIndexVertexArray(model.meshParts);
    collisionShape = new btBvhTriangleMeshShape(vertexArray, true);
    raycastCallback = new NavMeshRaycastCallback(navMeshRayFrom, navMeshRayTo);
    raycastCallback.setFlags(btTriangleRaycastCallback.EFlags.kF_FilterBackfaces);
    graph = new NavMeshGraph(model);
    pathFinder = new IndexedAStarPathFinder<Triangle>(graph);
    heuristic = new NavMeshHeuristic();
}