rhiever / TwitterFollowBot

A Python bot that automates several actions on Twitter, such as following users and favoriting tweets.
GNU General Public License v3.0
1.3k stars 448 forks source link

Can I run multiple action in the same .py? #119

Open DraxFTW opened 7 years ago

DraxFTW commented 7 years ago

for an example like this;

my_bot = TwitterBot() my_bot.auto_follow("@ShoutGamers")

from TwitterFollowBot import TwitterBot

my_bot = TwitterBot() my_bot.auto_fav("@ShoutGamers", count=1000)

will this both work? or just the top one.

rhiever commented 7 years ago

Yes, you can do that. You don't even need to create a new instance of the TwitterBot; you can just follow one function call with another:

from TwitterFollowBot import TwitterBot
my_bot = TwitterBot()
my_bot.auto_follow("@ShoutGamers")
my_bot.auto_fav("@ShoutGamers", count=1000)
ghost commented 7 years ago

Sorry for hijacking this post but what if you wanted to run 3 accounts to follow 1000 people each day. Could i put them all under one .py?

rhiever commented 7 years ago

Yes, if you create different TwitterBot instances pointing to your separate config files.

ghost commented 7 years ago

Thank you ive done that just worried that within the 24 hours each day the 3 accounts will not follow 1000 people each if that makes sense. If i put them all in one py will they all be following accounts at the same time or would it be one account following till 1000 before the next account starts following