Physics Components
Cocos Creator currently provides users with the following types of physics components.
-
The collider component is used to define the shape of the collider. The shape can be viewed in the editor environment and is not visible at runtime. The shape can be set as desired, and does not need to be identical to the object mesh.
-
Rigid bodies are the basic objects that make up the physics world and allow the game objects to move in a physically controlled way.
-
The constant force component is a tool component that depends on a rigid body and will apply a given force and torque to a rigid body at each frame.
-
The constraint component depends on the rigid body component and constrains the position, orientation or scale of an object to other objects.