mirror of
https://github.com/bspeice/speice.io
synced 2024-12-22 16:48:10 -05:00
10 lines
155 B
TypeScript
10 lines
155 B
TypeScript
export function camera(
|
|
x: number,
|
|
y: number,
|
|
size: number
|
|
): [number, number] {
|
|
return [
|
|
Math.floor(x * size),
|
|
Math.floor(y * size)
|
|
];
|
|
} |