-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.js
More file actions
40 lines (39 loc) · 921 Bytes
/
main.js
File metadata and controls
40 lines (39 loc) · 921 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
import Phaser from "phaser";
import RoomManager from "./plugins/room_manager";
import CellScene from "./scenes/cell";
import HubScene from "./scenes/hub";
import RoomScene from "./scenes/room";
import MovementScene from "./scenes/movement";
import MainMenuScene from "./scenes/main_menu.js";
import PlayUIScene from "./scenes/play_ui";
import "./lib/physics.js";
new Phaser.Game({
type: Phaser.AUTO,
pixelArt: true,
plugins: {
global: [
{
key: "RoomManager",
plugin: RoomManager,
start: false,
mapping: "room_manager",
},
],
},
scale: {
parent: "game",
mode: Phaser.Scale.FIT,
autoCenter: Phaser.Scale.CENTER_HORIZONTALLY,
},
dom: {
createContainer: true,
},
physics: {
default: "arcade",
arcade: {
debug: false,
tileBias: 32,
},
},
scene: [MainMenuScene, CellScene, HubScene, RoomScene, PlayUIScene],
});