In the Mind of an Ostrich

In the past months, we have continued to develop our game Ostrich Farm. During testing, we noticed that it can be hard to tell what our ostriches are up to. Since the player may need to intervene with some behaviors to ensure that orders are completed on time, it is necessary to show what the next planned action is. To help with this, I came up with what we ended up calling 'mind clouds'. Here's a brief look at how this component works and how we are using it.

Key Features of the Mind Cloud Component

How It Works

Data Table Setup:

We created a data table to store our mind cloud textures. Each entry in the table includes an identifier and the path to the texture file.

Dancing ostrich

Blueprint Logic:

We manage the creation and destruction of mind clouds in the component and use a mind cloud actor with a material billboard to display the texture. There are functions to control the appearance and duration of the mind clouds.

Material Configuration:

To add some extra flavor, we wanted the mind clouds to have soft movement. The material for the mind cloud transforms the uv's of the texture to create a continuous pulse animation.

Future plans

We're looking forward to reusing this component in future projects and will continue to refine it. Eventually, it would be nice to expand it with the following features:

Feathers and Footwork

In our ongoing quest to infuse life into our birds, we found unexpected inspiration while looking for animation reference on Youtube. Previously, our ostriches had a rather mundane approach to mating, just standing there in front of each other. Not exactly the epitome of romance, right? This weekend, we implemented new behavior, so now the male ostrich performs a small dance. To keep it simple, we started out with some basic moves — nimble steps and synchronized wing shakes, set to rythmic drum music.

As we venture further into development, our focus will be on the progression system, which is geared toward gradual discovery. Unlocking new dances moves will be a part of that. But they are not just for looks — an impressive performance will improve the odds of successfully courting a female ostrich. We want to add more animations later on, so we can blend between them. The idea is that every male ostrich will have a signature dance to spice things up. ~(‾▿‾~)(~‾▿‾)~

Dancing ostrich

Exploring Ostrich Variations

In my last post, I explained how I created a custom model for our game. Since then, we were able to test it in the engine.

The core feature of Ostrich Farm is combining ostriches with different colors and patterns to create cool looking offspring. To give our birds more personality, we decided to implement blend shapes for the head. The most prominent feature of our model is the beak, so this is where different shapes will be the most visible.

Here are the five blend shapes I set up:

Ostrich Blend Shapes

After importing the blend shapes into Unreal as morph targets, we can blend between them to get a unique look. The values are stored in each ostrich instance so that they can be passed down to offspring. This ties into our genetic system which also controls the inheritance of colors and patterns.

Something else we are adding to our model is a haircut. Here are some WIP sculpts:

Ostrich hairstyles

I have also rigged the model and created a first set of animations so we can continue our development with the new asset. I learned how to rig last year with the help of antCGI's comprehensive tutorials.

Now that we have all the core features of our model in the game, I will continue to produce animations, tweak the materials and polish. I would love to add a baby ostrich later on. Currently, ostriches hatched from eggs are full-grown.

Ostrich in game

 


Notes:

antCGI's Website
https://www.antcgi.com/

Creating Our Ostrich Model

After implementing the core loop in our game Ostrich Farm, I spent some time modifying our ostrich model so it supports the planned features.

Prototyping with a placeholder

When we started development, I purchased an awesome animated ostrich asset from the Unreal marketplace. This allowed us to start working on game mechanics before the final model was finished. Having animations in the game early on helped with setting up the behavior tree and gave us some ideas for interactions. Since one of the core mechanics of Ostrich Farm is breeding colorful ostriches, I had to make some modifications to the mesh. After a bit of research we decided to go with stylized sculpted feathers. I found a straightforward tutorial by follygon that helped me create that look.

Marketplace ostrich asset and new sculpt

Making adjustments

Initially, I thought I could be minimally invasive and just add feathers to the subdivided mesh in ZBrush, then bake it back onto the existing low poly. I assigned polypaint to the feather clusters and used it to generate the color id map in Substance Painter. When I first tried to bake the textures, there were issues with the wings because of their position and shape. Still, I was able to get good enough placeholder textures to prototype a material in Unreal. The material assigns different colors to the individual feather cluster to make a pattern. I'm using the color id map in the shader to mask out individual areas.

An additional requirement for the model was that it should allow for blend shapes. We want to implement different beak lengths and shapes to make the individual ostriches look more unique. This meant that we would need more vertex density in the head to support these deformations without stretching the UV's too much. We also wanted a more stylized, cartoony head shape and the placeholder asset had a more realistic look.

Because of the need for blend shapes and the issues with baking the wings, we decided to remake the model. I used the asset as a base and modified the wings and torso in ZBrush. I also sculpted a new head from scratch. Next, I retopologized the high poly in Maya and made a test bake.

I am happy with the result so far. Since we are using the color id maps directly in our material, creating more patterns is very easy. All I need to do is add polypaint to the feather clusters in ZBrush and bake the assigned colors into the map.

Here you can see two different feather patterns I created using this workflow:

Two stylized ostriches with different feather patterns

Future plans

My next steps include creating the new textures, setting up blend shapes and then rigging and animating the model. I want to produce a handful of different color id maps so we can have some variation in the game.


Notes:

Ostrich by Medhue
https://www.unrealengine.com/marketplace/en-US/product/medhue-ostrich

Stylized feathers tutorial by follygon
https://www.youtube.com/watch?v=g-PL_s9Qvzc