Add a constants file so that we don't need to have constants in the class files.
This commit is contained in:
parent
03db868b7c
commit
16c9376a55
3 changed files with 21 additions and 3 deletions
|
|
@ -17,14 +17,15 @@ import { ChancellorPolicy } from "./events/ChancellorPolicy";
|
|||
import { PresidentPolicies } from "./events/PresidentPolicies";
|
||||
import { ChancellorNomination } from "./events/ChancellorNomination";
|
||||
import { ExecutiveConfirmation } from "./events/ExecutiveConfirmation";
|
||||
import { LOG_LEVEL, LOG_NAME, WSS_PORT } from "./constants";
|
||||
|
||||
export var log: Logger = new Logger({
|
||||
displayFunctionName: false,
|
||||
displayLoggerName: false,
|
||||
displayFilePath: `hidden`,
|
||||
displayLogLevel: true,
|
||||
minLevel: `silly`,
|
||||
name: `SecretHitler`,
|
||||
minLevel: LOG_LEVEL || `info`,
|
||||
name: LOG_NAME,
|
||||
});
|
||||
|
||||
export var active_games: {[key: string]: Game} = {};
|
||||
|
|
@ -50,7 +51,7 @@ function clean_up() {
|
|||
process.on(`uncaughtException`, clean_up);
|
||||
process.on('SIGINT', clean_up);
|
||||
|
||||
const io = sio.listen(3000);
|
||||
const io = sio.listen(WSS_PORT);
|
||||
|
||||
io.on(`connection`, (socket: sio.Socket) => {
|
||||
log.silly(`Client connected with id ${socket.id}`);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue