Unity Unity Physics and Animation 1 — Questions and Answers
Question 1: Which component must be attached to a GameObject to enable Unity's physics simulation on it?
- Collider
- Rigidbody (Correct answer)
- Transform
- Animator
Correct answer: Rigidbody
The Rigidbody component enables physics simulation, allowing GameObjects to respond to gravity, forces, and collisions.
Question 2: What is the primary purpose of a Collider component in Unity?
- To render the mesh
- To define the physical shape for collision detection (Correct answer)
- To apply gravity
- To animate the object
Correct answer: To define the physical shape for collision detection
Colliders define the physical shape used for collision detection and are separate from the visual mesh.
Question 3: Which Unity physics method should be used to move a Rigidbody in a physics-safe way each fixed frame?
- Update()
- MovePosition() in FixedUpdate() (Correct answer)
- Translate() in Update()
- LateUpdate()
Correct answer: MovePosition() in FixedUpdate()
MovePosition() called inside FixedUpdate() ensures physics-safe movement synchronized with the physics engine.
Question 4: In Unity's Animation system, what is an Animator Controller used for?
- Storing raw animation clips
- Managing state machines and transitions between animations (Correct answer)
- Rendering skeletal meshes
- Setting physics constraints
Correct answer: Managing state machines and transitions between animations
An Animator Controller manages the state machine that controls which animation clips play and when transitions between them occur.
Question 5: What does the 'Is Trigger' checkbox on a Collider do?
- Enables gravity on the object
- Makes the collider detect overlaps without physical collision response (Correct answer)
- Locks the object's rotation
- Enables continuous collision detection
Correct answer: Makes the collider detect overlaps without physical collision response
Marking a Collider as a trigger allows it to detect overlapping objects via OnTriggerEnter/Exit without generating a physical collision response.
Question 6: Which Animation blend tree type is best suited for blending directional movement (e.g., walk forward/back/left/right)?
- 1D Blend Tree
- 2D Freeform Directional Blend Tree (Correct answer)
- Direct Blend Tree
- Override Layer
Correct answer: 2D Freeform Directional Blend Tree
A 2D Freeform Directional Blend Tree blends animations based on two float parameters, making it ideal for directional locomotion.
Which component must be attached to a GameObject to enable Unity's physics simulation on it?