浏览代码

Optional filter on getObjects

clementlandrin 9 月之前
父节点
当前提交
b3230406ce
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      hrt/prefab/Object3D.hx

+ 1 - 1
hrt/prefab/Object3D.hx

@@ -205,7 +205,7 @@ class Object3D extends Prefab {
 		Returns the list of all h3d.scene.Object created by this prefab (but not
 		Returns the list of all h3d.scene.Object created by this prefab (but not
 		the ones created by its children)
 		the ones created by its children)
 	**/
 	**/
-	public function getObjects<T:h3d.scene.Object>(c: Class<T>, filter : h3d.scene.Object -> Bool ) : Array<T> {
+	public function getObjects<T:h3d.scene.Object>(c: Class<T>, ?filter : h3d.scene.Object -> Bool ) : Array<T> {
 		var root = Object3D.getLocal3d(this);
 		var root = Object3D.getLocal3d(this);
 		if(root == null) return [];
 		if(root == null) return [];
 		var childObjs = Prefab.getChildrenRoots(root, this, []);
 		var childObjs = Prefab.getChildrenRoots(root, this, []);