I have been following the beginner tutorials in the wiki and got a bit stuck on the https://wiki.jmonkeyengine.org/docs/3.3/tutorials/beginner/hello_animation.html one attempting to make the SkeletonDebugger work. After a while of tinkering with different things I managed to make it work by calling updateGeometricState() on the skeletonDebugger as a final step but I don’t understand why this worked or if am doing the correct thing.
So this is what I have (at the end of simpleInitApp, the rest of the code is exactly the same as the tutorial linked):
skeletonDebug = new SkeletonDebugger("skeleton", control.getSkeleton()); Material mat = new Material(assetManager, "Common/MatDefs/Misc/Unshaded.j3md"); mat.setColor("Color", ColorRGBA.Green); mat.getAdditionalRenderState().setDepthTest(false); skeletonDebug.setMaterial(mat); player.attachChild(skeletonDebug); skeletonDebug.updateGeometricState();
Could someone explain what is going on in updateGeometricState and if there is another thing am missing to make the skeleton debugger work?