Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

### Deploy To Heroku</h4>

[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy?template=https://github.com/Infinity-Bots/GroupMusicPlayerBot)
[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy?template=https://github.com/executor99/GroupMusicPlayerBot)

Use [Repl Link](https://replit.com/@SpEcHiDe/GenerateStringSession) to get pyrogram string session

Expand Down
2 changes: 1 addition & 1 deletion app.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "Music Bot",
"description": "Open-Source bot to play songs in your Telegram's Group Voice Chat. Powered by PyTgCalls.",
"keywords": ["music", "voicechat", "telegram"],
"repository": "https://github.com/ImJanindu/GroupMusicBot",
"repository": "https://github.com/executor99/GroupMusicPlayerBot",
"stack": "container",
"env": {
"SESSION_NAME": {
Expand Down
16 changes: 8 additions & 8 deletions handlers/admins.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ async def pause(_, message: Message):
) or (
callsmusic.pytgcalls.active_calls[message.chat.id] == 'paused'
):
await message.reply_text("❗ Nothing is playing!")
await message.reply_text("❗ Kalau ga ada ya ga ada bangsat ngeyel bener hidup lu!")
else:
callsmusic.pytgcalls.pause_stream(message.chat.id)
await message.reply_text("▶️ Paused!")
await message.reply_text("▶️ Lagunya di Paused!")


@Client.on_message(command("resume") & other_filters)
Expand All @@ -33,34 +33,34 @@ async def resume(_, message: Message):
) or (
callsmusic.pytgcalls.active_calls[message.chat.id] == 'playing'
):
await message.reply_text("❗ Nothing is paused!")
await message.reply_text("❗ Ga ada yang di pause tolol!")
else:
callsmusic.pytgcalls.resume_stream(message.chat.id)
await message.reply_text("⏸ Resumed!")
await message.reply_text("⏸ Oke mari kita dengarkan lagi!")


@Client.on_message(command("end") & other_filters)
@errors
@authorized_users_only
async def stop(_, message: Message):
if message.chat.id not in callsmusic.pytgcalls.active_calls:
await message.reply_text("❗ Nothing is streaming!")
await message.reply_text("❗ Ngeyel lu anjing!")
else:
try:
callsmusic.queues.clear(message.chat.id)
except QueueEmpty:
pass

callsmusic.pytgcalls.leave_group_call(message.chat.id)
await message.reply_text("❌ Stopped streaming!")
await message.reply_text("❌ Lagunya di stop jangan tolol!")


@Client.on_message(command("skip") & other_filters)
@errors
@authorized_users_only
async def skip(_, message: Message):
if message.chat.id not in callsmusic.pytgcalls.active_calls:
await message.reply_text("❗ Nothing is playing to skip!")
await message.reply_text("❗ Ga ada yang perlu di skip!")
else:
callsmusic.queues.task_done(message.chat.id)

Expand All @@ -72,4 +72,4 @@ async def skip(_, message: Message):
callsmusic.queues.get(message.chat.id)["file"]
)

await message.reply_text("➡️ Skipped the current song!")
await message.reply_text("➡️ Lagunya di skip ya tolol!")
20 changes: 10 additions & 10 deletions handlers/play.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,15 +92,15 @@ async def generate_cover(requested_by, title, views, duration, thumbnail):
& ~filters.via_bot)
async def play(_, message: Message):

lel = await message.reply("🔄 **Processing...**")
lel = await message.reply("🔄 **Tunggu lagunya lagi di cari...**")

administrators = await get_administrators(message.chat)
chid = message.chat.id

try:
user = await USER.get_me()
except:
user.first_name = "Mizuki"
user.first_name = "Memew"
usar = user
wew = usar.id
try:
Expand All @@ -112,13 +112,13 @@ async def play(_, message: Message):
invitelink = await _.export_chat_invite_link(chid)
except:
await lel.edit(
"<b>Add me as admin of yor group first!</b>")
"<b>Jadikan saya admin di groupmu untuk memulai!</b>")
return

try:
await USER.join_chat(invitelink)
await USER.send_message(
message.chat.id, "**Mizuki Music assistant joined this group for play music 🎵**")
message.chat.id, "**Memew Music assistant telah join dan siap memutar musik 🎵**")

