
This lesson introduces the advanced Align Target capability within Rive's Listeners system. Instead of strictly manipulating variables, listeners can directly capture a pointer's runtime coordinates to drive another layer's position. This zero-code mapping framework streamlines the design of micro-interactions like eye-tracking or reactive cursor UI without complex web geometry scripting.
- Zero-Code Coordinate Space Projection: Traditionally, cross-platform mouse tracking demands registering global container listeners and mapping raw mouse client coordinates into localized canvas vectors. Rive handles this layout calculation under the hood, passing pure spatial updates directly to target nodes.
- Industry Practice (The Invisible Hitbox): Using an un-filled, un-stroked, or hidden shape layer as a proxy container is a standard approach. Scaling it to fit the background isolates interactive zones from rendering pipelines, giving you a safe boundary for user interface triggers.
- Advanced Rigging Extensions: Align Target shines brightest when combined with bone constraints. For instance, binding a custom controller to follow the pointer while constraining it via a Distance Constraint allows teams to animate eyes, hair, or limbs that dynamically lean towards user focus nodes effortlessly.