forked from Onek8/LNXSDK
24 lines
511 B
Haxe
24 lines
511 B
Haxe
package leenkx.logicnode;
|
|
|
|
#if lnx_navigation
|
|
import leenkx.trait.navigation.Navigation;
|
|
import leenkx.trait.NavMesh;
|
|
#end
|
|
|
|
class ReconstructNavMeshNode extends LogicNode {
|
|
|
|
public function new(tree: LogicTree) {
|
|
super(tree);
|
|
}
|
|
|
|
override function run(from: Int) {
|
|
#if lnx_navigation
|
|
var activeNavMesh: NavMesh = Navigation.active.navMeshes.get(inputs[1].get());
|
|
assert(Error, activeNavMesh != null, "No Navigation Mesh Present");
|
|
activeNavMesh.reconstructNavMesh();
|
|
#end
|
|
|
|
runOutput(0);
|
|
}
|
|
}
|