Refactor shapes
This commit is contained in:
parent
eb39846b75
commit
006ab3c4e6
1 changed files with 203 additions and 256 deletions
12
frontend/src/scripts/shapes/i-shape.ts
Normal file
12
frontend/src/scripts/shapes/i-shape.ts
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
import { BoundingBox } from './bounding-box';
|
||||
import { vec2 } from 'gl-matrix';
|
||||
|
||||
export interface IShape {
|
||||
readonly isInverted: boolean;
|
||||
readonly boundingBox: BoundingBox;
|
||||
|
||||
distance(target: vec2): number;
|
||||
normal(from: vec2): vec2;
|
||||
|
||||
clone(): IShape;
|
||||
}
|
||||
Loading…
Reference in a new issue