Skip to content

Commit 0ab5ee9

Browse files
committed
web: make world container cullable and set roundPixels
1 parent e93ed9e commit 0ab5ee9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

packages/web/src/lib/components/PixelWorldCanvas.svelte

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,14 @@ const initialisePixiApp = async () => {
4949
resizeTo: canvasContainer,
5050
autoDensity: true,
5151
resolution: window.devicePixelRatio || 1,
52+
roundPixels: true,
5253
});
5354
canvasContainer.appendChild(app.canvas);
5455
};
5556
5657
const initialiseWorld = async () => {
58+
worldContainer.cullable = true;
59+
5760
// Load and render Tiled map
5861
const tiledRenderer = await TiledMapRenderer.fromFile(
5962
WORLD_MAP_CONFIG.filePath,

0 commit comments

Comments
 (0)