diff options
Diffstat (limited to 'scene/3d/navigation.cpp')
-rw-r--r-- | scene/3d/navigation.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/scene/3d/navigation.cpp b/scene/3d/navigation.cpp index 40666a60dc..5c8fe6bb67 100644 --- a/scene/3d/navigation.cpp +++ b/scene/3d/navigation.cpp @@ -129,7 +129,7 @@ void Navigation::_navmesh_link(int p_id) { C->get().B=&p; C->get().B_edge=j; C->get().A->edges[C->get().A_edge].C=&p; - C->get().A->edges[C->get().A_edge].C_edge=j;; + C->get().A->edges[C->get().A_edge].C_edge=j; p.edges[j].C=C->get().A; p.edges[j].C_edge=C->get().A_edge; //connection successful. @@ -368,7 +368,7 @@ Vector<Vector3> Navigation::get_simple_path(const Vector3& p_start, const Vector while(!found_route) { if (open_list.size()==0) { - // print_line("NOU OPEN LIST"); + //print_line("NOU OPEN LIST"); break; } //check open list @@ -550,7 +550,7 @@ Vector<Vector3> Navigation::get_simple_path(const Vector3& p_start, const Vector path.push_back(begin_point); - path.invert();; + path.invert(); } return path; @@ -730,20 +730,20 @@ Vector3 Navigation::get_up_vector() const{ void Navigation::_bind_methods() { - ClassDB::bind_method(_MD("navmesh_create","mesh:NavigationMesh","xform","owner"),&Navigation::navmesh_create,DEFVAL(Variant())); - ClassDB::bind_method(_MD("navmesh_set_transform","id","xform"),&Navigation::navmesh_set_transform); - ClassDB::bind_method(_MD("navmesh_remove","id"),&Navigation::navmesh_remove); + ClassDB::bind_method(D_METHOD("navmesh_create","mesh:NavigationMesh","xform","owner"),&Navigation::navmesh_create,DEFVAL(Variant())); + ClassDB::bind_method(D_METHOD("navmesh_set_transform","id","xform"),&Navigation::navmesh_set_transform); + ClassDB::bind_method(D_METHOD("navmesh_remove","id"),&Navigation::navmesh_remove); - ClassDB::bind_method(_MD("get_simple_path","start","end","optimize"),&Navigation::get_simple_path,DEFVAL(true)); - ClassDB::bind_method(_MD("get_closest_point_to_segment","start","end","use_collision"),&Navigation::get_closest_point_to_segment,DEFVAL(false)); - ClassDB::bind_method(_MD("get_closest_point","to_point"),&Navigation::get_closest_point); - ClassDB::bind_method(_MD("get_closest_point_normal","to_point"),&Navigation::get_closest_point_normal); - ClassDB::bind_method(_MD("get_closest_point_owner","to_point"),&Navigation::get_closest_point_owner); + ClassDB::bind_method(D_METHOD("get_simple_path","start","end","optimize"),&Navigation::get_simple_path,DEFVAL(true)); + ClassDB::bind_method(D_METHOD("get_closest_point_to_segment","start","end","use_collision"),&Navigation::get_closest_point_to_segment,DEFVAL(false)); + ClassDB::bind_method(D_METHOD("get_closest_point","to_point"),&Navigation::get_closest_point); + ClassDB::bind_method(D_METHOD("get_closest_point_normal","to_point"),&Navigation::get_closest_point_normal); + ClassDB::bind_method(D_METHOD("get_closest_point_owner","to_point"),&Navigation::get_closest_point_owner); - ClassDB::bind_method(_MD("set_up_vector","up"),&Navigation::set_up_vector); - ClassDB::bind_method(_MD("get_up_vector"),&Navigation::get_up_vector); + ClassDB::bind_method(D_METHOD("set_up_vector","up"),&Navigation::set_up_vector); + ClassDB::bind_method(D_METHOD("get_up_vector"),&Navigation::get_up_vector); - ADD_PROPERTY( PropertyInfo(Variant::VECTOR3,"up_vector"),_SCS("set_up_vector"),_SCS("get_up_vector")); + ADD_PROPERTY( PropertyInfo(Variant::VECTOR3,"up_vector"),"set_up_vector","get_up_vector"); } Navigation::Navigation() { |