Skip to content
1        10        20        30        40        50        60        701import Phaser from 'phaser';2import { FlatScene } from './flat.js';34// The canvas fills the whole window (phones included); the scene picks a zoom.5export function createGame({ map, myId }) {6  const game = new Phaser.Game({7    type: Phaser.AUTO,8    parent: 'game',9    backgroundColor: '#120a18',10    pixelArt: true,11    roundPixels: true,12    scale: { mode: Phaser.Scale.RESIZE, parent: 'game' },13    scene: [FlatScene],14  });15  game.registry.set('map', map);16  game.registry.set('myId', myId);17  return game;18}