forked from SealedSaucer/Online-Forever
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
17 lines (14 loc) · 813 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
import discord
import os
from keep_alive import keep_alive
from discord.ext import commands
name_of_stream_status = "Hello World" #Name that show on stream status, Ex : {username} streaming [...]
stream_link = "https://twitch.tv/CustomStreamLink" #Must be a twitch link only, nothing else will work
client = commands.Bot(command_prefix=':', self_bot=True, help_command=None)
@client.event
async def on_ready():
await client.change_presence(activity = discord.Streaming(name = f"{name_of_stream_status}", url = f"{stream_link}"))
os.system('clear')
print(f'Logged in as {client.user} (ID: {client.user.id})')
keep_alive()
client.run(os.getenv("TOKEN")) #Must be a secret on replit, if you are hosting this script without replit or if you have a hacker plan on, check for the code needed on the readme.md