ARTnGame presents the next major asset, InfiniGRASS.
The system can paint ultra detailed static or dynamic grass everywhere, without any limit in shape, form, shader or placement surface. It is possible to apply any amount of grass anywhere, on objects or terrain. Based on a custom multithreaded LOD and AI system for ultimate performance and adaptability, from higher end systems to mobile (mutlicore is recommended).
The grass may also be grown dynamically in real time and the player can interact with it, by chopping or stepping on it.
The core system works on all platforms, but the grass shaders that will initially come with the pack are SM3.0 and the mobile varieties will come as a bonus later.
Initially the system will come with 6 grass types and shader varieties (vertex and transparent based), an editor to place grass, real time placement option and a complete fence creation and rocks placement system.
FAQs
InfiniGRASS FAQs (WIP)
Q: Are there video tutorials for the system usage ?
A: Yes, i have multiple tutorials that can be found in the follwong playlist (use the link and the rest of tutorials are on the right side panel of youtube playlist)
https://www.youtube.com/watch?v=l-apm8ZcZuc
Q: I use lower scale in grass than the default 20 and get strange waving motion. Is this adjustable ?
A: Use the “Stop motion distance” variable in brush settings, after pressing on one of the icons (the slider will change the value only for this brush) and set it lower or to zero to see if fixes the motion issue. Then you can use much lower values in this too.
Q: On low grass, any setting in Stop Motion distance will still give a big Y displacement on lower world scale.
A: There is a new version of the low grass shader, that can adjust a max height in the Y disaplcement to fix the issue. Available on PM request immediately.
Q: The grass wind is too high and cannot be regulated, sliders do not work
A: The system will work after adding wind zone, this is essential as it grabs the windzone direction to regulate the wind
Q: The wind effect is still on after setting wind to zero
A: Set also Turbulnce to zero to get a complete stop of the windy motion
Q: Can i fine tune the wind and turbuelnce stranghts per material, to regulate for the various grass types ?
A: This is possible using the various on material parameters (not available through the Grass Manager). The “Wave control x axis” & “Wave control y axis” will enchance the wind effect on the relevant direction over the global wind strength. The “Waves” and “Time” vectors will regulate the frequency of grass turbulence and the “Buldge Scale_copy” variable is an offset to the global Turbulence strength. The Grass Manager regulated variables are “Buldge Scale” and “Ocean center”, which pass the global paramaters to the shader.
Q: I want to paint with left mouse button, because i use a pen or the right mouse rotates the view
A: There is a patch available immediatly on PM request to allow painting with left mouse button. To avoid rotation of the camera during right mouse painting, while holding the right mouse down, also press the left once, this will lock the camera rotation until the right mouse is de-pressed.
Q: What is the right way to use a lower scale in the world ?
A: First set the World Scale and then choose a brush icon to setup for that world scale as first step before planting. The “World scale” does not do any actual scaling, it only scales the preset paramaters when a brush icon is pressed to be better suited for the selected world scale. Also the World Scale will affect the maximum possible density value in the Mass Plant system (this is done to avoid using big densities in very big areas, as in v1.x this can make Unity unstable). In v2.0 this is solved by not growing the actual grass all at once, so any number of maps can be planting in one Mass Plant application directly.
Q: Is there a latest demo for the v2.0 of the system ?
A: The latest demo can be found in the follwoing link
InfinigRASS v2.0 - Sky Master v4.0 Full volume clouds demo:
STREAMING E1d PC DEMO FINAL6f_test7a1_PC.rar - Google Drive
Q: Mass Plant does not seem to work.
A: First make sure the density mentioned in the Grass Manager is above zero. If it is zero increase mass plant density slider and also change the World Scale to allow more density in the slider. The two corners must be above the ground where the planting will happen and also corner B must have higher X and Z axis coordinates than corner A (otherwise corner B will return to corner A)
Q: The grass is not planted if there is a collider in the scene over the terrain.
A: The grass uses a raycast distance parameter while planting to determine where the raycast to plant will start from. Regulate this parameter to the grass raycast starts lower or inside the object with collider (the collsions happens on top or bottom surface of the box collider for the example, so having the low part below ground and top part high, will still allow to plat grass with a raycast that starts low above ground to be below the top and above the bottom which is below the impact plant point.
Q: The results in the pics look better than the grass system when used in my game.
A: The pics use the same system, so it is possible to get the exact same look, the difference is because i also use my other packs (mainly Sky Master ULTIMATE - Sky Master ULTIMATE: Volumetric Skies, Clouds & Weather | Particles/Effects | Unity Asset Store) to regulate the lighting, volumetric lighting and fog and shadowing, plus image effects to get the perfect look. For every user that has both assets, i can also send scenes prepared with both as a more complete demo to work with as base, on PM request.
Q: Can the system be used on mobile ?
A: Many users have used it on mobile with various results, the system has a SM2.0 compatible shader for the older devices and a lot more enchancements will come in v2.0 that will further help mobile (batched billboards, pooling, zero in game batching, much less allocations etc)
Q: The grass vanishes very close to the player-camera
A: The shader has a fade option that makes the grass fade out in a defined distance from the camera. This is defined using the “Grass Fade Distance” slider in the brush settings, for the currently selected grass brush icon.
Q: The grass is very slow and performance is taking a big hit
A: The system is based on batching the grass. Possible reasons for batching beeing broken include copying a Grass Manager from another scene when grass has been planted, missing meshes on the brush objects in custom brushes and missing materials in the customized brushes. If the batches count in the info window is very high, means that the system is not working proper and is best practice to create a Grass manager from scratch and always plant and erase grass through the manager, to be on the safe side.
Q: In interactive grass demo the performance takes a hit
A: The interctive grass demo uses the older versions scripted interaction, which opens up the batches, does the scripted changes in CPU and closes the batch in run time. This can be taxing on CPU and create spikes, based also on grass type and grass density. The newer versions (v1.5 and above) have a shader based temporal interaction mode (governed in radius by the Stop motion distance variable) and this shader is used by default, so it is advised to avoid the Interactive grass options in the brush settings, as this mode is for special cases and use the new GPU mode only. The coming v2.0 will have GPU based permanent grass interaction, which will be exponentially faster than the scipted mode as well.
Q: How do i define LODs for a brush ?
A: The LODs are defined by adding objects in the brush that have a material with LOD0 (or LOD1, LOD2) in the brush name and also have shadow cast & receive disabled (use Debug unity mode to disable shadow receive when in Deferred camera mode, or set to Forward to disable and back to Deferred). The objects can be anything, easiest is to copy the existing objects and change the material with the LOD named one. The MeshFilter component must also be disabled (otherwise the LOD meshes will ficker out when the game starts).
Q: I have a vast world and want to plant it all. Is this possible ?
A: Yes, but is advised to do so using multiple Grass Managers, each covering a specific smaller region. This has the advantage that the manager and its grass can be disabled when the player is away to save on performance and LOD change checks. The GrassManager holder references to the batched grass (“InfiniDYForest” items in the hierarchy) in the “StaticCombiners” public list, which can be grabbed from script directly from the manager in order to disable in a possible higher level LOD manager. The sectioning of terrains with a Grass Manager grid and disable of batchers is automated in the upcoming v2.0 of the system and happens when mass planting the terrains.
Q: A brush has more than one materials that require wind parameters, how is this handled ?
A: There is a “Extra grass materials” list in the Grass Manager, that can hold an extra list of materials for each grass type, assign any extra materials in this list, for the relevant brush type (extend the “Extra materials” list with setting its size above zero first, then drag and drop the needed extra materials)
Q: I cannot plant grass on a mesh terrain
A: To plant on meshes, the mesh must have the “PPaint” tag applied on it and also the “Paint on ‘PPaint’ tagged” checkbox in the Grass Manager must be checked. The mesh must also have a valid collider for the painting to take place.
Q: Can i set the brush so it always looks at a certain direction ? E.g. for trees to always look up, vines look down
A: Yes, the grass grower script has such an option, in “InfiniDyGrassField” script in the grass grower prefab of the brush, set the “CustomRot” checkbox and the “RotTowards” checkbox to true and use the “RotVector” vector to define the direction to be used instead of the surface normal. For example (0,1,0) can be used for trees looking up and (0,-1,0) for vines looking always downwards.
Q: The editor gets slow after planting lots of grass
A: The editor can have extra overhead when lots of items are in the scene. There is a “Editor view distance” slider that can lower the visible grass in the editor, thus increasing performance and allowing faster planting. Also it is advised to use more than one Grass managers, and “Ungrow” each and have only one active for planting each time. This increases editor performance a lot and is also usefull in play mode as an extra LOD system can be possible with disabling the far away managers.
Q: Can the system plant on any orientation and surface ?
A: Yes, the system can plant on multiple overlapping layers and below surfaces or on angled surfaces etc
Q: I cannot Mass Plant on a terrain when i have many terrains in the scene.
A: First disable the other terrains and leave only one that will plant on, then do the mass plant, repeat for the rest terrains
Q: I cannot paint grass on the Unity terrain
A: If more than one terrains is on the scene, tag all terrains with “PPaint” tag and enable the “paint on PPaint tagged” option to paint on all at once.
Q: The erase function is not working or not always working
A: Use the Mass erase checkbox option to erase grass en mass, in the single mode each grass center collider must be hit in order to erase the grass patch. The system relies on raycasts and thus also may require the “queries hit triggers” to be enabled in the physics settings (usually this is on by default, but perhaps has been disable for other functioanilities or gameplay situations).
I attach a first WIP version for the new FAQs guide, i have created it from various issues that come up frequently, so these should help clarify some major points for starting with the system and tweaking it. Some of the issues that come up above are also addressed in the upcoming v2.0 in automated or more streamlined ways.
TUTORIAL VIDEOS: http://forum.unity3d.com/threads/infinigrass-holiday-sale-fast-next-gen-interactive-volumetric-grass-everywhere.351694/page-4#post-2405601
DEMOS (These are WIP demos and a lot of further optimizations have gone in the system, final demos will be released soon):
InfiniGRASS (v1.1) paint grass (and fences-rocks) demo
https://dl.dropboxusercontent.com/u/79230236/INFINIDY/INFINIGRASS/INFINIGRASS_PAINT_DEMO.html
InfiniGRASS (v1.0) demo with Sky Master v3.0 Snow-Water-Sky-Rain
https://dl.dropboxusercontent.com/u/79230236/INFINIDY/INFINIGRASS/INFINIGRASS_SKYMASTER3_DEMO.html
Instructions:
-Paint grass with right mouse button and erase with left.
-Paint fence with right click and stop painting with fence paint toggle button.
-Paint rocks with right button, erase with left. 3rd rock type can be painted on itself !!!
-Press “Interactive on” to plant interactive grass, use for tall grass and use “cast ball” toggle to cast balls on the grass. Use small brushes for best dynamic result.
-The hero can also step on the grass (if balls are not activated)
- Toggle snow and water (and rain in special FX) in Sky Master demo to see how these extra FX integrate with InfiniGRASS
Round planets - InfiniGRASS fully supports any surface
Grass Interaction - Before stepping on grass
After stepping on grass
Uber detailed grass
Fully compatible with Sky Master ULTIMATE 3.0 (volume fog, image effects)
Endless Fields, placed in editor or real time
(Note: The pics are from WIP and the system has grown a lot since they were taken and is constantly polished for perfection. SpeedTree trees will not be included in the pack and can be downloaded from Unity store for free)
Videos and images from the latest version will follow soon.
All the grass, rocks and fencing in the images is placed/created with InfiniGRASS.
Sky Master ULTIMATE customers will benefit from specially made shaders that support the new global snow coverage feature that will be included in the upcoming v3.0.