-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Animation tutorial refers to the deprecated code that no longer works #1833
Comments
Thanks for getting in touch. We're aware that the Wiki is out-of-date and the code listed in the animation tutorial doesn't work with recent versions of JMonkeyEngine. The deprecated classes and methods still work in general. However, the structure of the 3-D model used in HelloAnimation changed as of JME version 3.3. That's what causes the There's an updated version of HelloAnimation.java available from GitHub, which should work for you: https://github.com/jMonkeyEngine/jmonkeyengine/blob/v3.5/jme3-examples/src/main/java/jme3test/helloworld/HelloAnimation.java For JMonkeyEngine support, the place to go is our Discord forum: https://hub.jmonkeyengine.org/ |
Note this issue is effectively a duplicate of #1402 and jMonkeyEngine/wiki#96 |
Thanks, will look that up. I still think that it'd be an improvement if deprecated code is treated as such: as long as old entities are in place AND behavior gets changed and this is exactly what's happening, e.g. if old approach is not meant to be working anymore but old entities are still kept intact - I guess to ease the migration without compilation errors, I'd still suggest changing the behavior of |
There can be a hundred different unexpected reasons that getControl() might return null. Perhaps the real issue is that the tutorial is not defensive about the fact that getControl() may return null... and in cases where it has nothing to do with AnimControl versus AnimComposer. |
Makes sense, thank you for responding so quickly. Closing. |
I'm using latest stable release of jmonkeyengine, specifically
3.5.2-stable
. While reading latest documentation - https://wiki.jmonkeyengine.org/docs/3.4/tutorials/beginner/hello_animation.html I tried to run relevant sample code, but it turns out:control = player.getControl(AnimControl.class);
.Minimalistic example:
Also I believe I referred all required libraries: jme3-core, jme3-desktop, jme3-lwjgl, jme3-testdata, jme3-plugins
All libraries imported from maven central, all of
3.5.2-stable
version.I'd like to suggest to (1) update documentation, (2) change engine code so that deprecated entities are handled in a distinct manner, e.g. by throwing
UnsupportedOperationException
or the like in the relevant places.The text was updated successfully, but these errors were encountered: