wrightedu / CSE-Discord-Bot

Discord bot for the WSU CSE Discord server
GNU General Public License v3.0
2 stars 4 forks source link

Convert role buttons to use custom_ids #303

Open JakeHamblin opened 2 months ago

JakeHamblin commented 2 months ago

Who are you? CSE Dev

What feature do you want? Convert the button menus to use custom_ids

Why do you want this feature? By using custom_ids, we can negate the use of hard-lined interactions, allowing the bot to restart without losing or dropping interactions, requiring role menus to be recreated.

Additional context Will assign custom_ids as something along the lines of add_role_{role id}. With this, we can create an event that listens for interactions and checks the custom id. IE: if "add_role_" in custom_id. If it appears. use a regular expression to pull the ID from the string and add that role.