Skip to content

Commit

Permalink
Generate background only for rocks
Browse files Browse the repository at this point in the history
  • Loading branch information
delasy committed Nov 5, 2024
1 parent 386db9f commit 8ec749d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions renderer/Background.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,10 @@ export async function generateBg(

for (let y = 0; y < map.length; y++) {
for (let x = 0; x < map[y].length; x++) {
if (map[y][x] !== "R") {
continue;
}

const bitMask = getBitMask(map, x, y);
const tileIdx = BITMASK_TO_TILE_INDEX[bitMask];

Expand Down

0 comments on commit 8ec749d

Please sign in to comment.