[Unity 3D from entry to actual combat] Summary of Unity 3D components

Table of contents

I. Introduction

Second, common components

1. Transform component

2. Mesh Filter component

3. Box Collider component

4. Rigidbody components

5. Script components

Three, summary


1. Foreword _

  1. Components are an important concept in Unity 3D. Unity 3D scenes are composed of game objects, and game objects can mount different components, and different components have different properties, which also makes different game objects have different effects.
  2. In Unity 3D, all objects are composed of components. Components are the necessary elements to realize all functions. Different components realize different functions. The combination of components and different settings of parameters will cause the state of game objects to change. difference.

Second , common components

1. Transform component

  • Any game object has a Transform component, which is used to control the position, rotation and scaling of the game object.

  1. Position : placement position
  2. Rotation : rotation angle
  3. Scale : zoom size 

2. Mesh Filter component

  • Mesh filter , this component is used to obtain the mesh from the project resource and pass it to the game object to which it belongs. After adding the Mesh Filter component  , you need to add the Mesh Renderer component (mesh renderer) . The mesh only passes through the mesh The renderer will only display it.

3. Box Collider component

  • The box collider  allows game objects to achieve collision effects for collision detection or trigger detection

4. Rigidbody components

  • The steel body component  can add NVIDIA PhysX physics engine to the object, which can simulate real physical behaviors, such as gravity, friction, elasticity, power, etc. 

5. Script components

  • Because Unity is a component-based development, scripts can also be added to objects as components. Unity 3D can use C# scripts to add the properties you want and display them in the Inspector panel

Three , summary

  • The components that will be encountered in the future will be added to the content of the article one by one, increasing the length of the article.

Guess you like

Origin blog.csdn.net/weixin_43729127/article/details/128300889