What should I use to make/edit maps?

Hi all,

I’m looking for a good editor to create large worlds that I can import into jMonkeyEngine3, that can have things like models and textures, as well as foliage like trees, etc.

Since the jMonkeyEngine SDK’s terrain editor really isn’t that effective for large and detailed worlds, I was wondering what you all use to create good terrains.

Currently I’m using the L3DT Terrain editor,

Which looks absolutely great, until I start coming across problems:

  1. Almost impossible to have grass, trees, etc.
  2. Impossible to add extra models.

For example, I have been adding runways into the game.

However, I am placing each of them by code, whereas the ideal situation would be to have a terrain editor where I can view the terrain and place certain objects onto it.

And then due to the inability to place objects into the world, I get issues like this:

Again, this is there placing things by code becomes an issue - The hangars are all separate models, the barriers are separate models, and all of them have separate textures too. Loading them into the game by code would be a mess.

In the end, I’m trying to find a terrain editor that can have great terrain (like L3DT). I could even import a terrain from L3DT if I wanted) that also allows me to place objects (such as trees, foliage, runways, etc), and that I can import into JME.

What do you people all use, and what would you recommend me to use to make/edit my terrains?

I would be fine with paying some money if I had to, but upward of $30 is getting a bit into the “no-go” zone.

Blender 3D, Blender I love Blender :smiley:
You can make there everything if you know how. Biggest problem with terrain be probable LOD optimization.

Blender is mostly just for models though, and does not have any easy way to add things like trees and foliage, nor any easy way just drag-and-drop a ton of models in.

As you say, LOD optimization is also the issue there.

For trees you make particle emitter - apply modifier - export. Or spawn there empties and replace it in code (theory).
Maybe there are some programs where you have some tree brush (if you setup weight paint you get it in blender^^) etc but usually you need good exporter that you get the same in game format (using instances etc).
I don’t know any “map maker”.

As for the trees you really do not need those in the terrain editor at all. Most games that are open worldish that have trees generate the trees with code. It would be impossible for instance or I should rather say very tedious to actually hand place tons of trees and brush for forestry and fields so they pragmatically generate them. This is why most game boxes mention speed tree that is exactly what it does for them.

As for placing objects like runways typically what would happen is the terrain is generated and then imported into the scene then the objects are manually placed with the tools the company uses ie their engines tools. For instance in UE4 you would load the terrain into the scene then manually place the objects in their locations using the scene editor in the package.

I highly doubt you will find one tool to do it all simply because tools need to be specialize otherwise the projects are too unmanageable.

Not really an answer to the question but if you want to see an example of dynamic tree placement based on the underlying mesh, you can take a look at the IsoSurfaceDemo.

…all of those trees are randomly placed with no knowledge about the world other than water level and mesh. The grass is placed similarly.

The basic approach is to find triangles that face the proper direction and check locations against a plot function. (I use some combined noise textures but anything works.)

This app uses basically the same placement algorithm but has saner terrain:

For what it’s worth, the trees are SimArboreal trees:

…which exports to j3o and has configurable LOD and so on.

I use instancing in the app for performance.

Don’t know if any of that is useful or not but maybe it inspires something.

Seems too complicated for me, as I honestly have no clue as to what you’re doing there. That said, that actually looks good, but I honestly have no idea how I would achieve graphics that are anything like what you have there.

Well, if you get curious… all of the source code is available (except for Dragonfly Odyssey but it’s all based on the SimArboreal stuff.)

You don’t have to start at the end, though. Find a tree model you like (or use one of SimArboreal’s exported trees… they load just like any j3o except you have to have a jar in your project dependencies to get the LOD and stuff.)

When you load one of your terrain chunks, use an algorithm to place trees down. It could be based on some kind of noise image sampled. (if( sample.r > 0.8 ) put tree here)) and probably takes surface normal into account and so on.

The point is to try to automatically place stuff like that as much stuff as possible.

