armory/Sources/armory/logicnode/GetMeshNode.hx

19 lines
310 B
Haxe
Raw Normal View History

2017-04-11 11:28:22 +02:00
package armory.logicnode;
2017-11-20 15:16:52 +01:00
import iron.object.MeshObject;
2017-04-11 11:28:22 +02:00
class GetMeshNode extends LogicNode {
2019-12-19 23:54:08 +01:00
public function new(tree: LogicTree) {
2017-04-11 11:28:22 +02:00
super(tree);
}
2019-12-19 23:54:08 +01:00
override function get(from: Int): Dynamic {
var object: MeshObject = inputs[0].get();
2017-04-11 11:28:22 +02:00
2017-09-20 14:27:45 +02:00
if (object == null) return null;
2017-04-11 11:28:22 +02:00
return object.data;
}
}