Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multibots #36

Closed
splexas opened this issue Mar 3, 2021 · 1 comment
Closed

multibots #36

splexas opened this issue Mar 3, 2021 · 1 comment

Comments

@splexas
Copy link

splexas commented Mar 3, 2021

any ideas how to run multiple bots at the same time?

@Merubokkusu
Copy link
Owner

Merubokkusu commented Mar 3, 2021

Personally I use sub processes


arandomnewaccount:
yep, also refer to issue #22 for some help on multitoken support.
And..if you want to speed up client initialization quite a bit (only request for build number once), you can do something like this:

bot = discum.Client(token=tokenlist[0])
build_num = bot._Client__super_properties['client_build_number']
clients = [bot]
for token in tokenlist[1:]:
    clients.append(discum.Client(token=token, build_num=build_num))

edit:
added a full example here:
https://github.com/Merubokkusu/Discord-S.C.U.M/blob/master/examples/multibots.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@Merubokkusu @splexas and others