don't render box contents if they would be small enough to be invisible.

This commit is contained in:
HyperOnion 2023-06-24 20:49:02 +02:00
parent b28dcba597
commit 80bb0edf03
1 changed files with 2 additions and 0 deletions

View File

@ -33,6 +33,8 @@ export function draw_floor (start_x, start_y, scale, invert = false) {
}
export function draw_world (box, start_x = 0, start_y = 0, scale = BASE_SCALE) {
if (scale < 1) return;
draw_floor(start_x, start_y, scale, !checkerboard(start_x, start_y));
iter_2d(range(0, world.BOX_SIZE - 1), (x, y) => {