GithubHelp home page GithubHelp logo

zevaryx / molter Goto Github PK

View Code? Open in Web Editor NEW

This project forked from nafteam/molter

0.0 0.0 0.0 105 KB

(WIP) Shedding a new skin on Dis-Snek's commands. Primarily developed by Astrea49.

License: MIT License

Python 100.00%

molter's Introduction

EDIT: This repo is archived - its features have been merged into Dis-Snek/NAFF.

PyPI Downloads Code style: black

Molter - WIP

Shedding a new skin on Dis-Snek's commands.

Currently, its goals are to make message commands more similar (not exactly the same!) to discord.py's message commands.

Primary developed by Astrea49. Direct questions about the project to her, please!

Installing

pip install -U molter

Example

Load this as a normal scale in dis_snek:

import dis_snek
import molter
from typing import Optional


class CommandTest(dis_snek.Scale):

    @molter.msg_command()
    async def test(
        self,
        ctx: dis_snek.MessageContext,
        a_num: int,
        a_user: Optional[dis_snek.Member],
        a_bool: bool,
    ):
        await ctx.reply(f"{a_num} {a_user} {a_bool}")


def setup(bot):
    CommandTest(bot)

Note

  • This project is a work in progress - it is unstable. Basic testing has been done, but more is still required.
  • This hasn't been merged with Dis-Snek yet because it's unstable. Don't worry, I plan to merge these changes with Dis-Snek once this is ready!
  • discord.py's FlagConverter and potentially other features are not in this. If they will be added is to be seen.
  • molter is not meant to be 1:1 with discord.py's command parser even if it may seem like it. There are some differences, usually done for clarity's sake.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.