AlignToVector
Aligns an entity axis to a vector.
AlignToVector ( entity,x#,y#,z#,axis[,rate#] )
Parameters
- entity
- the entity's handle.
- x#
- the direction's x part.
- y#
- its y part.
- z#
- its z part.
- axis
- which of the entity's axes to point: 1 for its x axis (its right), 2 for its y axis (its up), 3 for its z axis (its front).
- rate# (optional)
- how much of the way to turn it, from 0 (not at all) to 1 (all the way).
Description
Turns an entity so one of its axes points along a direction. It can turn part of the way, which, done each frame, swings it round smoothly.
