Foliage Painted On Foliage Deforms Incorrectly When Parented Landscape Is Sculpted

Hi! I am building an underwater scene with the landscape and foliage tools. Some coral foliage instances are placed on top of the rock foliage instances, and when I attempt to sculpt/modify other portions of the parented landscape, the coral jumps down to the landscape’s geometry and aligns with its normals, instead of the foliage it was painted on.

Is there a way to either disable the foliage alignment temporarily to allow me to work on the parented landscape, or set the coral foliage as a child of the rocks foliage?

Thank you in advance!

Micah

Unfortunately, this seems to be a bug in at least the Unreal 4.26 engine.

The engine allows you to place foliage instances on top of foliage instances via the filter option in the foliage editor, but then automatically deforms everything to the landscape when you directly access the landscape editing tools. The foliage affected has nothing to do with the foliage.OffGroundThreshold variable.

WORKAROUND: So, the workaround to my specific issue is to:

  1. select ANOTHER landscape,
  2. go into landscape editing mode,
  3. and then switch over to the landscape that needs to be sculpted.

The magical “initial foliage alignment function” will kick off on the other landscape, and not on the landscape with stacked foliages which you will switch over to.

NOTE: Now, when editing, ensure you are aware of your landscape’s component size. If you attempt to sculpt a component of your landscape with stacked foliage, at least for right now, 4.26 will perform that “initial foliage alignment function” and destroy your foliage painting inside that component region.

MISC: The invalid foliage collection (those instances that are too far out of alignment (z-index) with the landscape terrain) appears to be what is targeted, but that is not what is actually happening on the backend. Instead, this “foliage alignment function” runs across the active landscape when the landscape manager is initially activated having nothing to do with the foliage.OffGroundThreshold (invalid foliage) value.

I’ve submitted this as a bug to Unreal. Case # 00300244: Stacked/Child Landscape Foliage Not Aligning To Parent Foliage When Landscape Is Sculpted Via the Landscape Manager in 4.26

Another piece to add to this work around is to move all the stacked foliage to a separate level, and then when it deforms to the landscape, instead of the parent/root vegetation, make sure you do not save that separate level. Even though the vegetation is tied to a landscape in that separate level, the positions and rotations for all the vegetation is currently stored in whichever level the vegetation resides. Hope this helps someone!