AbhiCalls 2.9.8__py3-none-any.whl → 2.9.9__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
AbhiCalls/Start.py ADDED
@@ -0,0 +1,29 @@
1
+ import requests
2
+ from colorama import init, Fore, Style
3
+ from AbhiCalls import __version__, __author__
4
+
5
+ init(autoreset=True)
6
+
7
+ def check_latest_version(pkg_name="AbhiCalls"):
8
+ try:
9
+ response = requests.get(f"https://pypi.org/pypi/{pkg_name}/json", timeout=3)
10
+ if response.status_code == 200:
11
+ return response.json()["info"]["version"]
12
+ except Exception:
13
+ return None
14
+
15
+ def print_startup_message():
16
+ print(Fore.GREEN + "✅ AbhiCalls started...\n")
17
+
18
+ print(Fore.CYAN + f"Version : {__version__}")
19
+ print(Fore.CYAN + f"Author : {__author__}")
20
+ print(Fore.CYAN + "License : Abhishek Special")
21
+ print(Fore.CYAN + "GitHub : https://github.com/YouTubeMusicAPI/AbhiCalls")
22
+ print(Fore.CYAN + "Telegram : https://t.me/WhyAbhishek")
23
+
24
+ latest = check_latest_version("AbhiCalls")
25
+ if latest and latest != __version__:
26
+ print(Fore.YELLOW + "\nUpdate Available!")
27
+ print(Fore.YELLOW + f"New AbhiCalls v{latest} is now available!")
28
+ else:
29
+ print(Fore.GREEN + "\nYou are using the latest version!")
AbhiCalls/__init__.py CHANGED
@@ -1,5 +1,15 @@
1
1
  from AbhiCalls.vc import VoiceEngine
2
2
  from AbhiCalls.runtime import idle
3
3
  from .player import Player
4
+ from .plugins import Plugin
4
5
 
5
6
  __all__ = ["VoiceEngine", "idle"]
7
+
8
+ __version__ = "2.9.9"
9
+ __author__ = "ABHISHEK THAKUR"
10
+
11
+ try:
12
+ from .Start import print_startup_message
13
+ print_startup_message()
14
+ except Exception:
15
+ pass
@@ -0,0 +1 @@
1
+ from .base import Plugin
@@ -0,0 +1,57 @@
1
+ class Plugin:
2
+ name = "base"
3
+
4
+ def __init__(self, app):
5
+ self.app = app # pyrogram Client
6
+
7
+ # =========================
8
+ # ▶️ NOW PLAYING / AUTO-SKIP
9
+ # =========================
10
+ async def on_song_start(self, chat_id, song):
11
+ caption = (
12
+ "▶️ **Now Playing**\n\n"
13
+ f"🎵 **Title:** {song.title}\n"
14
+ f"⏱ **Duration:** {song.duration}\n"
15
+ f"🙋 **Requested by:** {song.requested_by}"
16
+ )
17
+
18
+ if song.thumb:
19
+ await self.app.send_photo(
20
+ chat_id,
21
+ photo=song.thumb,
22
+ caption=caption
23
+ )
24
+ else:
25
+ await self.app.send_message(chat_id, caption)
26
+
27
+ # =========================
28
+ # ⏹ SONG END (optional hook)
29
+ # =========================
30
+ async def on_song_end(self, chat_id, song):
31
+ # Usually no message needed here
32
+ pass
33
+
34
+ # =========================
35
+ # ➕ ADDED TO QUEUE
36
+ # =========================
37
+ async def on_queue_add(self, chat_id, song, position):
38
+ # First song ka message already on_song_start bhej dega
39
+ if position == 1:
40
+ return
41
+
42
+ caption = (
43
+ "➕ **Added to Queue**\n\n"
44
+ f"🎵 **Title:** {song.title}\n"
45
+ f"⏱ **Duration:** {song.duration}\n"
46
+ f"🙋 **Requested by:** {song.requested_by}\n"
47
+ f"📍 **Position:** {position}"
48
+ )
49
+
50
+ if song.thumb:
51
+ await self.app.send_photo(
52
+ chat_id,
53
+ photo=song.thumb,
54
+ caption=caption
55
+ )
56
+ else:
57
+ await self.app.send_message(chat_id, caption)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: AbhiCalls
3
- Version: 2.9.8
3
+ Version: 2.9.9
4
4
  Summary: Telegram Voice Chat Music Engine with Queue, Loop, ETA and Player controls
5
5
  Home-page: https://github.com/YouTubeMusicAPI/TgCall
6
6
  Author: Abhishek Thakur
@@ -1,4 +1,5 @@
1
- AbhiCalls/__init__.py,sha256=8Bgye84bSUJVFLhm2HPc2piO3YHZb67EihvJlGZxvDs,134
1
+ AbhiCalls/Start.py,sha256=Z4Kn3p8elM9Sgo3H_7EBP8dfHknsjgiaUaEs1GEqcnY,1068
2
+ AbhiCalls/__init__.py,sha256=uoXjElr_JmTjFdMHzNKBQbNzwGz4m1j9r2ChxrXouAE,322
2
3
  AbhiCalls/controller.py,sha256=KYppQPpWhTpWj-gwmZqyGgX5liZHAaWRIMqksZPzXzU,3241
3
4
  AbhiCalls/models.py,sha256=fwMdHKE0z6qB98nHJ8E1uYU3JSk25LGxaaeAz1JkAH0,791
4
5
  AbhiCalls/player.py,sha256=UlAWmhZqHFjtAplA9-6lXFkVAu4pyEWDGbF8Wj9KYkM,2286
@@ -8,7 +9,9 @@ AbhiCalls/vc.py,sha256=ld3C4-QNDrHBQPrNzIuNTcu7zk1pVOo9rvrQBUsTI8s,309
8
9
  AbhiCalls/yt.py,sha256=h0QRNK9sy-5wIDueiy-uMUxruV7z5m3xjUyRPoFT6_s,2594
9
10
  AbhiCalls/_engine/__init__.py,sha256=pTqDs11-vYr-wuwtd7h3EkspDquGu84jWfN54ajl0kM,34
10
11
  AbhiCalls/_engine/native.py,sha256=KJajnL9urwrx0PaOEJj4-pGGnhz4X9FDI6rTGrbCLoI,1272
11
- abhicalls-2.9.8.dist-info/METADATA,sha256=VzXnK3k_eeFbdczlR7RAFG8jmLrdA53aHFRUB1NQEvc,1209
12
- abhicalls-2.9.8.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
13
- abhicalls-2.9.8.dist-info/top_level.txt,sha256=3_ZgJEaE0rS9jpmEMi6oIXEtMzIagrn70XtK7H6w2gA,10
14
- abhicalls-2.9.8.dist-info/RECORD,,
12
+ AbhiCalls/plugins/__init__.py,sha256=rSCdGAjFfrzz-XQIFRjOcl629mPCo17n77Fn9lxLcPI,25
13
+ AbhiCalls/plugins/base.py,sha256=wanPA2h4dHvR-YXGIsAgkAGGtGMd6acT0Gg8q35RTgI,1696
14
+ abhicalls-2.9.9.dist-info/METADATA,sha256=3iVxiggOeLOrWg6msDJOCW3DCI8kmfuYRITyb9fKdhI,1209
15
+ abhicalls-2.9.9.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
16
+ abhicalls-2.9.9.dist-info/top_level.txt,sha256=3_ZgJEaE0rS9jpmEMi6oIXEtMzIagrn70XtK7H6w2gA,10
17
+ abhicalls-2.9.9.dist-info/RECORD,,