linearly v0.32.0 • Docs
linearly v0.32.0 / vec2 / dir
Function: dir()
dir(
deg
,length
,origin
):vec2
Alias for vec2.direction
Parameters
• deg: number
The direction in degrees
• length: number
= 1
The length of the vector to create. Default is 1
• origin: vec2
= vec2.zero
The origin of the vector. Default is [0, 0]