summaryrefslogtreecommitdiff
path: root/packages/web/src/math/Coord.ts
diff options
context:
space:
mode:
authorJosh Kingsley <josh@joshkingsley.me>2025-11-24 15:46:22 +0200
committerJosh Kingsley <josh@joshkingsley.me>2025-11-24 15:46:22 +0200
commitd724cc0bf6ff6d351319e6fb00f5184a04e16ac0 (patch)
treecb43253479df5db8f4844e17e68a48ea5a212df4 /packages/web/src/math/Coord.ts
parent7c966e105cd9f65853de1aba0ecce63aa56aca0b (diff)
chore: improve dev tasks
Diffstat (limited to 'packages/web/src/math/Coord.ts')
-rw-r--r--packages/web/src/math/Coord.ts23
1 files changed, 0 insertions, 23 deletions
diff --git a/packages/web/src/math/Coord.ts b/packages/web/src/math/Coord.ts
deleted file mode 100644
index db7ee6d..0000000
--- a/packages/web/src/math/Coord.ts
+++ /dev/null
@@ -1,23 +0,0 @@
-/** A coord on a grid whose origin is in the top left. */
-export default class Coord {
- private readonly _x: number;
- private readonly _y: number;
-
- constructor(x: number, y: number) {
- this._x = x;
- this._y = y;
- }
-
- get x(): number {
- return this._x;
- }
-
- get y(): number {
- return this._y;
- }
-
- /** Get the squared distance of this point from the origin. */
- squaredDistanceFromOrigin(): number {
- return this._x * this._x + this._y * this._y;
- }
-}