Revert "Create and send close message"

This reverts commit 7ac4a2b849.

# Conflicts:
#	back/src/Controller/IoSocketController.ts
#	back/src/Services/SocketManager.ts
#	front/src/Phaser/Game/GameScene.ts
This commit is contained in:
Gregoire Parant 2020-10-22 01:46:41 +02:00
parent f9bb749c56
commit ff9f5cfc32
3 changed files with 1775 additions and 515 deletions

View file

@ -6,7 +6,7 @@
"scripts": {
"tsc": "tsc",
"dev": "ts-node-dev --respawn ./server.ts",
"prod": "tsc && node --max-old-space-size=4096 ./dist/server.js",
"prod": "tsc && node ./dist/server.js",
"profile": "tsc && node --prof ./dist/server.js",
"test": "ts-node node_modules/jasmine/bin/jasmine --config=jasmine.json",
"lint": "node_modules/.bin/eslint src/ . --ext .ts",

View file

@ -2,7 +2,6 @@ import {RoomConnection} from "../front/src/Connexion/RoomConnection";
import {connectionManager} from "../front/src/Connexion/ConnectionManager";
import * as WebSocket from "ws"
function sleep(ms) {
return new Promise(resolve => setTimeout(resolve, ms));
}
@ -12,18 +11,15 @@ RoomConnection.setWebsocketFactory((url: string) => {
});
async function startOneUser(): Promise<void> {
await connectionManager.anonymousLogin(true);
const connection = await connectionManager.connectToRoomSocket(process.env.ROOM_ID ? process.env.ROOM_ID : '_/global/maps.workadventure.localhost/Floor0/floor0.json', 'TEST', ['male3'],
{
x: 783,
y: 170
}, {
top: 0,
bottom: 200,
left: 500,
right: 800
});
const connection = await connectionManager.connectToRoomSocket();
connection.emitPlayerDetailsMessage('foo', ['male3']);
await connection.joinARoom('global__maps.workadventure.localhost/Floor0/floor0', 783, 170, 'down', true, {
top: 0,
bottom: 200,
left: 500,
right: 800
});
console.log(connection.getUserId());
let angle = Math.random() * Math.PI * 2;

File diff suppressed because it is too large Load diff