Did some cleaning, worked on notifications
This commit is contained in:
@ -5,12 +5,13 @@ import {createServer as httpServer} from 'http';
|
||||
import {addAuthRoutes} from './app/utilities/Http';
|
||||
import cors from 'cors';
|
||||
import {Server as SocketServer} from 'socket.io';
|
||||
import {TSocket} from "./app/types/TSocket";
|
||||
import {TSocket} from "./app/utilities/Types";
|
||||
import config from './app/utilities/Config';
|
||||
import prisma from './app/utilities/Prisma';
|
||||
import ZoneManager from "./app/ZoneManager";
|
||||
import UserManager from "./app/UserManager";
|
||||
import {Authentication} from "./app/middleware/Authentication";
|
||||
import CommandManager from "./app/CommandManager";
|
||||
|
||||
export class Server
|
||||
{
|
||||
@ -36,7 +37,7 @@ export class Server
|
||||
*/
|
||||
public async start() {
|
||||
// Print logo
|
||||
const art = fs.readFileSync(path.join(__dirname, 'app', 'logo.txt'), 'utf8');
|
||||
const art = fs.readFileSync(path.join(__dirname, 'logo.txt'), 'utf8');
|
||||
console.log('\x1b[31m%s\x1b[0m', art + '\n');
|
||||
|
||||
// Check prisma connection
|
||||
@ -64,6 +65,9 @@ export class Server
|
||||
// Load zone manager
|
||||
await ZoneManager.boot();
|
||||
|
||||
// Load command manager
|
||||
await CommandManager.boot();
|
||||
|
||||
// Listen for socket connections
|
||||
this.io.on('connection', this.handleConnection.bind(this));
|
||||
}
|
||||
|
Reference in New Issue
Block a user