It’s my second day developing interaction, and I believe I have created something awesome. I am combining shader-based interaction with physics. I will return tomorrow with some video samples. Using just the shader interaction was insufficient; I had to utilize an array, which required changing my entire shader because this method only supported one player at a time, so I had to make my foliage more physics-based. The performance cost is minimal since it uses one pivot. ![]()
It’s 99% complete; I just need to fix a few issues, such as preventing the bottom from moving for the physics interaction.
Just want to quickly mention I integrated cloth, and I’m excited to showcase the new features soon.
The reason I’m taking so long to showcase anything new is that I have developed several extra features, which I am currently fine-tuning. Some of the new features include camera perspective correction for billboard grass, additional appendage features, and improved cloth simulation for wind effects. I believe that with these enhancements, I’ll be able to rival The Vizual Engine.
Upcoming features 2.0:
All these features are finished and almost production-ready.
Camera perspective correction
Adjusting the camera perspective from a top view is useful for simple plane or low-poly grass; it also works on high-poly grass, as it reduces any odd visual effects.
Additional appendage features
It can be used on objects that hang from branches or bark. It adds random motion to these objects using random vertex color IDs. Examples can include anything tied to a rope, like cans, rocks, and other bodies.
Cloth simulation
Basically uses the same wind system but with extra settings specific for objects like cloth and flags.
I created a first preview video showcasing some of the new features. I’m currently cleaning up the project and optimizing it. Soon, I’ll be making a video on physics interaction as well. I apologize for the lag in the video; my PC underperformed during the recording for some reason, but the in-editor experience should be smooth like a baby.
The wind has been completely redesigned from the ground up, featuring a new and modern vegetation system based on global variables.
Features: Appendage, cloth simulation, wind motion in vector direction, storm mode, wind improvements, global variables, full terrain integration, perspective correction.
I ran into a pitfall with my physics interaction system: it doesn’t work with Unity’s terrain trees and plants because they’re instanced by the terrain and use a different collision type. To address this, I’ve created a workaround script that converts terrain vegetation into prefabs as clones. Note that this solution is best suited for small to medium-sized scenes due to performance considerations. The physics system is greate for prefab plants and props like flags, etc. Additionally, there’s an existing shader-based interaction that works with terrain, but it’s limited to a single player. To improve this, I’m implementing raycasting, similar to The Visual Engine, to support more robust interactions with multiple objects at a time.
Amazing work! I’m very excited to try out this latest version.
RE: tree colliders. Each project is likely to have a different implementation. I’m using GPU Instancer, and for this reason, I place colliders (without mesh renderers) in the scene hierarchy for collision. It sounds like your code would work without changes in this scenario.
I’m excited as well. This will be a huge and crucial update for the Toby Foliage Engine. Hoping it will make it more relevant.
I’m excited to share that I’ve successfully implemented multiplayer interaction, though with some limitations. The player limit is set to 12, as further expanding the shader and script complexity could impact performance and stability. After exploring and reverse-engineering The Vegetation Engine, I opted for a simpler approach. The interaction features are now production-ready, and I’m ready to begin wrapping up this project.
The Toby Foliage Engine - Updates:
Interaction Update 2.0.0
(Massive changes and complete asset overhaul)
- Basic player interaction (Shader + physics-based) —> Trees will also have physics integration. These features are still in the early version, so there will be drawbacks!

Wind system and shaders overall:
- Improved wind (Gentle phase).

- Wind Sway Intensity (Per material) —> Enables manual control over the intensity of plant swaying, addressing wind discrepancies between various plant types.

- Pivot Sway Intensity (Per material) —> Enables manual control over the intensity of tree pivot swaying, addressing wind discrepancies between various tree types.

- Improved specular for built-in and URP + Specular maps.

- Improved deferred translucency (Attempt to fix the deferred BI lighting glitch).

- Forward translucency for built-in.
- Fix a few script bugs.

- Improved custom GUI.

