معرفی شرکت ها


dgg-bot-0.9.1


Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر
Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر
Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر
Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر
Card image cap
تبلیغات ما

مشتریان به طور فزاینده ای آنلاین هستند. تبلیغات می تواند به آنها کمک کند تا کسب و کار شما را پیدا کنند.

مشاهده بیشتر

توضیحات

A library for making a bot in Destiny.gg chat.
ویژگی مقدار
سیستم عامل -
نام فایل dgg-bot-0.9.1
نام dgg-bot
نسخه کتابخانه 0.9.1
نگهدارنده []
ایمیل نگهدارنده []
نویسنده Fritz-02
ایمیل نویسنده -
آدرس صفحه اصلی -
آدرس اینترنتی https://pypi.org/project/dgg-bot/
مجوز MIT
DGG-bot ======= .. image:: https://img.shields.io/pypi/v/dgg-bot.svg :target: https://pypi.python.org/pypi/dgg-bot :alt: PyPI version info .. image:: https://img.shields.io/pypi/pyversions/dgg-bot.svg :target: https://pypi.python.org/pypi/dgg-bot :alt: PyPI supported Python versions A library for making a bot in Destiny.gg chat. Installing ---------- **Python 3.9 or higher is required** (version 0.5.0 and above, Python 3.8+ for versions below) .. code:: sh # Linux/macOS python3 -m pip install -U dgg-bot # Windows py -3 -m pip install -U dgg-bot Usage ----- Not sure what to put here at this point in time. Unauthorized chat bots are subject to being **banned**, ask Cake in DGG for permission and guidelines for chat bots before running one. Examples -------- A simple bot with three commands and will yump back at chatters. .. code-block:: python from dggbot import DGGBot import time bot = DGGBot( "AUTH_TOKEN", owner="Owner", prefix="$", ) # default command prefix is "!" @bot.command() @bot.is_owner() # only the owner named in DGGBot can use this command. def test(msg): # $test msg.reply("Test 123") @bot.command(aliases=["banmeplease"]) # aliases for this command def banme(msg): # $banme / $banmeplease bot.send("RightToBearArmsLOL BINGQILIN nathanTiny2") def is_cake(msg): # a check where only the user Cake can use commands with this check return msg.nick == "Cake" @bot.command(aliases=["oooo"]) @bot.check(is_cake) def pog(msg): msg.reply("Cake OOOO") """ Events You can either name the function after the event, or include the event name in the decorator. mention() is also included as a shortcut for event("on_mention"). Event names: on_ban, on_broadcast, on_join, on_mention, on_msg, on_mute, on_privmsg, on_quit, on_refresh, on_unban """ @bot.event() def on_msg(msg): print(msg) # @bot.event("on_mention") @bot.mention() def yump(msg): if "MiyanoHype" in msg.data: time.sleep(0.5) msg.reply(f"{msg.nick} MiyanoHype") if __name__ == "__main__": bot.run_forever() Connecting to alternative DGG environments. .. code-block:: python from dggbot import DGGBot bot = DGGBot( owner="Owner", prefix="$", sid="SID", rememberme="REMEMBERME", config={ { "wss": "wss://chat.omniliberal.dev/ws", "wss-origin": "https://www.omniliberal.dev", "baseurl": "https://www.omniliberal.dev", "endpoints": {"user": "/api/chat/me", "userinfo": "/api/userinfo"}, "flairs": "https://cdn.omniliberal.dev/flairs/flairs.json", } }, ) @bot.event() def on_msg(msg): print(msg) if __name__ == "__main__": bot.run_forever()


نیازمندی

مقدار نام
- requests
- websocket-client
- black
- flake8


زبان مورد نیاز

مقدار نام
>=3.9 Python


نحوه نصب


نصب پکیج whl dgg-bot-0.9.1:

    pip install dgg-bot-0.9.1.whl


نصب پکیج tar.gz dgg-bot-0.9.1:

    pip install dgg-bot-0.9.1.tar.gz