StampyAI / stampy

A Discord bot for the Robert Miles AI server
37 stars 9 forks source link

Wanted: supporting multiple Discord guilds simultaneously #308

Open ProducerMatt opened 1 year ago

ProducerMatt commented 1 year ago

Would be nice for one Stampy instance to connect to multiple Discord guilds.

at first I thought this would require a bottom-up rewrite. But I quickly realized that most of the messages sent through the system don't care what Guild it's in, they usually just need the text and the channel. The fact that channel IDs are unique across servers is vital to this.

Where it becomes more complicated is regarding certain modules like the stamp collecting, reply management, and factoid saving. In these cases we wouldn't want the functions to return the same result across servers, so they need to be aware of the guild. This raises the question of how currently existing databases (Factoid database, Stamp database, etc) could be migrated to record which guild is being tracked with each message.

ProducerMatt commented 3 months ago

This feature is available in the new Elixir codebase: https://github.com/ProducerMatt/stampede