Island Generation for the Herd
- Dec 18, 2018
- 4 min read
The Herd is an atmospheric adventure game in the sky where you play as the lone survivor of a collapsed civilization. Glide through the world and round up a herd of creatures with your musical instrument. Help them stay safe and explore the sky together (Boxcastle Games. ).


Alpha version in game screenshots (Thanks our artists to make it pretty)
Alpha version game play trailer
1. Challenges
The biggest challenge for my job so far is how to fit different styles of islands in one tool. Our vision is to have one single tool that generates two to three different art styles of islands because long story short - players herds the remaining creatures and by doing so he(she) slowly brings the life to this world. And one important aspect to reflect that is to one the shape language on the islands. From Canyon like dead islands to root shape living islands. So the tool needs to be scalable and flexible.

Island concept arts by Rita Kaczmarska (https://www.artstation.com/ritakaczmarska)
2. My Approach
A straightforward and approachable solution to it is integrating L-system to the generation of island shapes. The L-system gives controllable output with different styles. Although it is hard to let artists fully understand how L-system works, create a few preset options for them would not be a bad solution.
It's rather easy to create cold dead rock like shape. And when it comes organic shapes, turbo noise becomes our best friends. What is special about turbo noise is that a 3D curl noise can mimic the organic flow of living things.

1. L-System generated lines 2. Lines copied to random points on L-System output 3. Lines after curl noise 4. Final output with organic shapes with a hole top fly through
In the image shown, a L-system provides a good base of how much space an island should occupy and the density of the lines scattered. After apply turbo noise it, a piece of geometry was inserted and the island roots will avoid this root and eventually leave a hose to it to let players to fly through.
3. Implementation
What comes from L-system is a set of points and lines defining. So I re-sampled it and scattered some on it and use these points to copy and translate some lines. Those lines are given a weight in which the closer it gets toward the center, the longer it could possibly get. And the artist wants to have an overall control on the flow of those lines, so I made a simple control node for them.

An attribute wrangler node that controls the shape of scattered lines
The code is simply just calculated the geometry center of line bundles, set up a few thresholds and use them to move a certain parts of the geometry. And after that, turbonoise is applied to those lines. What I find really interesting is that if we round the noise with in a certain range, we can get kind of semi organic semi rigid looking root flow. Although it is disproved by artist...T_T

1.Rounded Curl Noise 2. Straight Turbo Noise 3. VoP network for Rounded Curl Noise
And the level designer do wants a controllable holes or cracks on the island to let players to fly through. My quick and dirty why to do that is to group out the start point and the end point of each curve, and run a pass of findShortestPath to avoid a hole/crack like shape. And run a smooth on the affected area to counter abrupt artifacts.

Island with a hole to fly through
And the final step to solidify the shape of islands is to use those lines as base points to sweep a circle on it. And then convert it to VDB. One extra step I did was to use a giant cube to cut the top part of the island to make a flat top, do a pass of VDB smooth and then convert it back to polygon mesh. A pattern that my artist wants to have is to let geometries in the center to be wider - while geometries on the border become smaller. A trick I found to make it happen is to use a log function and apply it to each single line's distance from center. And a threshold to kill tiny geometries.
4. Normals

1. Combination of hard normal and soft normal. 2. Hard normal 3. Smooth normal
We are using a blend material to blend three materials for the island. The material looks nice in its material ball but when it lends on islands it definitely need more work. Since the material is based on world normal direction, normals will affect the color distribution on the island. I tested out three automate solutions for the team - All hard normals is ruled out since the island look chunky. The right side one is all soft normals and this yields out a smaller proportion of grass land with too much sand materials. So my solution is the let the upper part of islands stays soft while changing the body part to hard normals. It is still a potential solution, the best solution is to set vertex normals individually based on the point normal information it belongs.
Still working on the rest of it..




Comments