From 2416b80a3951a62434bace0a3c8adcbca8fa0b42 Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 00:11:30 +0200 Subject: [PATCH 01/14] Added `pop_reminder` to `database.py`, so we can delete reminders by timestamp. --- database.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/database.py b/database.py index e8110e8..a39e496 100644 --- a/database.py +++ b/database.py @@ -261,6 +261,22 @@ async def pop_expired_reminders(self): rows = await cur.fetchall() await self.connection.commit() return rows + + async def pop_reminder(self, timestamp): + """Remove all reminders with the given timestamp from the database, returning the messages for displaying. + + Args: + timestamp (UserFriendlyTime): The time we use to filter by + + Returns: + list: A list of messages of each reminder we deleted. + """ + async with self.connection.cursor() as cur: + query = "DELETE FROM reminders WHERE timestamp = ? RETURNING message" + await cur.execute(query, (timestamp,)) + rows = await cur.fetchall() + await self.connection.commit() + return rows async def add_tempban(self, user_id, reason, timestamp): """Add a temporary ban for a user. The ban is stored in the database with the user's ID, reason, and expiration time. From 01fd8c7f34f8dae9299bd4202789d2a4c0a44c5e Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 00:13:55 +0200 Subject: [PATCH 02/14] Updated `pop_reminder`, as we don't necessarily need to retrive the message(s) of deleted reminders. --- database.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/database.py b/database.py index a39e496..26ba483 100644 --- a/database.py +++ b/database.py @@ -267,17 +267,12 @@ async def pop_reminder(self, timestamp): Args: timestamp (UserFriendlyTime): The time we use to filter by - - Returns: - list: A list of messages of each reminder we deleted. """ async with self.connection.cursor() as cur: query = "DELETE FROM reminders WHERE timestamp = ? RETURNING message" await cur.execute(query, (timestamp,)) - rows = await cur.fetchall() await self.connection.commit() - return rows - + async def add_tempban(self, user_id, reason, timestamp): """Add a temporary ban for a user. The ban is stored in the database with the user's ID, reason, and expiration time. From 23dbd0fb3c097da51ae4f0e4f3fe11f5623043c9 Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 00:18:14 +0200 Subject: [PATCH 03/14] Fixed bug where users would be able to delete every reminder, even if it is not theirs. --- database.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/database.py b/database.py index 26ba483..69bb472 100644 --- a/database.py +++ b/database.py @@ -262,15 +262,15 @@ async def pop_expired_reminders(self): await self.connection.commit() return rows - async def pop_reminder(self, timestamp): + async def pop_reminder(self, user_id, timestamp): """Remove all reminders with the given timestamp from the database, returning the messages for displaying. Args: timestamp (UserFriendlyTime): The time we use to filter by """ async with self.connection.cursor() as cur: - query = "DELETE FROM reminders WHERE timestamp = ? RETURNING message" - await cur.execute(query, (timestamp,)) + query = "DELETE FROM reminders WHERE user_id = ? AND timestamp = ? RETURNING message" + await cur.execute(query, (user_id, timestamp)) await self.connection.commit() async def add_tempban(self, user_id, reason, timestamp): From 48582631921a0786488796dc247654dff87553e5 Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 00:24:21 +0200 Subject: [PATCH 04/14] Update database.py --- database.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/database.py b/database.py index 69bb472..dd2217c 100644 --- a/database.py +++ b/database.py @@ -267,11 +267,13 @@ async def pop_reminder(self, user_id, timestamp): Args: timestamp (UserFriendlyTime): The time we use to filter by - """ + """ # Optionally returns int async with self.connection.cursor() as cur: query = "DELETE FROM reminders WHERE user_id = ? AND timestamp = ? RETURNING message" await cur.execute(query, (user_id, timestamp)) + # length = await len(await cur.fetchall()) await self.connection.commit() + # return lenght async def add_tempban(self, user_id, reason, timestamp): """Add a temporary ban for a user. The ban is stored in the database with the user's ID, reason, and expiration time. From 07f1fe091b072054546fa8b0bddc997393bff3be Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 00:28:23 +0200 Subject: [PATCH 05/14] Added `delete_reminders` to `reminders.py` --- cogs/reminders.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/cogs/reminders.py b/cogs/reminders.py index 6f080de..65c824d 100644 --- a/cogs/reminders.py +++ b/cogs/reminders.py @@ -53,5 +53,16 @@ async def check_reminders(self): # If the bot cannot send messages to the channel, skip it continue + @is_discord_member() + @commands.command(name='delete_reminder', aliased=['delreminder']) + async def delete_reminder(self, ctx, *, timestamp: UserFriendlyTime) -> None: + """Delete all reminders of the user with the given timestamp.""" + reminders = await self.bot.database.get_reminders(ctx.author.id) + if not reminders: + return await ctx.reply(f"{ctx.author.display_name}: You have no reminders to delete.") + + await self.bot.database.pop_reminder(ctx.author.id, timestamp) + await ctx.reply(f"{ctx.author.mention}: Reminder(s) deleted successfully.") # We could reply something like "@...: 4 Reminders deleted successfully." + async def setup(bot): - await bot.add_cog(Reminders(bot)) \ No newline at end of file + await bot.add_cog(Reminders(bot)) From c3667750ce09022446949d3af1ced879f81fd0f0 Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 12:28:47 +0200 Subject: [PATCH 06/14] Updated the reminder Database, and added the option to filter by key. --- database.py | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/database.py b/database.py index dd2217c..80acbff 100644 --- a/database.py +++ b/database.py @@ -56,6 +56,7 @@ async def connect(self): channel_id INTEGER, message TEXT, timestamp DATETIME + key TEXT )""" ) await cursor.execute( @@ -224,7 +225,7 @@ async def get_timers(self, user_id): await self.connection.commit() return rows - async def add_reminder(self, user_id, channel_id, message, timestamp): + async def add_reminder(self, *, user_id, channel_id, message, timestamp, key: str): """Add a reminder for a user. The reminder is stored in the database with the user's ID, message, and timestamp. Args: @@ -234,11 +235,11 @@ async def add_reminder(self, user_id, channel_id, message, timestamp): timestamp (datetime): The time when the reminder should be triggered """ async with self.connection.cursor() as cur: - query = "INSERT INTO reminders(user_id, channel_id, message, timestamp) VALUES(?, ?, ?, ?)" - await cur.execute(query, (user_id, channel_id, message, timestamp)) + query = "INSERT INTO reminders(user_id, channel_id, message, timestamp, key) VALUES(?, ?, ?, ?, \)" + await cur.execute(query, (user_id, channel_id, message, timestamp, key)) await self.connection.commit() - async def get_reminders(self, user_id): + async def get_reminders(self, user_id) -> list[tuple[str, str, str, str]]: # I suppose the DB just returns strings and not Python objects """Get all reminders for a user. The reminders are returned as a list of tuples with the message and timestamp of each reminder. Args: @@ -248,7 +249,7 @@ async def get_reminders(self, user_id): list: A list of tuples with the message, channel and timestamp of each reminder """ async with self.connection.cursor() as cur: - query = "SELECT message, channel_id, timestamp FROM reminders WHERE user_id = ?" + query = "SELECT message, channel_id, timestamp, key FROM reminders WHERE user_id = ?" await cur.execute(query, (user_id,)) rows = await cur.fetchall() return rows @@ -262,18 +263,17 @@ async def pop_expired_reminders(self): await self.connection.commit() return rows - async def pop_reminder(self, user_id, timestamp): - """Remove all reminders with the given timestamp from the database, returning the messages for displaying. + async def pop_reminder(self, *, user_id, key: str) -> None: + """Remove all reminders (from the user) with the given key from the database. Args: - timestamp (UserFriendlyTime): The time we use to filter by - """ # Optionally returns int + user_id (int): Theid of the user wanting to delete a reminder + key (str): The key we use to filter out the reminder + """ async with self.connection.cursor() as cur: - query = "DELETE FROM reminders WHERE user_id = ? AND timestamp = ? RETURNING message" - await cur.execute(query, (user_id, timestamp)) - # length = await len(await cur.fetchall()) + query = "DELETE FROM reminders WHERE user_id = ? AND key = ? RETURNING message" + await cur.execute(query, (user_id, key)) await self.connection.commit() - # return lenght async def add_tempban(self, user_id, reason, timestamp): """Add a temporary ban for a user. The ban is stored in the database with the user's ID, reason, and expiration time. From 55b943f55f8b3bec4c752a5c57db239c94cf8458 Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 12:30:20 +0200 Subject: [PATCH 07/14] Added keys to reminders, so we can filter them by a 6 long key. --- cogs/reminders.py | 27 ++++++++++++++++++++------- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/cogs/reminders.py b/cogs/reminders.py index 65c824d..133b98f 100644 --- a/cogs/reminders.py +++ b/cogs/reminders.py @@ -1,10 +1,15 @@ import discord from discord.ext import commands, tasks from datetime import datetime, timedelta +from random import choice +from string import ascii_lowercase, ascii_uppercase from util import is_discord_member from timeutil import UserFriendlyTime + +KEY_LEN: int = 6 + class Reminders(commands.Cog): def __init__(self, bot): self.bot = bot @@ -20,6 +25,7 @@ async def remind_me(self, ctx, *, time: UserFriendlyTime): channel_id=ctx.channel.id, message=message, timestamp=time.dt + key=''.join(choice(ascii_lowercase + ascii_uppercase, KEY_LEN)) ) await ctx.reply(f"{ctx.author.mention}: I will remind you at {time.dt.strftime('%Y-%m-%d %H:%M:%S')} UTC with the message: {message}") @@ -32,9 +38,9 @@ async def my_reminders(self, ctx): return await ctx.reply(f"{ctx.author.display_name}: You have no reminders set.") elif len(reminders) < 25: embed = discord.Embed(title=f"{ctx.author.display_name}'s Reminders", color=discord.Color.blue()) - for message, _, timestamp in reminders: + for message, _, timestamp, key in reminders: embed.add_field( - name=f"Reminder at {timestamp.strftime('%Y-%m-%d %H:%M:%S')}", + name=f"Reminder at {timestamp.strftime('%Y-%m-%d %H:%M:%S')}; key={key}", value=f"Message: {message}", inline=False ) @@ -55,14 +61,21 @@ async def check_reminders(self): @is_discord_member() @commands.command(name='delete_reminder', aliased=['delreminder']) - async def delete_reminder(self, ctx, *, timestamp: UserFriendlyTime) -> None: - """Delete all reminders of the user with the given timestamp.""" + async def delete_reminder(self, ctx, *, key: str) -> None: + """Delete all reminders of the user with the given key.""" + if len(key) != KEY_LEN: + return await ctx.reply(f"{ctx.author.display_name}: Key does not meet criteria, expected {KEY_LEN} long.") + + for char in key: + if not char in ascii_lowercase + ascii_uppercase: + return await ctx.reply(f"{ctx.author.display_name}: Key contains non alphabetical characters.") + reminders = await self.bot.database.get_reminders(ctx.author.id) if not reminders: return await ctx.reply(f"{ctx.author.display_name}: You have no reminders to delete.") - - await self.bot.database.pop_reminder(ctx.author.id, timestamp) - await ctx.reply(f"{ctx.author.mention}: Reminder(s) deleted successfully.") # We could reply something like "@...: 4 Reminders deleted successfully." + + await self.bot.database.pop_reminder(user_id=ctx.author.id, key=key) + await ctx.reply(f"{ctx.author.mention}: Reminder( deleted successfully.") async def setup(bot): await bot.add_cog(Reminders(bot)) From e2ed92cb76f91f9cf334a6983d03d621c7c390e0 Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 12:32:44 +0200 Subject: [PATCH 08/14] Update reminders.py --- cogs/reminders.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cogs/reminders.py b/cogs/reminders.py index 133b98f..c49b43f 100644 --- a/cogs/reminders.py +++ b/cogs/reminders.py @@ -25,7 +25,7 @@ async def remind_me(self, ctx, *, time: UserFriendlyTime): channel_id=ctx.channel.id, message=message, timestamp=time.dt - key=''.join(choice(ascii_lowercase + ascii_uppercase, KEY_LEN)) + key=''.join(choice(ascii_lowercase + ascii_uppercase, k=KEY_LEN)) ) await ctx.reply(f"{ctx.author.mention}: I will remind you at {time.dt.strftime('%Y-%m-%d %H:%M:%S')} UTC with the message: {message}") From bd22c54d256318ed625b63cfeef392f79ff6863d Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 17:01:13 +0200 Subject: [PATCH 09/14] Update reminders.py (see seb's reply) --- cogs/reminders.py | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/cogs/reminders.py b/cogs/reminders.py index c49b43f..7d3511b 100644 --- a/cogs/reminders.py +++ b/cogs/reminders.py @@ -7,9 +7,6 @@ from util import is_discord_member from timeutil import UserFriendlyTime - -KEY_LEN: int = 6 - class Reminders(commands.Cog): def __init__(self, bot): self.bot = bot @@ -25,7 +22,7 @@ async def remind_me(self, ctx, *, time: UserFriendlyTime): channel_id=ctx.channel.id, message=message, timestamp=time.dt - key=''.join(choice(ascii_lowercase + ascii_uppercase, k=KEY_LEN)) + key=''.join(choice(ascii_lowercase + ascii_uppercase, k=ctx.bot.config["reminder_key_length"])) ) await ctx.reply(f"{ctx.author.mention}: I will remind you at {time.dt.strftime('%Y-%m-%d %H:%M:%S')} UTC with the message: {message}") @@ -63,9 +60,6 @@ async def check_reminders(self): @commands.command(name='delete_reminder', aliased=['delreminder']) async def delete_reminder(self, ctx, *, key: str) -> None: """Delete all reminders of the user with the given key.""" - if len(key) != KEY_LEN: - return await ctx.reply(f"{ctx.author.display_name}: Key does not meet criteria, expected {KEY_LEN} long.") - for char in key: if not char in ascii_lowercase + ascii_uppercase: return await ctx.reply(f"{ctx.author.display_name}: Key contains non alphabetical characters.") @@ -73,9 +67,12 @@ async def delete_reminder(self, ctx, *, key: str) -> None: reminders = await self.bot.database.get_reminders(ctx.author.id) if not reminders: return await ctx.reply(f"{ctx.author.display_name}: You have no reminders to delete.") + + if not any(reminder[3] == key for reminder in reminders): + return await ctx.reply(f"{ctx.author.display_name}: {key} not valid for any of your reminders.") - await self.bot.database.pop_reminder(user_id=ctx.author.id, key=key) - await ctx.reply(f"{ctx.author.mention}: Reminder( deleted successfully.") + await self.bot.database.pop_reminder(user_id=ctx.author.id, key=key) + await ctx.reply(f"{ctx.author.mention}: Reminder deleted successfully.") async def setup(bot): await bot.add_cog(Reminders(bot)) From 28ed6a65b675779ecb47059549b8e20ea4d224c6 Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 17:01:55 +0200 Subject: [PATCH 10/14] Update config.example.yaml (see the config for key length) --- config.example.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/config.example.yaml b/config.example.yaml index b63995a..9cfc08b 100644 --- a/config.example.yaml +++ b/config.example.yaml @@ -8,6 +8,7 @@ autosub_forums: - 1026904572293287936 - 1022293381705125968 ingame_regex: '^`[A-Za-z]+` \*\*([A-Za-z0-9_\\]+)\*\*: *(.*)$' +reminder_key_length: 6 notifications: - name: "🇸urvival" description: "Survival updates" From 1ef65426212e653ed9e4952a135190715e39631e Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 17:05:02 +0200 Subject: [PATCH 11/14] Update database.py --- database.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/database.py b/database.py index 80acbff..678f179 100644 --- a/database.py +++ b/database.py @@ -55,7 +55,7 @@ async def connect(self): user_id INTEGER, channel_id INTEGER, message TEXT, - timestamp DATETIME + timestamp DATETIME, key TEXT )""" ) @@ -263,11 +263,11 @@ async def pop_expired_reminders(self): await self.connection.commit() return rows - async def pop_reminder(self, *, user_id, key: str) -> None: - """Remove all reminders (from the user) with the given key from the database. + async def delete_reminder(self, *, user_id, key: str) -> None: + """Remove reminder from the user, filtered by key, from the database. Args: - user_id (int): Theid of the user wanting to delete a reminder + user_id (int): The id of the user wanting to delete a reminder key (str): The key we use to filter out the reminder """ async with self.connection.cursor() as cur: From 2b5bc107cf8bc72320b49662ed502ac19d986fee Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Thu, 7 Aug 2025 17:05:26 +0200 Subject: [PATCH 12/14] Update reminders.py --- cogs/reminders.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cogs/reminders.py b/cogs/reminders.py index 7d3511b..a96ea22 100644 --- a/cogs/reminders.py +++ b/cogs/reminders.py @@ -71,7 +71,7 @@ async def delete_reminder(self, ctx, *, key: str) -> None: if not any(reminder[3] == key for reminder in reminders): return await ctx.reply(f"{ctx.author.display_name}: {key} not valid for any of your reminders.") - await self.bot.database.pop_reminder(user_id=ctx.author.id, key=key) + await self.bot.database.delete_reminder(user_id=ctx.author.id, key=key) await ctx.reply(f"{ctx.author.mention}: Reminder deleted successfully.") async def setup(bot): From d43d694109f2cedba43743bf04fb2b4e2948b9ea Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Sun, 10 Aug 2025 11:42:19 +0200 Subject: [PATCH 13/14] Slightly updated some code, although we fail with an index error in `notifications.py`. --- .env.example | 1 - cogs/notifications.py | 2 +- cogs/reminders.py | 6 ++--- config.example.yaml | 59 ------------------------------------------- latest.log | 0 5 files changed, 4 insertions(+), 64 deletions(-) delete mode 100644 .env.example delete mode 100644 config.example.yaml create mode 100644 latest.log diff --git a/.env.example b/.env.example deleted file mode 100644 index f74c661..0000000 --- a/.env.example +++ /dev/null @@ -1 +0,0 @@ -TOKEN= \ No newline at end of file diff --git a/cogs/notifications.py b/cogs/notifications.py index 0bbb947..4b01b08 100644 --- a/cogs/notifications.py +++ b/cogs/notifications.py @@ -28,7 +28,7 @@ class NotificationsView(discord.ui.View): def __init__(self, bot, categories): super().__init__() self.bot = bot - + print(self.bot.guilds) # del this line (but keep empty) for category in categories: role = self.bot.guilds[0].get_role(category["role"]) self.add_item(RoleButton(role)) diff --git a/cogs/reminders.py b/cogs/reminders.py index a96ea22..588f821 100644 --- a/cogs/reminders.py +++ b/cogs/reminders.py @@ -21,7 +21,7 @@ async def remind_me(self, ctx, *, time: UserFriendlyTime): user_id=ctx.author.id, channel_id=ctx.channel.id, message=message, - timestamp=time.dt + timestamp=time.dt, key=''.join(choice(ascii_lowercase + ascii_uppercase, k=ctx.bot.config["reminder_key_length"])) ) await ctx.reply(f"{ctx.author.mention}: I will remind you at {time.dt.strftime('%Y-%m-%d %H:%M:%S')} UTC with the message: {message}") @@ -63,14 +63,14 @@ async def delete_reminder(self, ctx, *, key: str) -> None: for char in key: if not char in ascii_lowercase + ascii_uppercase: return await ctx.reply(f"{ctx.author.display_name}: Key contains non alphabetical characters.") - + reminders = await self.bot.database.get_reminders(ctx.author.id) if not reminders: return await ctx.reply(f"{ctx.author.display_name}: You have no reminders to delete.") if not any(reminder[3] == key for reminder in reminders): return await ctx.reply(f"{ctx.author.display_name}: {key} not valid for any of your reminders.") - + await self.bot.database.delete_reminder(user_id=ctx.author.id, key=key) await ctx.reply(f"{ctx.author.mention}: Reminder deleted successfully.") diff --git a/config.example.yaml b/config.example.yaml deleted file mode 100644 index 9cfc08b..0000000 --- a/config.example.yaml +++ /dev/null @@ -1,59 +0,0 @@ -channels: - welcome: 708732557453426728 - gamechat: 597852843785060357 - notifications: 701813343530254346 - audit_log: 1213536691902742618 - automod: 1213536691902742618 -autosub_forums: - - 1026904572293287936 - - 1022293381705125968 -ingame_regex: '^`[A-Za-z]+` \*\*([A-Za-z0-9_\\]+)\*\*: *(.*)$' -reminder_key_length: 6 -notifications: - - name: "🇸urvival" - description: "Survival updates" - role: 701802551175282759 - - name: "🇺pdates" - description: "Network updates" - role: 702192714862821485 - - name: "🇨ompetitor" - description: "Competition involvement" - role: 755068314186940486 - - name: "🇵oL" - description: "Plot o' Logic Revamp" - role: 846135848226652191 - - name: "🇹rial" - description: "Get notified by Staff for trials" - role: 1295904929378074725 -roles: - trusted: 962782039403298887 - staff: 617848463438118922 - admin: 117711708847472645 -fractalDeets: - size: 2048 - maxIterations: 10000 - messiness: 30 - zoom: 3.5 -automod_regexes: - - "^test(ing)?$" - - "f[0o]+" -logging: - level: "WARN" # one of: INFO, WARN, ERROR, CRITICAL - file: "latest.log" # Filename. Will not produce files when this field is empty - amount_files: 5 # How many files to keep -greetings: - - "Welcome to ORE, {user}! Make sure to run `/discord` ingame and link your account to view the rest of DiscOREd!" - - "Oh hi, {user}! Run `/discord` ingame to link your account to view the rest of DiscOREd!" - - "Welcome, {user}! To see the rest of our DiscOREd, link your account by running `/discord` ingame!" -insults: - - "once in the 4th grade {user} got a 2% on their math quiz so everyone called them milk for the rest of the year" - - "{user} may look like an idiot and talk like an idiot but don't let that fool you. {user} really is an idiot." - - "{user}, you warthog-faced buffoon." - - "{user}, I fart in your general direction. Your mother was a hamster and your father smelt of elderberries." - - "{user} has no enemies, but is intensely disliked by their friends." - - "{user} is a cockalorum." - - "{user} ........ pillock." - - "{user} is more disappointing than an unsalted pretzel." - - "{user} is the reason God created the middle finger." - - "I’ll never forget the first time I met {user}. But I’ll keep trying." - - "Hold still. I’m trying to imagine {user} with a personality." diff --git a/latest.log b/latest.log new file mode 100644 index 0000000..e69de29 From e79c53f83a78bf737e33292b74de50196048d4b3 Mon Sep 17 00:00:00 2001 From: JoBe <165585785+JoBeGaming@users.noreply.github.com> Date: Sun, 7 Dec 2025 13:56:27 +0100 Subject: [PATCH 14/14] Create config.example.yaml Copied this from https://github.com/OpenRedstoneEngineers/Patrick/tree/main, so the PR can be merged easier. --- config.example.yaml | 62 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) create mode 100644 config.example.yaml diff --git a/config.example.yaml b/config.example.yaml new file mode 100644 index 0000000..17db6ea --- /dev/null +++ b/config.example.yaml @@ -0,0 +1,62 @@ +channels: + welcome: 708732557453426728 + gamechat: 597852843785060357 + notifications: 701813343530254346 + audit_log: 1213536691902742618 + automod: 1213536691902742618 +autosub_forums: + - 1026904572293287936 + - 1022293381705125968 +ingame_regex: '^`[A-Za-z]+` \*\*([A-Za-z0-9_\\]+)\*\*: *(.*)$' +notifications: + - name: "🇸urvival" + description: "Survival updates" + role: 701802551175282759 + - name: "🇺pdates" + description: "Network updates" + role: 702192714862821485 + - name: "🇨ompetitor" + description: "Competition involvement" + role: 755068314186940486 + - name: "🇵oL" + description: "Plot o' Logic Revamp" + role: 846135848226652191 + - name: "🇹rial" + description: "Get notified by Staff for trials" + role: 1295904929378074725 +roles: + trusted: 962782039403298887 + staff: 617848463438118922 + admin: 117711708847472645 +fractalDeets: + size: 2048 + maxIterations: 10000 + messiness: 30 + zoom: 3.5 +spirographDeets: + height: 2000 + width: 2000 + length: 1000 +automod_regexes: + - "^test(ing)?$" + - "f[0o]+" +logging: + level: "WARN" # one of: INFO, WARN, ERROR, CRITICAL + file: "latest.log" # Filename. Will not produce files when this field is empty + amount_files: 5 # How many files to keep +greetings: + - "Welcome to ORE, {user}! Make sure to run `/discord` ingame and link your account to view the rest of DiscOREd!" + - "Oh hi, {user}! Run `/discord` ingame to link your account to view the rest of DiscOREd!" + - "Welcome, {user}! To see the rest of our DiscOREd, link your account by running `/discord` ingame!" +insults: + - "once in the 4th grade {user} got a 2% on their math quiz so everyone called them milk for the rest of the year" + - "{user} may look like an idiot and talk like an idiot but don't let that fool you. {user} really is an idiot." + - "{user}, you warthog-faced buffoon." + - "{user}, I fart in your general direction. Your mother was a hamster and your father smelt of elderberries." + - "{user} has no enemies, but is intensely disliked by their friends." + - "{user} is a cockalorum." + - "{user} ........ pillock." + - "{user} is more disappointing than an unsalted pretzel." + - "{user} is the reason God created the middle finger." + - "I’ll never forget the first time I met {user}. But I’ll keep trying." + - "Hold still. I’m trying to imagine {user} with a personality."