Can I control a MultiMeshInstance via a weight map? And how? | 3D

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Good-Boi McLovin

Not sure if this is an engine question or a project question? Engine I guess?

Sorry, anyways, it’s as stated above I have a 3D project, I have various tree types and I aim to fill an area with said trees, the area is detailed with hills, divots, and whatnot. So I’m wondering if it’s possible to control where on my environment I can instance my trees. Say via a black and white weight map.
For example; I wish to fill just the outer edges of my environment with tree 1 and not have any appear in the middle, then say fill only the middle with tree 2 with a separate MultiMeshInstance. Is it possible to do so via some sort of weight map? If so is there a node structure for this, preferably not coded tho I could learn to do so.

The only other solution I can think of is having a flat plane that sits just under the map in the shape I want, but that could be tedious with all the hills and valleys I have to make sure no trees float in the air or are stuck too deep into the ground.

Any ideas or help would be greatly appreciated, thank you! Also, I’m really loving Godot so far, far nicer than Unity or Cryengine and Unreal, I am excited for more powerful features in the future.

:bust_in_silhouette: Reply From: Good-Boi McLovin

I found the answer myself, thank you! I’ll post them here once I get ahold of the links for anyone who is wondering the same question.

Did you find a solution? I’m also interested in this.

Dechows | 2021-04-01 13:47

Yes! Sorry I forgot to post them ive been busy with work and with my game, there are two main plug-in solutions for this problem:
The first is the biome generator plug-in which requires the HTerrain plug in which is a good plug in anyways and should be used regardless:
https://youtu.be/5i0EUC0voao (he has the download link in video desc)
However I found this solution to be really awesome in concept but a bit difficult to use and setup with the current version. This is however weight based using HTerrain SPLAT painting.

The better current solution if you ask me is the scatter plugin:
GitHub - HungryProton/scatter: Godot engine addon to randomly fill an area with props or other scenes
This plug-in allows you to draw an area and randomly fill it with selected meshinstance objects or even scenes. While its not weight map based in my opinion it is a far better solution and has a lot of control and setup and is relatively easy to use. Video here describing its uses:
https://youtu.be/MB3Vz6JFAOA

Good-Boi McLovin | 2021-04-01 18:02

Thank you. Scatter seems like a pretty nice plugin for a bunch of other stuff also.

Although I still hope that Godot will, at some point, get support for full control of arbitrary properties of MultiMeshInstances and/or particles by a texture, similar to what Blender has.

Dechows | 2021-04-01 18:07

Yah I completely agree, technically it does but you’d have to add it manually to Godots source code, so ill just hold out and use plug-ins people have developed. Scatter really is good though, you can do a lot.

Good-Boi McLovin | 2021-04-01 18:22