From 347e925af712eab771b6df9c7ca1f3a16738228b Mon Sep 17 00:00:00 2001 From: shoopea Date: Sat, 16 Nov 2024 18:27:47 +0100 Subject: [PATCH] update arms race --- cfg/live_arms_race.cfg | 1 + public/js/console.js | 2 +- routes/game.js | 7 ++++--- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/cfg/live_arms_race.cfg b/cfg/live_arms_race.cfg index f84a70a..6bc620d 100644 --- a/cfg/live_arms_race.cfg +++ b/cfg/live_arms_race.cfg @@ -1,5 +1,6 @@ ammo_grenade_limit_flashbang 1 ammo_grenade_limit_total 3 +bot_quota 0 cash_player_bomb_defused 0 cash_player_bomb_planted 0 cash_player_damage_hostage 0 diff --git a/public/js/console.js b/public/js/console.js index d8feb81..4053a7a 100644 --- a/public/js/console.js +++ b/public/js/console.js @@ -246,7 +246,7 @@ $(document).ready(function () { map_list.push("de_vertigo"); map_list.push("de_whistle"); } else if (e.value == "6") { // arms race - map_list.push("ar_bagage"); + map_list.push("ar_baggage"); map_list.push("ar_pool_day"); map_list.push("ar_shoots"); } diff --git a/routes/game.js b/routes/game.js index 2bd1263..63e6292 100644 --- a/routes/game.js +++ b/routes/game.js @@ -59,9 +59,6 @@ router.post('/api/setup-game', is_authenticated, async (req, res) => { await rcon.execute_command(server_id, `game_mode 0`); await rcon.execute_command(server_id, `sv_skirmish_id 10`); execute_cfg_on_server(server_id, './cfg/live_arms_race.cfg'); - setTimeout(() => { - rcon.execute_command(server_id, `mp_restartgame 1`); - }, 20000) } await rcon.execute_command(server_id, `changelevel ${map}`); @@ -75,6 +72,10 @@ router.post('/api/setup-game', is_authenticated, async (req, res) => { setTimeout(() => { execute_cfg_on_server(server_id, './cfg/warmup_24.cfg'); }, 1000) + } else if (game == "6") { + setTimeout(() => { + rcon.execute_command(server_id, `mp_restartgame 20`); + }, 1000) } return res.status(200).json({ message: 'Game Created!' });