video-stream/main.py

30 lines
652 B
Python
Raw Normal View History

2021-10-29 18:47:52 +00:00
import asyncio
2021-11-02 08:36:57 +00:00
from program import BOT_ID, USERBOT_ID
2021-11-02 08:44:29 +00:00
from driver.veez import bot, user
2021-10-29 18:47:52 +00:00
from pytgcalls import idle
2021-11-02 08:44:29 +00:00
def all_info(bot, user):
2021-11-02 08:36:57 +00:00
global BOT_ID, USERBOT_ID
getme = bot.get_me()
getme1 = call_py.get_me()
BOT_ID = getme.id
USERBOT_ID = getme1.id
2021-10-29 18:47:52 +00:00
async def mulai_bot():
print("[INFO]: STARTING BOT CLIENT")
await bot.start()
print("[INFO]: STARTING PYTGCALLS CLIENT")
await call_py.start()
2021-11-02 08:36:57 +00:00
print("[INFO]: GENERATING CLIENT PROFILE")
2021-11-02 08:44:29 +00:00
all_info(bot, user)
2021-10-29 18:47:52 +00:00
await idle()
print("[INFO]: STOPPING BOT")
await bot.stop()
2021-10-29 20:19:54 +00:00
loop = asyncio.get_event_loop()
2021-10-29 18:47:52 +00:00
loop.run_until_complete(mulai_bot())