MAXScript Language Reference > 3ds Max Objects > Animation Controllers > Controller Types > Matrix3 Controllers >

# LookAt : Matrix3Controller

    lookat - superclass: Matrix3Controller; super-superclass:MAXWrapper - 3:3 - classID: #(8198, 0)

Value > MAXWrapper > Controllers > Matrix3Controller > LookAt

| Animation Controllers - Quick Navigation

The LookAt controller is obsolete and available only for backwards compatibility. You are encouraged to use the LookAt Constraint (which is a Rotation Controller and not a Matrix3 Controller) instead.

Constructor

    lookat ...

Properties

    <lookAt>.position Bezier_Position -- the position controller

Get/Set the Position sub-controller of the LookAt controller.

    <lookAt>.roll_angle Bezier_Float -- the roll controller

Get/Set the Roll sub-controller of the LookAt controller.

    <lookAt>.scale Bezier_Scale -- the scale controller

Get/Set the Scale sub-controller of the LookAt controller.

There presently are no methods for directly accessing or setting the target node in the LookAt controller. To set the target node, the LookAt controller needs to be assigned to a node, and then the lookat property of the node is set to the target node. If the transform controller for a node is not a LookAt controller, and a target node is assigned to the lookat property of the node, a LookAt controller is automatically assigned to the node.

FOR EXAMPLE
    $box01.lookat=$box02
is equivalent to
    $box01.transform.controller=lookat()
    $box01.lookat=$box02

lookat interfaces:

    Interface:ILookatControl

Properties:

    .UseTargetAsUpNode: bool : Read|Write

Get/Set whether to use the target as the Up Node.

    .Axis: integer : Read|Write|Validated by Range: 0 to 2

Get/Set the axis. Possible values are:

0 - X Axis

1 - Y Axis

2 - Z Axis

    .Flip: boolean : Read|Write

Get/Set whether to flip the orientation.Normally, a node will look at the target with the negative axis. Setting Flip to true will make the node to look at the target with the positive axis.

#### See Also

- LookAt_Constraint - superclass: RotationController

- Controller Common Properties, Operators, and Methods

- MAXWrapper Common Properties, Operators, and Methods

- Value Common Properties, Operators, and Methods