except UserAlreadyParticipant:
pass
Expand Down Expand Up @@ -153,7 +153,7 @@ async def play(_, message: Message):
[
InlineKeyboardButton(
text="Channel 🔊",
url="https://t.me/Infinity_BOTs")
url="https://t.me/ohempty")

]
]
Expand Down Expand Up @@ -201,7 +201,7 @@ async def play(_, message: Message):
)
except Exception as e:
title = "NaN"
thumb_name = "https://telegra.ph/file/638c20c44ca418c8b2178.jpg"
thumb_name = "https://telegra.ph/file/6b4d999e0897fe457d797.jpg"
duration = "NaN"
views = "NaN"
keyboard = InlineKeyboardMarkup(
Expand All @@ -215,18 +215,18 @@ async def play(_, message: Message):
]
)
if (dur / 60) > DURATION_LIMIT:
await lel.edit(f"❌ Videos longer than {DURATION_LIMIT} minutes aren't allowed to play!")
await lel.edit(f"❌ Ga bisa di putar anjing karna durasi kepanjangan {DURATION_LIMIT} minutes aren't allowed to play!")
return
requested_by = message.from_user.first_name
await generate_cover(requested_by, title, views, duration, thumbnail)
file_path = await converter.convert(youtube.download(url))
else:
if len(message.command) < 2:
return await lel.edit("🧐 **What's the song you want to play?**")
await lel.edit("🔎 **Finding the song...**")
await lel.edit("🔎 **Lagu nya sudah di temukan sabar...**")
query = message.text.split(None, 1)[1]
# print(query)
await lel.edit("🎵 **Processing sounds...**")
await lel.edit("🎵 **Bentar anjing lagi di proses nih...**")
try:
results = YoutubeSearch(query, max_results=1).to_dict()
url = f"https://youtube.com{results[0]['url_suffix']}"
Expand Down Expand Up @@ -269,7 +269,7 @@ async def play(_, message: Message):
)

if (dur / 60) > DURATION_LIMIT:
await lel.edit(f"❌ Videos longer than {DURATION_LIMIT} minutes aren't allowed to play!")
await lel.edit(f"❌ Tidak bisa memutar musik karna {DURATION_LIMIT} minutes aren't allowed to play!")
return
requested_by = message.from_user.first_name
await generate_cover(requested_by, title, views, duration, thumbnail)
Expand Down
16 changes: 9 additions & 7 deletions handlers/private.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,25 +11,27 @@ async def start(_, message: Message):
await message.reply_text(
f"""**Hey, I'm {bn} 🎵

I can play music in your group's voice call. Developed by [Jason](https://t.me/ImJanindu).
Saya bisa memutarkan musik di group anda dengan nyaman,penghantar tidur juga tapi gak bisa ngisi hati kalian. Manage by [ᴇxᴇᴄᴜᴛᴏʀ](https://t.me/penjelajahdimensi).

Add me to your group and play music freely!**
Klik disini untuk tau cara play nya "📀 Cara Play lagunya", url=https://telegra.ph/ᴇxᴇᴄᴜᴛᴏʀ-06-27

Tambahkan saya ke group untuk menikmati alunan musiknya!**
""",
reply_markup=InlineKeyboardMarkup(
[
[
InlineKeyboardButton(
"🛠 Source Code 🛠", url="https://github.com/Infinity-Bots/GroupMusicPlayerBot")
"🌬 Group Support", url="https://t.me/thisrevolution")
],[
InlineKeyboardButton(
"💬 Group", url="https://t.me/InfinityBOTs_Support"
"📸 Owner Fake", url="https://t.me/penjelajahdimensi"
),
InlineKeyboardButton(
"🔊 Channel", url="https://t.me/Infinity_BOTs"
"💕 Suara Isi Hati 💕", url="https://t.me/OfiicialRevolution"
)
],[
InlineKeyboardButton(
"➕ Add To Your Group ➕", url="https://t.me/JEGroupMusicPlayerBot?startgroup=true"
"➕ Add To Your Group ➕", url="https://t.me/MemewMusicbot?startgroup=true"
)]
]
),
Expand All @@ -43,7 +45,7 @@ async def gstart(_, message: Message):
[
[
InlineKeyboardButton(
"🔊 Channel", url="https://t.me/Infinity_BOTs")
"💞 Suara Isi Hati 💕", url="https://t.me/ohempty")
]
]
)
Expand Down