Improving repl more

This commit is contained in:
dylan
2023-05-04 20:14:48 -07:00
parent dca54e76ec
commit 2a7003b443
7 changed files with 77 additions and 38 deletions

View File

@ -153,6 +153,10 @@ export const setPixelsInRect = (x: number, y: number, w: number, pixels: Array<n
}
}
export const fillRect = (x: number, y: number, w: number, h: number, color: number) => {
setPixelsInRect(x, y, w, Array(w*h).fill(color));
}
export const clearScreen = () => {
allPixelColors.fill(0);
}