# Nanite Foliage with wind/sway material effects placed via procedural volumes (UE 5.1.0) may seesaw/sway together with all other foliage in the same procedurally generated volume

**URL:** <https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655>\
**Category:** Community & Industry Discussion\
**Tags:** bug, workaround, unreal-engine, UE5-1\
**Created:** [November 18, 2022, 11:55am UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655 "2022-11-18T11:55:03Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![SoraKagami](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SoraKagami](https://forums.unrealengine.com/u/SoraKagami)\
**Post date:** [November 18, 2022, 11:55am UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655/1 "2022-11-18T11:55:03Z")

</div>

I would like to share information for a not-quite-a-bug issue with Nanite foliage in Unreal Engine 5.1.0 (release) and the workaround that worked for me, so that anyone else with a similar issue might be able to benefit from it.

**Issue**  
Nanite-enabled Foliage with wind/sway (material) effects placed via procedural volumes in UE 5.1.0 may end up “swaying” together with all other foliage in the same procedurally generated volume.

**Example video**  
[https://www.youtube.com/watch?v=UD6ydvczpTY](https://www.youtube.com/watch?v=UD6ydvczpTY)

**How to replicate**

1. Install a marketplace asset such as one of the Brushify packs containing foliage or use any in which the foliage utilizes the “World Position Offset” value in a material to create the wind/sway effect.
2. Create a large procedural foliage volume and populate with foliage from 1. above.
3. Make sure the wind/sway effects have been enabled in the material for the foliage from 1.
4. If the material was correctly setup, the foliage will behave as they have done so since Unreal 4.2x → 5.0.3.
5. If the foliage “rocks” or seesaws as one large “unit” spanning the procedurally generated volume, then this is the issue detailed above.

**Workaround**  
The workaround I used to fix this effect after updating to UE 5.1.0 was to modify Brushify’s `MF_TrunkSway`:  
Inside the comment section “Objects Pivot Point”, the `TransformPosition`’s `Source` value needs to be changed from `Local Space` to `Instance & Particle Space`.

**Note**  
**This “bug” is not unique to Brushify foliage and may affect other foliage assets that implement wind/sway effects** using the `World Position Offset` input for materials where the pivot point for the sway effect was obtained using `Local Space`. This did not appear to be an issue for UE 4.2x → 5.0.x.  
Brushify was what I used for my testing and debugging.

I am unsure if this fix is the correct way to go about it, however appears to have done the trick.

Good luck!

---

<div class="post-metadata">

**Author:** ![SoraKagami](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SoraKagami](https://forums.unrealengine.com/u/SoraKagami)\
**Post date:** [November 18, 2022, 12:44pm UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655/2 "2022-11-18T12:44:31Z")

</div>

Summary of workaround:

Modify the material’s `TransformPosition` ’s `Source` value from `Local Space` to `Instance & Particle Space`.

---

<div class="post-metadata">

**Author:** ![Bromar9238327](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Bromar9238327](https://forums.unrealengine.com/u/Bromar9238327)\
**Post date:** [November 19, 2022, 1:41am UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655/3 "2022-11-19T01:41:41Z")

</div>

i fixed by finding an objectpivotpoint function and changed the transform from particle source to absolute world space

 ![Screenshot 2022-11-18 203955](https://d3kjluh73b9h9o.cloudfront.net/original/4X/9/d/c/9dc2de1fd2031b14139d96b71e2131ab55ce8726.png)

---

<div class="post-metadata">

**Author:** ![SoraKagami](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SoraKagami](https://forums.unrealengine.com/u/SoraKagami)\
**Post date:** [November 19, 2022, 4:19am UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655/4 "2022-11-19T04:19:00Z")

</div>

Nice find, thanks for sharing!

Looks like there are multiple possible causes for these types of foliage problems and they all revolve around changes to how coordinates are returned from base UE 5.1 functions/etc.

[Edit]:  
**My guess for what may have caused the glitch/bug:**  
When enabling nanite for foliage any procedurally generated foliage volumes become treated as a single unit, at least for the foliage material. “Local Space” coordinates will then point to the procedurally generated volume itself instead of each individual foliage asset.

---

<div class="post-metadata">

**Author:** ![AmadJunaid](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/amadjunaid/32/604650_2.png) [@AmadJunaid](https://forums.unrealengine.com/u/AmadJunaid)\
**Post date:** [December 10, 2022, 1:44pm UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655/5 "2022-12-10T13:44:25Z")

</div>

thanks… that helped a lot… lost 3 hours trying to fix the rotation function

---

<div class="post-metadata">

**Author:** ![YYTSSLN](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/yytssln/32/547866_2.png) [@YYTSSLN](https://forums.unrealengine.com/u/YYTSSLN)\
**Post date:** [January 29, 2023, 9:56pm UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655/6 "2023-01-29T21:56:52Z")

</div>

Thank you, I finally solved it

---

<div class="post-metadata">

**Author:** ![TwitchTorchBunny](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@TwitchTorchBunny](https://forums.unrealengine.com/u/TwitchTorchBunny)\
**Post date:** [March 5, 2023, 6:01pm UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655/7 "2023-03-05T18:01:43Z")

</div>

Thanks alot m8 for saving me a big headache \<3

---

<div class="post-metadata">

**Author:** ![blyxzen](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/blyxzen/32/1040549_2.png) [@blyxzen](https://forums.unrealengine.com/u/blyxzen)\
**Post date:** [April 10, 2023, 5:50pm UTC](https://forums.unrealengine.com/t/nanite-foliage-with-wind-sway-material-effects-placed-via-procedural-volumes-ue-5-1-0-may-seesaw-sway-together-with-all-other-foliage-in-the-same-procedurally-generated-volume/693655/8 "2023-04-10T17:50:47Z")

</div>

For anyone using Dreamscapes, I was able to fix the issue by going into `MF_FoliageWind_Sway` and for every `ObjectPivotPoint` node (there are 2), connecting the `Mesh Particle Pivot Location` instead of `Object Pivot Location`. This accomplishes the same thing as Bromar’s fix, without altering engine content.
