diff --git a/CHANGELOG.md b/CHANGELOG.md
index aa16594..5a18652 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -15,7 +15,7 @@
- Telethon has been completely updated, moving to heroku-tl
- update heroku-tl to 1.0.6
- added prefix to ping
-- removed official support serv00, tothost, goorm, railway
+- removed official support serv00, tothost, goorm, railway, termux
- rename folder "hikka" to "heroku"
- fix close btn
- fix native imports
diff --git a/README.md b/README.md
index 98f494e..de93748 100644
--- a/README.md
+++ b/README.md
@@ -129,11 +129,4 @@ Check out heroku.codrago.top for users
Codwiz for Ukrainian translation pack
Lyomi for German translation pack
Lonami for Telethon, which is the base of Heroku-TL
-
-
-
-Sponsors:
-
-
-
-Developed with support of aeza.net
\ No newline at end of file
+
\ No newline at end of file
diff --git a/heroku/langpacks/de.yml b/heroku/langpacks/de.yml
index e73f836..cfb0f89 100644
--- a/heroku/langpacks/de.yml
+++ b/heroku/langpacks/de.yml
@@ -203,7 +203,7 @@ heroku_backup:
backupall_sent: "🗂 Sicherung der Datenbank und der an gespeicherte Nachrichten gesendeten Module"
db_warning: "❗️ Hikka-Backup erkannt. Wenn Sie fortfahren, versucht der Userbot, es in ein für Heroku geeignetes Format zu konvertieren. Möglicherweise treten Fehler bei der Konvertierung auf. Fortfahren?"
advice_converting: "Sie können 'hikka.' im Backup-Inhalt manuell durch 'heroku.' ersetzen. Dies ist zum Laden erforderlich."
- db_converting: "🔄 Konvertierung läuft …"
+ converting_db: "🔄 Konvertierung läuft …"
_cls_doc: "Verarbeitet Datenbank- und Modulsicherungen"
_cmd_doc_backupdb: "Datenbanksicherung erstellen [wird per PN gesendet]"
_cmd_doc_backupmods: "Erstelle ein Backup der Mods [wird per PN gesendet]"
@@ -213,6 +213,15 @@ heroku_backup:
_cmd_doc_backupall: "Erstellt eine allgemeine Sicherungskopie (Module + Datenbank)"
_cmd_doc_restoreall: "Stellt ein gemeinsames Backup wieder her (Basis + Module)"
+executor:
+ no_code: "❌ Es sollte {}exec [Python-Code]
sein"
+ executing: "🔄 Code wird ausgeführt..."
+ no_phone: "Versteckt deine Telefonnummer in der Ausgabe"
+ result: "\n💻 Code:\n{code}
\n{result}\n⏳ Ausgeführt in {time} Sekunden"
+ result_no_error: "✅ Ergebnis\n{result}
"
+ result_error: "🚫 Fehler\n{result}
"
+ res_return: "💾 Code hat zurückgegeben:\n{res}
"
+
presets:
_fun_title: "🪩 Unterhaltsame Module"
_fun_desc: "Lustige Module – Animationen, Spam, Spiele und mehr."
diff --git a/heroku/langpacks/en.yml b/heroku/langpacks/en.yml
index febad9b..3c30254 100644
--- a/heroku/langpacks/en.yml
+++ b/heroku/langpacks/en.yml
@@ -217,7 +217,7 @@ heroku_backup:
backupall_sent: "🗂 Backup of database and modules sent to saved messages"
db_warning: "❗️ Hikka backup detected. If you continue, the userbot will try to convert it to a format suitable for Heroku.\nThere may be some errors in the conversion. Continue?"
advice_converting: "You can manually replace 'hikka.' with 'heroku.' in the backup content. This is necessary for loading it."
- db_converting: "🔄 Converting..."
+ converting_db: "🔄 Converting..."
_cls_doc: "Processes database and module backups"
_cmd_doc_backupdb: "Create a database backup [will be sent to PM]"
_cmd_doc_backupmods: "Create a backup of mods [will be sent to PM]"
@@ -227,6 +227,15 @@ heroku_backup:
_cmd_doc_backupall: "Creates a general backup copy (modules + database)"
_cmd_doc_restoreall: "Restores a common backup (base + modules)"
+executor:
+ no_code: "❌ Should be {}exec [python code]
"
+ executing: "🔄 Executing code..."
+ no_phone: "Hides your phone number in the output"
+ result: "\n💻 Code:\n{code}
\n{result}\n⏳ Executed in {time} seconds"
+ result_no_error: "✅ Result\n{result}
"
+ result_error: "🚫 Error\n{result}
"
+ res_return: "💾 Code returned:\n{res}
"
+
presets:
name: "Presets"
_fun_title: "🪩 Entertainment modules"
diff --git a/heroku/langpacks/ru.yml b/heroku/langpacks/ru.yml
index 271f1ae..ab66ac9 100644
--- a/heroku/langpacks/ru.yml
+++ b/heroku/langpacks/ru.yml
@@ -203,7 +203,7 @@ heroku_backup:
backupall_sent: "🗂 Резервная копия базы и модулей отправлена в сохраненные сообщения"
db_warning: "❗️ Обнаружен бекап из Hikka. Если продолжить — юзербот попробует преобразовать его в подходящий формат для Heroku.\nВозможны некоторые ошибки в преобразовании. Продолжить?"
advice_converting: "Вы можете вручную заменить 'hikka.' на 'heroku.' в содержимом бекапа. Это необходимо для его загрузки."
- db_converting: "🔄 Конвертирую..."
+ converting_db: "🔄 Конвертирую..."
_cls_doc: "Обрабатывает резервные копии базы данных и модулей"
_cmd_doc_backupdb: "Создать бэкап базы данных [будет отправлено в лс]"
_cmd_doc_backupmods: "Создать бэкап модов [будет отправлено в лс]"
@@ -213,6 +213,15 @@ heroku_backup:
_cmd_doc_backupall: "Создаёт общую резервную копию (модули + база)"
_cmd_doc_restoreall: "Восстанавливает общую резервную копию (база + модули)"
+executor:
+ no_code: "❌ Должно быть {}exec [python код]
"
+ executing: "🔄 Выполняю код..."
+ no_phone: "Скрывает твой номер телефона при выводе"
+ result: "\n💻 Код:\n{code}
\n{result}\n⏳ Выполнен за {time} секунд"
+ result_no_error: "✅ Результат\n{result}
"
+ result_error: "🚫 Ошибка\n{result}
"
+ res_return: "💾 Код вернул:\n{res}
"
+
presets:
_fun_title: "🪩 Развлекательные модули"
_fun_desc: "Забавные модули — анимации, спам, игры, и др."
diff --git a/heroku/langpacks/ua.yml b/heroku/langpacks/ua.yml
index 43f1974..d6436f4 100644
--- a/heroku/langpacks/ua.yml
+++ b/heroku/langpacks/ua.yml
@@ -203,7 +203,7 @@ heroku_backup:
backupall_sent: "🗂 Резервна копія бази даних і модулів, надісланих у збережені повідомлення"
db_warning: "❗️ Виявлено резервну копію Hikka. Якщо ви продовжите, користувач-бот спробує конвертувати її у формат, придатний для Heroku.\nПід час конвертації можуть бути деякі помилки. Продовжити?"
advice_converting: "Ви можете вручну замінити 'hikka.' на 'heroku.' у вмісті резервної копії. Це необхідно для її завантаження."
- db_converting: "🔄 Конвертування..."
+ converting_db: "🔄 Конвертування..."
_cls_doc: "Обробляє резервні копії бази даних і модулів"
_cmd_doc_backupdb: "Створити резервну копію бази даних [буде надіслано на PM]"
_cmd_doc_backupmods: "Створити резервну копію модів [буде надіслано в личку]"
@@ -213,6 +213,14 @@ heroku_backup:
_cmd_doc_backupall: "Створює загальну резервну копію (модулі + база)"
_cmd_doc_restoreall: "Відновлює загальну резервну копію (база + модулі)"
+executor:
+ no_code: "❌ Повинно бути {}exec [python код]
"
+ executing: "🔄 Виконую код..."
+ no_phone: "Приховує ваш номер телефону у виводі"
+ result: "\n💻 Код:\n{code}
\n{result}\n⏳ Виконано за {time} секунд"
+ result_no_error: "✅ Результат\n{result}
"
+ result_error: "🚫 Помилка\n{result}
"
+ res_return: "💾 Код повернув:\n{res}
"
presets:
_fun_title: "🪩 Розважальні модулі"
diff --git a/heroku/main.py b/heroku/main.py
index 5808d1f..830b007 100644
--- a/heroku/main.py
+++ b/heroku/main.py
@@ -91,7 +91,6 @@ BASE_DIR = (
BASE_PATH = Path(BASE_DIR)
CONFIG_PATH = BASE_PATH / "config.json"
-IS_TERMUX = "com.termux" in os.environ.get("PREFIX", "")
IS_DOCKER = "DOCKER" in os.environ
IS_LAVHOST = "LAVHOST" in os.environ
IS_HIKKAHOST = "HIKKAHOST" in os.environ
@@ -212,7 +211,7 @@ def run_config():
"""Load configurator.py"""
from . import configurator
- return configurator.api_config(IS_TERMUX or None)
+ return configurator.api_config(None)
def get_config_key(key: str) -> typing.Union[str, bool]:
@@ -497,7 +496,6 @@ class Heroku:
if (
not web_available
or getattr(self.arguments, "disable_web", False)
- or IS_TERMUX
):
self.web = None
return
@@ -597,7 +595,7 @@ class Heroku:
async def _phone_login(self, client: CustomTelegramClient) -> bool:
phone = input(
"\033[0;96mEnter phone: \033[0m"
- if IS_TERMUX or self.arguments.tty
+ if self.arguments.tty
else "Enter phone: "
)
@@ -630,7 +628,7 @@ class Heroku:
print(
(
- "\033[0;96m{}\033[0m" if IS_TERMUX or self.arguments.tty else "{}"
+ "\033[0;96m{}\033[0m" if self.arguments.tty else "{}"
).format(
"You can use QR-code to login from another device (your friend's"
" phone, for example)."
@@ -640,7 +638,7 @@ class Heroku:
if (
input(
"\033[0;96mUse QR code? [y/N]: \033[0m"
- if IS_TERMUX or self.arguments.tty
+ if self.arguments.tty
else "Use QR code? [y/N]: "
).lower()
!= "y"
@@ -686,7 +684,7 @@ class Heroku:
while True:
_2fa = getpass(
f"\033[0;96mEnter 2FA password ({password.hint}): \033[0m"
- if IS_TERMUX or self.arguments.tty
+ if self.arguments.tty
else f"Enter 2FA password ({password.hint}): "
)
try:
diff --git a/heroku/modules/executor.py b/heroku/modules/executor.py
index cc3fd80..e42f994 100644
--- a/heroku/modules/executor.py
+++ b/heroku/modules/executor.py
@@ -34,11 +34,7 @@ class Executor(loader.Module):
"""Выполнение python кода"""
strings = {
- "name": "Executor",
-
- "no_code": "❌ Должно быть {}exec [python код]
",
-
- "executing": "🔄 Выполняю код..."
+ "name": "Executor"
}
def __init__(self):
@@ -46,7 +42,7 @@ class Executor(loader.Module):
loader.ConfigValue(
"hide_phone",
True,
- lambda: "Скрывает твой номер телефона при выводе",
+ lambda: self.strings["no_phone"],
validator=loader.validators.Boolean()
),
)
@@ -120,16 +116,12 @@ class Executor(loader.Module):
res = res.replace("+"+me.phone, t_h).replace(me.phone, t_h)
if result:
- result = f"""{'✅ Результат' if not cerr else '🚫 Ошибка'}:
-{result}
-"""
- if res or res == 0 or res == False and res is not None:
- result += f"""💾 Код вернул:
-{res}
-"""
+ if not cerr:
+ result = self.strings["result_no_error"].format(result={result})
+ else:
+ result = self.strings["result_error"].format(result={result})
- return await utils.answer(message, f"""
-💻 Код:
-{code}
-{result}
-⏳ Выполнен за {round(stop_time - start_time, 5)} секунд""")
\ No newline at end of file
+ if res or res == 0 or res == False and res is not None:
+ result += self.string["res_return"].format(res={res})
+
+ return await utils.answer(message, self.strings["result"].format(code={code}, result={result}, time=round({stop_time} - {start_time}, 5)))
\ No newline at end of file
diff --git a/heroku/modules/presets.py b/heroku/modules/presets.py
index 2d5bc2b..6ee6a5c 100644
--- a/heroku/modules/presets.py
+++ b/heroku/modules/presets.py
@@ -46,6 +46,7 @@ PRESETS = {
"https://github.com/amm1edev/ame_repo/raw/refs/heads/main/Compliments.py",
"https://github.com/amm1edev/ame_repo/raw/refs/heads/main/mazemod.py",
"https://mods.codrago.life/dice.py",
+ "https://mods.codrago.life/randnum.py",
"https://mods.codrago.life/loli.py",
"https://mods.codrago.life/DoxTool.py",
"https://mods.codrago.life/randomizer.py",
@@ -64,6 +65,7 @@ PRESETS = {
"https://github.com/amm1edev/ame_repo/raw/refs/heads/main/filter.py",
"https://mods.codrago.life/id.py",
"https://mods.codrago.life/clickon.py",
+ "https://mods.codrago.life/autoclicker.py",
],
"service": [
"https://github.com/amm1edev/ame_repo/raw/refs/heads/main/account_switcher.py",
@@ -81,7 +83,6 @@ PRESETS = {
"https://mods.codrago.life/modlist.py",
],
"downloaders": [
- "https://heta.dan.tatar/musicdl.py",
"https://github.com/amm1edev/ame_repo/raw/refs/heads/main/uploader.py",
"https://github.com/amm1edev/ame_repo/raw/refs/heads/main/porn.py",
"https://github.com/amm1edev/ame_repo/raw/refs/heads/main/web2file.py",
@@ -166,7 +167,7 @@ class Presets(loader.Module):
)
async def _preset(self, call: InlineCall, preset: str):
- await call.edit(
+ await self.inline.bot(call.edit)(
self.strings("preset").format(
self.strings(f"_{preset}_title"),
self.strings(f"_{preset}_desc"),
diff --git a/heroku/utils.py b/heroku/utils.py
index 95f9f1a..154fdbd 100644
--- a/heroku/utils.py
+++ b/heroku/utils.py
@@ -936,9 +936,6 @@ def get_named_platform() -> str:
if main.IS_DOCKER:
return "🐳 Docker"
- if main.IS_TERMUX:
- return "🕶 Termux"
-
return f"✌️ lavHost {os.environ['LAVHOST']}" if main.IS_LAVHOST else "💎 VDS"
@@ -970,16 +967,11 @@ def get_platform_emoji() -> str:
if main.IS_LAVHOST:
return BASE.format(5352753797531721191)
- if main.IS_TERMUX:
- return BASE.format(5350588498359377932)
-
if main.IS_DOCKER:
return BASE.format(5352678227582152630)
return BASE.format(5393588431026674882)
-allowed_ids = [1714120111, 1655585249]
-
def uptime() -> int:
"""
Returns userbot uptime in seconds
@@ -1000,35 +992,6 @@ def formatted_uptime() -> str:
return f"{days} day(s), {time_formatted}"
return time_formatted
-async def add_uptime(client: CustomTelegramClient, minutes: int) -> str:
- """
- Adds a custom uptime in minutes to the current uptime.
- :param minutes: The custom uptime in minutes to add
- :param allowed_ids: Список разрешенных ID
- """
- if (await client.get_me()).id not in allowed_ids:
- return "You are not allowed to add uptime."
-
- global init_ts
- seconds = minutes * 60
- init_ts -= seconds
- return "Added uptime!"
-
-async def set_uptime(client: CustomTelegramClient, minutes: int) -> str:
- """
- Sets a custom uptime in minutes. This will adjust the init_ts accordingly.
- :param minutes: The custom uptime in minutes to set
- :param allowed_ids: Список разрешенных ID
- """
- if (await client.get_me()).id not in allowed_ids:
- return "You are not allowed to added uptime."
-
- global init_ts
- seconds = minutes * 60
- init_ts = time.perf_counter() - seconds
-
- return " Uptime is on offer!"
-
def ascii_face() -> str:
"""
Returnes cute ASCII-art face