added delay for running commands in rcon channel, updated scraping to be even more generic.

This commit is contained in:
jenz
2022-06-25 13:40:30 +02:00
parent 0c45287ae6
commit e2795c8edc
2 changed files with 50 additions and 39 deletions
@@ -3,6 +3,7 @@
import discord
from datetime import datetime
from discord.ext.tasks import loop
from time import sleep
from settings import get_connection_event, token
intents = discord.Intents.default()
@@ -77,6 +78,8 @@ async def discord_task():
#silly white space none sense
if len(map) > 3:
cooldown_msg = f"""sm_nominate_exclude_time {map} 1 0"""
#adding slight delay
sleep(1)
await r.send(cooldown_msg)
conn.commit()