Anyway, I don’t know how you are getting the cool looking terrain into your game so I can’t really comment further. Depending on how, you might be able to drop some IsoSurface code in directly just to place trees and grass.

Sighs In my opinion it doesn’t look that cool, which is why I’m looking for ways to make it better.

The terrain is imported from the L3DT terrain editor, as 8x8 chunks, which are all .obj meshes.

[quote=“pspeed, post:8, topic:35525, full:true”] Depending on how, you might be able to drop some IsoSurface code in directly just to place trees and grass.
I’m not sure quite which code I’m meant to be copying. I’ve taken a look at the GitHub link you provided, but I can’t actually see at the moment what is adding trees or grass or anything like that.

Yeah, I didn’t leave enough breadcrumbs. Some of it’s easier or harder depending on how much of the whale you want to swallow.

For example, if you are willing to use the Pager library to load your terrain chunks (don’t know how they are organized or if you have a lot of them that would need paging or whatever) then the Grass and Tree zones will just drop in on top of that with little fuss. I can provide sample code in that case.

…else reusing my code for anything other than reference would be possible but more surgical.

It’s the plot zones that do the work: IsoSurface/src/main/java/com/simsilica/iso/plot at master · Simsilica/IsoSurface · GitHub

…but they are written to plugin to the pager. So if the bottom layer (or outer zone grid) of the pager was something simple that just loaded your terrain chunks, then these guys could be drop-in children on top of that.

As for stuff like your airfield… one stop-gap option would be to edit it together on a flat plane in the SDK’s scene editor and then just save the full configuration as a j3o that you can load and place in your game. Not ideal but easier than trying to place it all by code. I think you can even use asset link nodes to share the models and stuff.

The funny thing is that I was just doing that already:

Problem is, I don’t know how to add the textures onto the objects. In all the tutorials the textures appear to be “just there”, and as all objects have different textures, I’m not sure how to apply them all.

I think the problem with this is that I feel way over my head - I am being dropped into a ton of code where I’m not really sure what it’s doing or exactly what it’s purposes is in the overall picture. I’ve only been working with JME for two months, so I don’t know a lot of the method calls you’re using or a lot of what you’re doing.

Of course, I don’t expect you to hold my hand through the whole process - You have other things to do. However, let’s say I was going to code my own system for adding grass and trees into the world - What is some advice or general rules that I should follow to achieve that?

It would be great to have some simple examples to use the Pager and the SimArboreal systems (by separate or in conjunction). They both look quite powerful but dig into isosurface to find out how to use them can be a little bit overwhelming. To be honest, I didn’t dig too much but is the impression It gives to me each time I say “ok, lets take a look to see if this time I get it” xD. Maybe adding the fast basis to use them on their respective wiki would be enough (or giving simple examples) to help a lot.

Yeah, so maybe at this point in your learning, eating the whole whale is a bit much. General advice is to use batching for grass and instancing for trees… when those two terms make more sense then you’ll be ready to take those challenges on. You are probably well on your way there already.

As to your textures, something must have happened in the export or how they are defined in blender. You can add them after the fact by selecting the geometry in the scene editor and generating the material. (It’s one of the material options in the property editor for the object.) Then you can edit the material file to give it a texture.

…probably better if you can figure out why they didn’t export in the first place. I don’t have much advice to offer there.

I will try to provide some simpler examples at some point for the other stuff. Even the simple form of paging might be a big much to swallow right now. How many terrain files do you have at this point? How are they organized?

[quote=“pspeed, post:14, topic:35525, full:true”]How many terrain files do you have at this point? How are they organized?
Currently every terrain file has a megatexture. Not because I am a noob, but because the tiled textures looked really bad.

Which is maybe because I’m a noob.

Anyway, my map is like this:

I then load chunks as a Spatial, and then add them to the node. If they get too far away, I remove them from the node.

A simple form of paging might be a bit hard to follow, but I would be interested to actually get to know something about it.

Cool. I’ll see if I can write up an example of some kind (probably just in pseudo code) the next time I can come up for air. If you don’t hear from my in a week or so then bump this thread.