Fixing problem when switching scenes with container

This commit is contained in:
David Négrier 2020-07-29 11:40:05 +02:00
parent dcbe8d35db
commit bc929615d1
4 changed files with 24 additions and 14 deletions

View file

@ -28,6 +28,7 @@ import {SimplePeer} from "../../WebRtc/SimplePeer";
import {ReconnectingSceneName} from "../Reconnecting/ReconnectingScene";
import FILE_LOAD_ERROR = Phaser.Loader.Events.FILE_LOAD_ERROR;
import {FourOFourSceneName} from "../Reconnecting/FourOFourScene";
import {LAYERS, loadAllLayers} from "../Entity/body_character";
export enum Textures {
@ -158,6 +159,8 @@ export class GameScene extends Phaser.Scene {
);
});
loadAllLayers(this.load);
this.load.bitmapFont('main_font', 'resources/fonts/arcade.png', 'resources/fonts/arcade.xml');
this.connectionPromise = Connection.createConnection(gameManager.getPlayerName(), gameManager.getCharacterSelected()).then((connection : Connection) => {