StampyAI / stampy

A Discord bot for the Robert Miles AI server

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Wanted: supporting multiple Discord guilds simultaneously

ProducerMatt opened this issue · comments

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.

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