MultiplayerMinesweeper/scripts/world/placer.mjs

15 lines
304 B
JavaScript
Raw Normal View History

2022-06-22 01:51:09 +00:00
import * as log from "../log.mjs"
import * as revealer from "./revealer.mjs"
export function place(x, y, data) {
let tile = data[x][y];
2022-06-22 01:51:09 +00:00
if (tile.mask === true) {
if (tile.mask && tile.flag === 0) {
tile.mask = false;
}
data[x][y] = tile;
revealer.reveal(x, y, data)
2022-06-22 01:51:09 +00:00
}
return data;
}