Explorar el Código

make lib public + add getPath()

Nicolas Cannasse hace 2 meses
padre
commit
94d83b9f63
Se han modificado 1 ficheros con 5 adiciones y 1 borrados
  1. 5 1
      h3d/prim/HMDModel.hx

+ 5 - 1
h3d/prim/HMDModel.hx

@@ -8,7 +8,7 @@ class HMDModel extends MeshPrimitive {
 	var dataPosition : Int;
 	var indexCount : Int;
 	var indexesTriPos : Array<Int>;
-	var lib : hxd.fmt.hmd.Library;
+	public var lib(default,null) : hxd.fmt.hmd.Library;
 	var curMaterial : Int;
 	var collider : h3d.col.Collider;
 	var normalsRecomputed : String;
@@ -31,6 +31,10 @@ class HMDModel extends MeshPrimitive {
 			this.colliderData = Collider.fromHmd(this);
 	}
 
+	public function getPath() {
+		return lib.resource.entry.path;
+	}
+
 	override function hasInput( name : String ) {
 		return super.hasInput(name) || data.vertexFormat.hasInput(name);
 	}