async def on_ready(): ''' Shows that the bot's running when we run this program. ''' await hat.change_presence(game = Game(name = 'with Dumbledore')) print("Bot Logging In!") print("Bot ID: " + hat.user.id) print(hat.user.name + " is ready!")
def on_ready(self): print("Bot is logged in succesfully. Running on servers: \n") for s in self.client.servers: print(" - %s (%s)" % (s.name, s.id)) if 'presence_game' in self.config['bot']: yield from self.client.change_presence(game=Game( name=self.config['bot']['presence_game']))
async def change_presence_loop(): await client.wait_until_ready() await asyncio.sleep(4) while not client.is_closed: now_playing = random.choice(playing) print("Now Playing: " + now_playing) await client.change_presence(game=Game(name=now_playing)) await asyncio.sleep(60 * 60) # change every hour
async def ex(message, client): author = message.author content = message.content channel = message.channel global customenabled args = " ".join(content.split()[1:]) if customenabled and (args.startswith("off") or args.startswith("disable")): customenabled = False await client.send_message(channel, embed=Embed(description="Disbaled custom botmessage.")) await client.change_presence(game=Game(name=functions.get_members_msg(client))) else: await client.send_message(channel, embed=Embed(description="%s changed bot message to `%s`." % (author.mention, args), color=Color.blue())) await client.change_presence(game=Game(name=args + " | !help")) customenabled = True
async def on_ready(self): LOG.info('Logged in as {}'.format(self.bot.user.name)) await self.bot.change_presence( status=discord.Status.online, activity=Game('Waking up, making coffee...')) self.bot.loop.create_task(utils.change_status(self.bot)) self.bot.loop.create_task(utils.list_servers(self.bot)) self.bot.loop.create_task(utils.list_users(self.bot))
async def poke(ctx): """ Commands related to interacting with wild pokemon. """ await pokemaster_bot.change_presence(game=Game( name='!help for command info')) if ctx.invoked_subcommand is None: await pokemaster_bot.say("Invalid Command")
async def on_ready(): #print (suBot.retServId(1), type(suBot.retServId(1))) #Server = client.get_server(suBot.retServId(1)) #me = Server.get_member(suBot.myId()) await client.send_message(me, "```Online at:\t"+str(datetime.datetime.now())+"```") await client.change_presence(game=Game(name="with my creator")) print ("Logged in as " + client.user.name)
async def on_ready(): await bot.change_presence(game=Game(name="with Western Spy")) print("BLIN THIS BOT WORKS!") print("OPA BOT NAME: " + bot.user.name) print("OPA BOT ID: " + bot.user.id) print("BLIN DIRECTORY IS: " + os.getcwd()) print("--------------------------------------") print("bot made by: bitran")
async def presenceTask(self): timeLeft = self.utility.timeUntil("optime") minutes = (timeLeft.seconds // 60) % 60 minuteZero = "0" if minutes < 10 else "" presenceString = "{}:{}{}:00 until optime".format( timeLeft.seconds // 3600, minuteZero, minutes) await self.bot.change_presence(activity=Game(name=presenceString))
async def on_ready(): serverList = client.servers await client.change_presence(game=Game(name="| $help | $git |")) print("\nLogged in as " + client.user.name) for server in serverList: if not server.id in authServerList: await client.leave_server(client.get_server(server.id)) print("\nLeft Server :: " + server.name)
async def on_ready(self): await self.bot.change_presence(activity=Game(name=config.game)) print('#' * 50) print(f'Id: {self.bot.user.id:d}') print(f'Name: {self.bot.user.name}#{self.bot.user.discriminator}') print(f"Guilds: {', '.join(guild.name for guild in self.bot.guilds)}") print('#' * 50)
async def on_ready(): await bot.change_presence(game=Game(name="Censorship Machine with the EU")) print ("Starting this shit. V2") print ("user.name: " + bot.user.name) print ("user.id: " + bot.user.id) print ("directory is: " + os.getcwd()) print ("--------------------------------------") print ("bot made by: bitran")
async def updatePresence(): try: with open('queryCount.log', 'r') as rf: queries = rf.read() activity = Game(f"with {queries} answers") await bot.change_presence(activity=activity) except: fprint("presence update failed!")
async def on_ready(): await client.change_presence(game=Game(name="!help")) print('Eingeloggt als') print(client.user.name) print(client.user.id) print('-----------')
async def on_ready(): await client.change_presence(game=Game( name="~help ¦ ~invite", url="https://www.twitch.tv/avibn", type=1)) print("Logged in as " + client.user.name) print("Currently active on " + str(len(client.servers)) + " servers.") while True: await client.change_presence(game=Game( name="~help ¦ ~invite", url="https://www.twitch.tv/avibn", type=1)) # await client.change_presence(game=Game(name="..help ¦ ..invite", type=3)) await asyncio.sleep(20) await client.change_presence( game=Game(name=" {} Guilds.".format(len(client.servers)), url="https://www.twitch.tv/avibn", type=1)) # await client.change_presence(game=Game(name="{} guilds".format(len(client.servers)), type=3)) await asyncio.sleep(10) await asyncio.sleep(600)
async def set_bot_playing(message, client, arguments): if message.author.id not in owners: return else: await client.change_presence(game=Game(name=arguments)) send(1, "Updating playing status!") return
async def status(self, ctx: Context, *, status: str): """Set the bot to 'Playing <status>'.""" activity = Game(name=status) try: await self.bot.change_presence(activity=activity) await ctx.send(":white_check_mark: Status changed.") except Exception as e: await ctx.send(f":anger: Unable to change status: {e}")
async def on_ready(): await client.change_presence(activity=Game(CONFIG['activity'])) # Scrub dead links on start channel = client.get_channel(CONFIG['tree-channel-id']) async for message in channel.history(limit=1000): if message.author == client.user: await message.delete()
async def on_ready(): print('Logged in as') print(bot.user.name) print(bot.user.id) print('------') game = Game() game.name = '~help' await bot.change_status(game=game)
async def change_status(self, name): log.debug("Changing status to {}".format(name)) log_to_file("Changing status to {}".format(name)) shards = list(self.client.shards.keys()) for shard_id in shards: customized = name + " | shard {}".format(shard_id + 1) await self.client.change_presence(game=Game(name=customized, type=0), shard_id=shard_id)
async def change_status(): await bot.wait_until_ready() msg = cycle(status) while not bot.is_closed: current_status = next(msg) await bot.change_presence(game=Game(name=current_status)) await asyncio.sleep(120)
def on_ready(): print( "Bot hat sich erfolgreich einngeloggt, der Bot laeuft derzeit auf folgenden Servern:\n" ) for s in client.servers: print(" - %s (%s)" % (s.name, s.id)) yield from client.change_presence(game=Game( name="Assistant Bot Ps: Hilft dir gerne xD"))
async def on_ready(): bot.start_gw = 23 bot.base_padding = 3 bootstrap(bot) await bot.change_presence(status=Status.idle, activity=Game("Alfred")) logging.info('Bot is now online!') logging.info('Current Gameweek: %s', str(bot.gameweek_id)) print('Current Gameweek: %s', str(bot.gameweek_id)) print(bot.start, bot.end)
async def change_presence(self) -> None: """Slow scrolling effect for "Playing" status message.""" await self.bot.wait_until_ready() while not self.bot.is_closed(): self.current_status = self._reorder_text(self.current_status) await self.bot.change_presence(activity=Game(self.current_status)) await asyncio.sleep(7)
async def on_ready(self): await self.bot.change_presence(activity=Game(name=random.choice(self.game_list))) try: print("Scheduling random game status changer.") self.bot.loop.create_task(self.PlayRandomGame(self.interval)) except RuntimeError: print('Could not schedule random now playing game change.') traceback.format_exc()
async def on_ready(): # This sets the bot's game status to make it read "Playing with Fire" # Which is a reference to my favorite Major League Soccer team, Chicago Fire await client.change_presence(game=Game(name="with Fire")) print('Logged in as') print(client.user.name) print(client.user.id) print('------')
async def on_ready(self): activity = Game("prefix: " + Settings.DEFAULT_SETTINGS["prefix"]) await self.bot.change_presence(activity=activity) logging.info("Bot is ready") for guild in self.bot.guilds: moderations, _ = crud.get_all_moderations(guild.id, revoked=False) for moderation in moderations: create_task(revoke_moderation(guild, moderation))
async def on_ready(): print('Bot Online') await client.change_presence(activity=Game(name="with Finesse")) print('Logged in as ' + client.user.name) print('Current servers: ') for guild in client.guilds: print(guild.name, guild.id)
async def on_ready(): print('Logged in as') print(bot.user.name) print(bot.user.id) f = open("config/playing.txt", "r") game = f.read() f.close await bot.change_presence(game=Game(name=game))
async def on_connect(): print(f'Bot connected as {bot.user}') # Setting `Playing ` status await bot.change_presence(activity=Game(name='Grand Theft Auto: Emily Dickinson Edition')) try: if bot.SESSION.closed: bot.SESSION = aiohttp.ClientSession() except AttributeError: bot.SESSION = aiohttp.ClientSession()