Costing and feel-related movement fixes

This commit is contained in:
2025-02-22 16:19:06 -08:00
parent d9a7b5094c
commit 92288085b7
3 changed files with 50 additions and 48 deletions

View File

@ -105,6 +105,12 @@ export class Point {
lerp(y, Math.floor(this.y), Math.ceil(this.y)),
);
}
distance(other: Point) {
let dx = other.x - this.x;
let dy = other.y - this.y;
return Math.sqrt(dx * dx + dy * dy);
}
}
export class Size {