Introducing Art Assets (In Progress)
Well, let’s start with textures and moss in the terrain editor.
Right now I am working with 8 different textures and 5 different pngs for moss that are painted as grass.
Texture Atlas Script
The atlas script creates an atlas from the pngs I wish to paint as grass in the terrain editor. It creates UV coordinates for the images and extracts the images as individual pngs which is also determined by the size of the atlas.
The extracted file names from the atlas include the names of the original textures and the dimensions of the sizes. The script ensures the textures as RGBA32, and that alpha is transparency.
It also makes sure wrap mode is set to repeat.
I discovered that for performance, it is important to also set the Compression to Low Quality. The moss still looks good at this compression. So I manually set these extracted pngs to low-quality compression and experience no performance issues.
Terrain Settings
8 Textures in Terrain Editor
So far each moss png has similar settings to this example.
Lowering the Min Width, Max Width, Min Height, and Max Height have really worked well for the moss effect I am going for. The moss can be dense and does not affect performance so far.
The ferns were made using SpeedTree but I made a custom shader and material to give the ferns subtle movement and subsurface light.
I believe the subsurface will truly shine once I have some good lighting set up.
The rock was made in Blender and textured in Substance Painter. I had also been using the Quad Remesher addon to have clean low poly meshes.
Moss Atlas
5 extracted moss pngs
It is also important to note that I set the Billboard Start to 35 and the Detail distance to 40.
I playtested this, and the moss appears at an appropriate distance.
Shiny Wet Texture
I have a texture that has some interesting organic details and it’s smoothness turned up to give a shiny wet effect. Since this is a damp environment, this is an important detail.
Base Ground Texture
The base ground texture uses a normal to help it pop. It has just enough variation to not have an obvious looking pattern when repeating over large surfaces.
Moss Texture
I am using two different moss textures which help the environment look lush and green and help compliment the extracted moss pngs being painted as grass. The texture uses a normal and it really helps it pop even though its a flat painted texture.
Roots Texture
This rock texture is being used subtly to add a nice detail to break up the moss and blend in with the dirt. It looks good on the bumpier parts of the terrain but also blends subtly into the trail.
I had also put together a PureRef board combining images I took at a garden alongside images of Pikmin4 that I thought were comparable. As the art assets continue to transform the scene from a blockout to a forest, I will focus more on some of my inspirations from the photos.
The spawning pool is where the main character is born. The player walks out from the water to begin life on land. The water was created from an asset from the Unity Asset Store called URP Water. It uses a cubemap to reflect an image on the surface. Unity has a built in feature to make cubemaps from camera views, but I have a script that allows you to take any image and generate a cubemap that can be used on the water material to project the image.
I created a skybox and introduced sprout plants to the project.
Moving Plants
I created empty objects on the base of each stem that works as a pivot and have made a script that makes the plants move on trigger collision. Currently, I set the ferns to have more subtle movement than the sprouts. but it is more obvious with the sprouts that they move in the direction the player is moving.
New Flower
I introduced a new flower to the scene that uses the same custom shader as the fern and sprouts to give it a nice subsurface lighting effect and subtle movement to bring it to life.
Moving Mushrooms
The mushrooms I made in Blender. They were textured using Substance Painter and Photoshop. I used a special alpha map under the mushroom caps to give them gils that are visible with the normals. I also made them moveable, the smaller ones are more reactive, and the larger one moves slowly and with less force. I made a custom-optimized collider for the top of the mushroom so the Player can jump on top and the mushroom moves.
I am starting to add small details like sticks and various-sized rocks into the scene in areas the player will get close to.
I also started putting large low poly trees in the background that have some leaves with a material using a shader that gives subtle movement. I have been using the shader for all the leaves in the scene because I can control the amount of movement and subsurface light effect.
I am keeping in mind from my earlier concepts how the smaller details are arranged close to the player and the larger details are layered in the background.
I had been aiming to make the texture of the mosses feel like you can touch them, like when you look at moss in a photo or in real life it looks soft, velvety, and alive, with its dense, fuzzy surface and moist, earthy appearance inviting you to reach out and run your fingers through its lush, spongy layers. I also wanted to utilize the LOD technique in Unity.
In Blender I sculpted a high poly model of the basic clumps for the moss. I used Quad Remesher to make the mesh dense. I created the moss alpha to draw the details onto the dense high poly mesh of the moss clumps. I then created 3 lower poly versions. LOD0 (4k tris), LOD1(2k tris), and LOD2(600 tris). In Substance Painter I created two sets of textures, one set for Blender’s Shader Nodes, and one set for Unity’s Materials since they handle textures differently.
I wanted to show the LODs lined up. LOD0 on the left (4k tris), LOD1 in the middle (2k tris), and LOD2 (600 tris), on the right. I made a script to switch between them depending on the distance of the camera from the moss clump. LOD0 and LOD1 look very similar and LOD2 looks pretty good too especially since it will only be seen from far away. The textures remain nice and… mossy.
Here is a render of LOD0 from Blender with the textures applied from Substance Painter.
You can also check out my blog where I am updating more frequently with my travels and development activities.