Merge branch 'develop' into usersLimit
# Conflicts: # back/src/Controller/IoSocketController.ts # front/src/Phaser/Game/GameScene.ts
This commit is contained in:
commit
4f8b315727
5 changed files with 542 additions and 1809 deletions
|
@ -6,7 +6,7 @@
|
|||
"scripts": {
|
||||
"tsc": "tsc",
|
||||
"dev": "ts-node-dev --respawn ./server.ts",
|
||||
"prod": "tsc && node ./dist/server.js",
|
||||
"prod": "tsc && node --max-old-space-size=4096 ./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",
|
||||
|
|
|
@ -109,6 +109,10 @@ export class GameRoom {
|
|||
}
|
||||
}
|
||||
|
||||
get isFull(): boolean {
|
||||
return this.users.size >= MAX_USERS_PER_ROOM;
|
||||
}
|
||||
|
||||
public isEmpty(): boolean {
|
||||
return this.users.size === 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue