void OnEnable() { instance = this; root_paht_ = Application.dataPath + "/"; nav_editor.editor_set_log_callback(nav_editor.default_unity_log); nav_editor.editor_init(); nav_editor.editor_set_nav_mesh_changed_cb(this.OnNavMeshChanged); //暂时按现有使用的类型 nav_editor.editor_set_nav_mesh_type(nav_editor.NavmeshType.NAVMESH_TILEMESH); }
void OnDisable() { nav_editor.editor_uninit(); instance = null; }