Constructors
constructor
- new SATVector(x?: number, y?: number): SATVector
Parameters
Optional
x: numberOptional
y: number
Properties
x
x: number
y
y: number
Methods
clone
- clone(): SATVector
dot
- dot(other: SATVector): number
Returns number
len
- len(): number
Returns number
len2
- len2(): number
Returns number
normalize
- normalize(): SATVector
perp
- perp(): SATVector
reverse
- reverse(): SATVector
rotate
- rotate(angle: number): SATVector
scale
- scale(x: number, y?: number): SATVector
Parameters
- x: number
Optional
y: number
This is a simple 2D vector/point class,Vector has two parameters {x},{y}.