2023-02-17 11:06:01 +01:00

10 lines
268 B
JavaScript

const fixFactor = Math.sqrt(2);
export class SquareDrawer {
draw(context, particle, radius) {
context.rect(-radius / fixFactor, -radius / fixFactor, (radius * 2) / fixFactor, (radius * 2) / fixFactor);
}
getSidesCount() {
return 4;
}
}