Making trees in jmonkey

Hello guys!

I’m new to jMonkey but studing java programming.

I’m making a game (ofc) and have trouble creating trees. I’ve used unity earlier when you can just drag-and-drop trees. Is there any way to do the same in Jmonkey?
If not, which is the best way?

I imported the jme test data package and saw that there was a tree in there, but how do i actually use it and place in into the terrain?

Two things:

  1. No, jME will not generate trees for you.
  2. Yes, you can add a model in your scene and place it somewhere.

Personal opinion: Don’t expect too much visual editing in jME, especially compared to unity. You have much more possibilities when you program.

1 Like
@m41q said: Two things: 1. No, jME will not generate trees for you. 2. Yes, you can add a model in your scene and place it somewhere.

Personal opinion: Don’t expect too much visual editing in jME, especially compared to unity. You have much more possibilities when you program.

  1. Okey! But how do I add a the tree from java test data package, if you know what i mean?

  2. How does everybody place trees into the scene in jmonkeyy? Am I the only one with problem? =P

  1. I personally do not know the java test data package too well. But I guess the trees are stored somewhere as .j3o files. That’s what you need to find.

  2. Two ways:

Either you add it via programming “assetManager.loadModel(”…");" and place it via “setLocalTranslation(…)”.

Or (that’s more what you want I guess): You can add the model in the scene via the SceneComposer.
However this is pretty basic jME stuff and can be easily found in the tutorials: SDK Tutorials
Take a look at the videos, Importing Models, Dragging and Dropping Nodes and Scene Composing especially.
(Tough everything else is gonna be useful sooner or later anyway.)

1 Like
@mrbanana said: How does everybody place trees into the scene in jmonkeyy?

My personal solution:
The standard SDK editor does not fulfill my requirements of placing many objects very fast, applying certain UserData and so on, so I have a own little jME world editor, which does exactly what I wants.

I think I saw a forum post about a more extensive scene editor somewhere, but it’s in an early stage and user contributed, so no ‘official jME development’ at the moment.

1 Like

http://hub.jmonkeyengine.org/forum/topic/simarboreal-formerly-tree-editor/

1 Like
@m41q said: 1. I personally do not know the java test data package too well. But I guess the trees are stored somewhere as .j3o files. That's what you need to find.
  1. Two ways:

Either you add it via programming “assetManager.loadModel(”…“);” and place it via “setLocalTranslation(…)”.

Or (that’s more what you want I guess): You can add the model in the scene via the SceneComposer.
However this is pretty basic jME stuff and can be easily found in the tutorials: SDK Tutorials
Take a look at the videos, Importing Models, Dragging and Dropping Nodes and Scene Composing especially.
(Tough everything else is gonna be useful sooner or later anyway.)

OK thank you very much for helping a Dummie :wink: I will look into it right away!
I’m making a noob version of “battlefield vietnam” in java and you will be the first one to get a copy of the game! :wink:

Many thanks!

@pspeed said: http://hub.jmonkeyengine.org/forum/topic/simarboreal-formerly-tree-editor/

Many thanks to you too! I will look at this as well! Really need all help I can get and you will have a copy of the game as well :wink:

Many thanks!