Creating Object Interaction Animations for Games
A character reaches for a door, the handle is right where it should be — but the hand passes through it, because the door is positioned 15 centimeters to the left of where it was in the original animation file. Or a character picks up an object — and it teleports into the hand instead of smoothly grabbing. This is not a rig bug, it is an architectural problem: interaction animations require real-time synchronization of object and character positions, and implementing this without IK and a proper attachment system is impossible.
Why Hardcoded Interaction Animations Don't Work in Real Projects
Baking complete interaction into a single FBX clip is temptingly simple. An animator in Maya creates a character render with a mug, exports, imports into Unity. In the scene, this looks correct exactly once: when the character stands in exactly the same position as in the source file.
In-game, the character can approach an object from any side, the object can lie at different heights, there can be physics-simulated objects that are not in a predictable position. A fully baked animation breaks immediately.
The solution is to divide the animation into two parts. Base animation sets the general arc of body movement, anticipation pose, and follow-through. IK layer pulls the limb to the actual object position at runtime. Unity Animation Rigging package provides Chain IK Constraint and Two Bone IK Constraint with Tip and Target transforms, which are managed by a script receiving the interactive object's position.
The IK constraint weight should not be constant 1.0. The correct scheme: at the beginning of the animation (approach phase) weight = 0, the body moves along the base clip. As the hand approaches the object, weight interpolates to 1.0 through AnimationCurve, which the controller updates through constraint.weight = ikWeightCurve.Evaluate(normalizedAnimationTime). This creates the sensation that the character is "feeling" for the object rather than jumping to it in a straight line.
Attachment and Parent Constraints
When a character picks up an object, the object should become a child of a bone or a special attach point. In Unity, the most reliable way is a GameObject with Transform attached to the hand bone (grip_r / grip_l), to which the object attaches through transform.SetParent() at the moment of Animation Event.
The Animation Event is placed on a specific frame of animation — the moment when the grip is already closed. If placed earlier, the object will jump into the hand before the grip closes. If later — there will be a frame when the hand is already closed but the object is still on the ground.
For grip accuracy, use Attachment Offset: the object has an empty GameObject named like grip_socket, and upon attachment its local transform aligns with the character's grip_r attach point through targetObject.transform.position = gripPoint.position + offset. The offset is computed in advance in Editor and saved in ScriptableObject for each object type.
Variability Through Constraint Blending
If there are multiple types of one interaction in the game (pick up a light object, pick up a heavy box, pick up a wounded ally) — there is no need to create completely separate animations. It is enough to make a base animation + additive layer for heavy objects (body bending, arm tension). Additive weight is managed through ItemWeight parameter, which Animator Controller receives from ItemData ScriptableObject.
Override Animator Controller with AnimatorOverrideController — useful when different objects require different clips for the same state. For example: Interact_UseItem state in the base controller can be overridden for a specific object through override without changing the entire Animator Controller logic.
Creation Process
Start with reference video or frame-by-frame breakdown of the interaction. For pick-up animations this is especially important: a real person never picks up an object in linear motion — there is arc, anticipation of fingers, weight shift.
Production: blocking base animation without IK → placement of attach/detach Animation Events → IK constraints setup in Unity → test with real scene geometry → final polish of secondary movements.
| Interaction Type | Timeline |
|---|---|
| Pick-up / put-down one object | 2–4 days |
| Door open/close with IK setup | 3–5 days |
| Full interaction set (5–10 types) | 2–3 weeks |
| Complex two-handed interactions (weapons, mechanisms) | 3–5 days per type |
Cost is calculated individually. For accurate estimate, you need: list of interaction types, screenshots or gameplay video, description of existing IK and Animator Controller structure.





