Creating Reusable Characters With Blender and Unity

Characters in video games are often as memorable as the accompanying gameplay and music. In this tutorial, you’ll learn how to prepare a humanoid model using Blender and how to bring it into Unity. By Eric Van de Kerckhove.

5 (3) · 2 Reviews

Download materials
Save for later
Share
You are currently viewing page 3 of 5 of this article. Click here to view the first page.

Adding Accessories

Accessories in this context are objects that are attached to the character but aren’t a part of its body. This section discusses two ways of attaching objects: to the model itself and as a separate, reusable object that connects to a bone.

The former is a simple hat, and the latter is a weapon for the character to hold.

Before continuing, press A two times followed by Alt (or Option) + R to reset the rotation of all bones.

Editing the Character

The first way of adding more details to your character is easier to work with, but it comes with some limitations. As you’ll be working on the model itself — which is mirrored — all geometry added will be copied from the left side to the right and vice-versa. This makes it impossible to add anything unique to one side. Because the geometry is a part of a particular model, it also can’t be reused for other characters. It’s perfect for any situation where those limitations aren’t a problem.

If you’ve followed along with the tutorial until now, you’ll probably still be in Weight Paint mode. Press Tab to enter Edit mode and start off by switching the selection mode to Vertex by pressing 1 on your number row or by clicking the first button right of the mode dropdown.

Now select any vertex above the red line (which is an UV seam used for texturing) on top of the head by clicking on it. Next, press CTRL + L to select all connected vertices, this selects the whole model. Now select the UV delimiter by selecting UVs in the bottom left panel. The top of the head will be selected now.

Select the edge loop underneath as well by holding Shift and Alt (or Option) and then clicking on any of the first horizontal edges below.

Now duplicate the selected faces by pressing Shift + D and then clicking. Move the duplicated faces up a bit by pressing G, Z and 0.01 followed by Enter to confirm.

Next, scale the whole selection up by pressing S, 1.05 and Enter. This moves the hat away from the head a bit, so you don’t end up with some of the faces Z-fighting.

The hat is still floating around, so do the following to attach it to the model:

  • Select just the bottom row of the “hat” by pressing ALT/Option + A to deselect everything. Now select the bottom edge row of the hat by holding Alt (or Option) and clicking on one of the bottom edges.
  • Make it straight by press S, Z and 0 in that order.
  • Press E to extrude and press Enter to confirm.
  • Press S to start scaling and move your cursor towards the model until the edges are inside of the head. Rotate the view around to make this easier to see. Click to confirm the scaling.

This gave the hat some depth so it can look all right from all sides without any holes. A hat made from human skin probably isn’t what you had in mind though! To change the color, you’ll have to unwrap its UVs first so it can fit nicely on the texture.

Select the entire hat by selecting any vertex on the hat and then pressing CTRL + L. Change the delimiter to Normal this time to select all the connected vertices. For this hat, you’ll perform one of the easiest unwraps in existence: from the current view. Press numpad 1 to get a front view, then press U to open the Unwrap menu and select Project From View.

If you look at the right side of the Blender window where the texture is visible, you’ll notice some vertices were added that look similar to half of the hat:

You can select all of these by moving your cursor over to the texture and pressing A. Actions in Blender are context sensitive depending on where your cursor is placed, so make sure to keep it somewhere inside the region of the texture for now.

Now press G to move the UVs over to the blue splotch, confirm the movement by clicking and then scale the selection down until it fits inside the blue region by pressing S and confirming by clicking again.

If you now look at the character again, you’ll notice his hat turned blue!

Now, position the cursor back somewhere near the model on the left and press Tab to return to Weight Paint mode. Rotate the Head bone around a bit to check if the hat is connected.

It looks like you’re in luck! Because the vertices of the hat are all so near to the Head bone, they’re included automatically. If this wouldn’t be the case, you’d have to paint the hat like you did with the eyes.

Next up is creating and attaching a separate object.

Attaching Objects

For this part, you’ll be creating a simple staff that will act as a weapon for the character to hold. It’s easy to imagine a sword, an axe or even a magic wand instead, but creating a complex weapon is outside the scope of this tutorial.

Get into Object mode and press Shift + A to open the Add menu. Select Mesh > Cylinder to add a new cylinder to the scene.

The default cylinder is too big, so adjust the cylinder parameters in the bottom left: change Radius to 0.04 and set the Depth to 1.2.

This makes the cylinder thinner and shorter. Now make the cylinder smooth by right-clicking to open the context menu and selecting Shade Smooth.

The cylinder doesn’t have any material assigned yet, so it looks grey and bland. To assign a material, open the Material tab in the Properties editor on the right and select CuteMaterial from the drop-down next to the New button.

To turn the cylinder into a brown staff, you’ll need to unwrap its UVs first. Press Tab to enter Edit mode, press U to open the Unwrap menu and select Project From View.

Move your cursor over the texture on the right, press G to start moving the UVs and move it over the brown patch on the texture. Confirm the movement with Enter and scale it down by pressing S and moving your mouse, so the UVs fit inside.

The staff is now brown colored. Don’t worry about the awkward positioning; you’ll be dealing with that next.

Open the Object Constraint Properties tab in the properties editor. Add a new constraint by clicking the Add Object Constraint drop-down and selecting Child Of.

Constraints limit the position, rotation and/or scale of an object. In this case, it’ll be used to parent the cylinder to the hand bone of the character. This way — if you create any animations — the object will be attached to the hand at all times. This makes previewing the animation a lot easier and allows you to prevent the object from intersecting with the body.

Setting up the Child Of constraint is straightforward. Click the Target drop-down and select Armature. Now click the Bone drop-down and select Hand.R. You can type the name of the bone in this fields to make selecting it easier.

After doing this, you’ll notice the staff snaps to the character’s right hand. The position isn’t quite right though, so move it forward a bit by pressing G, Y, -0.4 and Enter. Much better!

Time to put the staff to the test. Select the armature and switch to Pose mode. Now rotate the view so you can see the staff clearly, select UpperArm.R and rotate it around a bit by pressing R and moving your mouse around. The staff will keep following the hand around as if the character held it.

The character and its accessories are now done. Save the file and pat yourself on the back for a job well done!

Next up is exporting the model and the armature to Unity.