fixed server start, changed game duration 20s

This commit is contained in:
evanpelle
2024-08-26 09:29:51 -07:00
parent 0797a72e35
commit 2d57b20227
2 changed files with 5 additions and 10 deletions
+2 -2
View File
@@ -20,10 +20,10 @@ export class DefaultConfig implements Config {
return 100
}
gameCreationRate(): number {
return 31.5 * 1000
return 20 * 1000
}
lobbyLifetime(): number {
return 30 * 1000
return 20 * 1000
}
theme(): Theme {return vintageTheme;}
}
+3 -8
View File
@@ -16,14 +16,9 @@ const app = express();
const server = http.createServer(app);
const wss = new WebSocketServer({server});
app.use(express.static(path.join(__dirname, '../../resources/styles'), {
setHeaders: (res, path, stat) => {
if (path.endsWith('.css')) {
res.set('Content-Type', 'text/css');
}
}
}));
// Serve static files from the 'out' directory
app.use(express.static(path.join(__dirname, '../../out')));
app.use(express.json())
const gm = new GameManager(getConfig())
// New GET endpoint to list lobbies