官术网_书友最值得收藏!

Chapter 3. Player Characters

In this chapter, we'll expand the island scenario we created in the previous chapter by taking a look at the construction of the player character that you have already added to the scene. Stored as a prefab (a data template object) provided by Unity Technologies as part of the Standard Assets package, this object is an example of a first person perspective player character. But how does its combination of objects and components achieve this effect?

In this chapter, we'll take a look under the hood of this prefab, while looking at how each of the components work together to create our player character. You'll get your first look at scripting in Unity JavaScript. As we have already added our prefab to the game scene, it would be all too easy to continue with the development and accept that this object just works. Whenever you are implementing any externally created assets, you should make sure you understand how they work. Otherwise, if anything needs adjusting or goes wrong, you'll be in the dark.

With this in mind, we'll take a look at the following in order to help you understand how combining just a few objects and components can create a fully-fledged character:

  • Tags, layers, and prefabs in the Inspector
  • Parent-child relationships in objects
  • JavaScript basics
  • Scripting for player movement
  • Public member variable adjustment in the Inspector
  • Using cameras to create the viewpoint
主站蜘蛛池模板: 香港| 青州市| 日喀则市| 河南省| 定兴县| 宁南县| 安仁县| 虹口区| 汤阴县| 正安县| 上思县| 吉林省| 弥勒县| 多伦县| 扶沟县| 阿拉尔市| 红安县| 台南县| 定州市| 岳普湖县| 西吉县| 和政县| 尼玛县| 穆棱市| 福清市| 石狮市| 左权县| 太湖县| 永济市| 锡林浩特市| 宁远县| 峨眉山市| 溧阳市| 陇西县| 栖霞市| 武清区| 大田县| 德格县| 清涧县| 中牟县| 汉寿县|