Importing the game character

We will use a custom third-person character controller for our Cucumber Beetle game. First, we should make sure there are no conflicting assets in your game project. Let's start by launching Unity and opening your game project based on the work you did in Chapter 6, Creating and Importing 3D Objects for our Game. Alternatively, you can load the Starting-Chapter-07 Unity project available from the publisher's companion site. Once your project is loaded in Unity, delete any of the following listed items from the Hierarchy panel:

  • Camera (you will retain the main camera you first explored in Chapter 5, Lights, Cameras, and Shadows)
  • ThirdPersonController

Once the unnecessary assets are deleted, your Hierarchy panel should contain only the assets listed in the following Hierarchy panel screenshot:

You are now ready to import the asset package for our game's player character, the Cucumber Man. Go through the following steps to import the package:

  1. Download the CucumberMan_Controller.unitypackage file from the publisher's companion website
  2. In Unity, with your game project open, select AssetsImport PackageCustom Package from the top menu
  3. Navigate to the location of the asset package you downloaded in step 1 and click the Open button
  4. When presented with the Import Asset Package dialog window, click the Import button

As you will notice, the Cucumber Man asset package contains several assets related to the Cucumber Man, including a Controller, Scripts, Prefabs, and other assets. In the next section, we will add the Cucumber Man to our game.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset