# by @xtdevs from pyrogram import Client as ren from pyrogram import Client, filters from pyrogram import * from pyrogram.types import * from pyrogram.enums import MessageEntityType from akn.utils.handler import * from akn.utils.prefixprem import command from config import * custom_verifed = "🗿" @Akeno( ~filters.scheduled & command(["getemoji"]) & filters.me & ~filters.forwarded ) async def knowledge_check(client: Client, message: Message): if not message.reply_to_message: return reply_message = message.reply_to_message if not reply_message.entities: return custom_emoji_id = reply_message.entities[0].custom_emoji_id try: await message.reply(f"Get emoji ID : `{custom_emoji_id}`") except Exception as e: await message.reply(str(e)) return @Akeno( ~filters.scheduled & command(["rsetpemoji"]) & filters.me & ~filters.forwarded ) async def set_emoji_status_reply(client: Client, message: Message): if not message.reply_to_message: return await message.reply_text("Reply to emoji premium status") reply_message = message.reply_to_message if not reply_message.entities: return await message.reply_text("No custom emoji found in the message.") get_custom_emoji_id = None for entity in reply_message.entities: if entity.type == MessageEntityType.CUSTOM_EMOJI: get_custom_emoji_id = entity.custom_emoji_id break if not get_custom_emoji_id: return await message.reply_text("No custom emoji found in the message.") if client.me.is_premium: try: await client.set_emoji_status( EmojiStatus(custom_emoji_id=get_custom_emoji_id) ) await message.reply_text(f"Successfully changed profile emoji status to 🗿") except Exception as e: await message.reply_text(str(e)) else: await message.reply_text("Non-premium users cannot set custom emojis.") @Akeno( ~filters.scheduled & command(["setpemoji"]) & filters.me & ~filters.forwarded ) async def set_emoji_status(client: Client, message: Message): text_get = str(message.command[1]) if len(message.command) > 1 else None if not text_get: await message.reply_text(f"Example ?setpemoji {custom_verifed}") return if not message.entities: await message.reply_text("No custom emoji found in the message.") return get_custom_emoji_id = None for entity in message.entities: if entity.type == MessageEntityType.CUSTOM_EMOJI: get_custom_emoji_id = entity.custom_emoji_id break if not get_custom_emoji_id: await message.reply_text("No custom emoji found in the message.") return if client.me.is_premium: try: await client.set_emoji_status( EmojiStatus(custom_emoji_id=get_custom_emoji_id) ) await message.reply_text(f"Successfully changed profile emoji status to 🗿") except Exception as e: await message.reply_text(str(e)) else: await message.reply_text("Non-premium users cannot set custom emojis.") @Akeno( ~filters.scheduled & command(["stealpemoji"]) & filters.me & ~filters.forwarded ) async def steal_emoji_user(client: Client, message: Message): if not message.reply_to_message: await message.reply_text("Reply to a Message") return reply_message = message.reply_to_message if not reply_message.from_user: await message.reply_text("Reply to a message user") return user_id = reply_message.from_user.id if reply_message else "@" + reply_message.from_user.username user = await client.get_users(user_id) custom_emoji_id = user.emoji_status.custom_emoji_id if user.is_premium: try: await client.set_emoji_status( EmojiStatus( custom_emoji_id=custom_emoji_id ) ) await message.reply_text(f"Successfully stole your emoji status 🗿") except Exception as e: await message.reply_text(str(e)) return else: await message.reply_text("can't non-premium user") module = modules_help.add_module("getemoji", __file__) module.add_command("getemoji", "null.") module.add_command("rsetpemoji", "null.") module.add_command("setpemoji", "null.") module.add_command("stealpemoji", "null")