Model mouse pick


I have a class that extends Node that loads a model file using

JmeBinaryReader.loadBinaryFormat(this, …)

This is ok, as I can display the model and add some functionality to the class.

Now, I want to be able to pick this class using mouse pick, but as PickData returns a Geometry I cannot get the Node back. And since I want to load a model from a file, I have to extend Node and cannot extend Geometry.

So: what would be the way to extend Node to add functionality, load a model and be able to be picked using mouse picking?


Node doesn't contain any vertex data, so you can't pick it. Just getParent() on the geometry you find when picking.

it was easier than I thought… thanks