Scripting/Squirrel/Functions/Object.RotateToEuler

From Vice City Multiplayer
Revision as of 11:37, 2 June 2019 by NicusorN5 (talk | contribs) (Created page with "Rotates the specified object using a Vector. ==Syntax== <pre>object.RotateToEuler(rotation,time)</pre> ==Arguments== ''Vector'' '''rotation''' - Rotation in Euler angles sys...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Caution icon
This wiki is using an old backup from 2020
Some information may be old/missing

Rotates the specified object using a Vector.

Syntax

object.RotateToEuler(rotation,time)

Arguments

Vector rotation - Rotation in Euler angles system. Be aware that this method uses radians instead of degrees. For a example to rotate an object 90 degrees around an axis use

Vector(0,0,3.1415926 /2)

Plase be aware that the y and z coordinates in VC's engine are somewhat switched. If you are used to degrees, use a Radians to degrees calculator

int time - Time in milisecond how fast the object will move. For map-making use 0.

Example

object.RotateToEuler(Vector(0,0,3.1415926 /4)

Related Functions