Other improvements:
- Add new assets and scenes from TTFEL.

- Fix the “Global Controller” lag.

- Add wind direction control via gizmo.

- Attempt to integrate the Unity terrain into the TTFE “Global Controller”.

- Research foliage wetness features.
- Add custom normals for trees via the shader.

- Research GPU instancing.
(Won’t be implemented
) - Create an interaction example scene.
(WIP) - Add flags and banners for showcasing physics interaction.

- Cloth examples.
- Additional tools: Material matcher and wind mask debugger.

- Full Physics interaction

- Player interaction via shader (12 players)

- Camera perspective correction

- Additional appendage features

- Cloth simulation

-__________________________________________________________________-
Current tasks:
- Optimizing and cleaning up the shaders.
- Forward translucency for built-in.
- Implement additional tools.
-__________________________________________________________________-
Upcoming features 2.0:
All these features are finished and production-ready.
Full physics interaction
Works on trees and plants with an unlimited number of interactors. Limitations: Doesn't work on terrain objects.
Multiplayer shader interaction
Works on all plants, including terrain objects. Limitations: Only 12 interactors max are supported.
Simple player interaction
Works on all plants like the previous interaction, but with a more realistic simulation. Limitations: Only works with one interactor.
Preview of the Interaction features. Unfortunately, after further investigation, the performance for multiplayer interaction was horrid: 20fps out of 130 just by running the script by itself. I tried reverse engineering the Vegetation Engine, but the custom Expressions in Amplify Shader Editor kept failing to compile. I hate to be the guy saying I wasn’t able to make it work, but here we are. For now, this feature won’t be included or postponed for a future update.
Multiplayer shader interaction (Won’t be implemented for now
)
Works on all plants, including terrain objects. Limitations: Only 12 interactors max are supported.
From here on out, I will focus on further optimization, cleanup, and getting the Update ready for publishing.
Just in case there was a misunderstanding in my last post, I want to let everyone know that these two features will be included, and the first one works with unlimited interactors, but it doesn’t support terrain:
Full physics interaction
Works on trees and plants with an unlimited number of interactors. Limitations: Doesn't work on terrain objects.
Simple player interaction
Works on all plants like the previous interaction, but with a more realistic simulation. Limitations: Only works with one interactor.
But not the multiplayer shader interaction.
![]()
Expect the update to be released this month, but if delayed, it will be in September.
This asset is amazing! Congratz!
I’m having a little problem though… I cant figure out how to light the grass in realtime, it goes through the mesh and lights only the ground beneath. Im using the grass as painted details in the terrain editor.
Any ideia on what am I missing?
Thanks in advance.
That’s strange, it should normally work. Are there any console errors? Are you using deferred or forward rendering, and which pipeline are you using? Normally, the shaders work as intended with point lights.
It might be helpful to add a directional light in the scene and set its intensity to 0. This could be a potential glitch. From your image, it appears that the trees and other plants are not receiving any light. Perhaps there is an issue with your terrain shader that needs to be addressed?
Im using the Built-in pipeline. In the “deferred or forward” question, im using the default “Use Graphics Settings”, cause im new to dev.. so I have no idea what it means haha.
I placed two grass prefabs manually (not painting detail) and it works. The problems seems to be somewhere in the terrain paint details thing.
It works when changed to Deferred! haha Thanks!
I’m glad. Use Defered, it’s also faster
![]()
I finished all the features, cleaned up, and optimized; however, the optimization didn’t yield good results, so version 2.0 will be a bit more expensive than previous versions in some cases because the shaders became more bloated with features. Therefore, I will also provide optimized mobile versions of the shaders as well.
Publishing date getting closer! ![]()
After a long break, the update is finished and the package is spotless. Now working on converting to URP and HDRP. Oh, by the way, I added a last-minute wetness feature!
URP support 100%, and HDRP 98% finished. V2.0 Update to be released in a few business days, possibly this week!

