1 | import type { IValueWithRandom } from "../Options/Interfaces/IValueWithRandom";
|
2 | import type { ICoordinates } from "../Core/Interfaces/ICoordinates";
|
3 | import { MoveDirection, MoveDirectionAlt } from "../Enums/Directions";
|
4 | import type { IVelocity } from "../Core/Interfaces/IVelocity";
|
5 | import { RangeValue } from "../Types/RangeValue";
|
6 | import { Vector } from "../Core/Particle/Vector";
|
7 | export declare class NumberUtils {
|
8 | static clamp(num: number, min: number, max: number): number;
|
9 | static mix(comp1: number, comp2: number, weight1: number, weight2: number): number;
|
10 | static randomInRange(r: RangeValue): number;
|
11 | static getRangeValue(value: RangeValue): number;
|
12 | static getRangeMin(value: RangeValue): number;
|
13 | static getRangeMax(value: RangeValue): number;
|
14 | static setRangeValue(source: RangeValue, value?: number): RangeValue;
|
15 | static getValue(options: IValueWithRandom): number;
|
16 | static getDistances(pointA: ICoordinates, pointB: ICoordinates): {
|
17 | dx: number;
|
18 | dy: number;
|
19 | distance: number;
|
20 | };
|
21 | static getDistance(pointA: ICoordinates, pointB: ICoordinates): number;
|
22 | static getParticleBaseVelocity(direction: MoveDirection | keyof typeof MoveDirection | MoveDirectionAlt): Vector;
|
23 | static rotateVelocity(velocity: IVelocity, angle: number): IVelocity;
|
24 | static collisionVelocity(v1: Vector, v2: Vector, m1: number, m2: number): Vector;
|
25 | }
|