nyxx/README.md
2018-09-04 20:43:16 +02:00

2.7 KiB



Build Status Pub documentation

Simple, robust framework for creating discord bots for Dart.
Fork of Hackzzila's nyx - extended with new functionality, few bug fixes, applied pending pull requests.


Stable release

nyxx 1.0.0 is first stable release. It uses Dart 2.0 stable and has many rewritten and improved features.

Features

  • Commands framework included
    A fast way to create a bot with command support. Implementing the framework is simple - and everything is done automatically.
  • Cross Platform
    Nyxx works on the command line, in the browser, and on mobile devices.
  • Fine Control
    Nyxx allows you to control every outgoing HTTP request or WebSocket message.
  • Internal Sharding
    Nyxx automatically spawns shards for your bot, but you can override this and spawn a custom number of shards. Internal sharding means that all of your bots shards are managed in one script, and there is no need for communication between shards.
  • Complete
    Nyxx supports nearly all Discord API endpoints.

Sample

void main() {
  discord.Client bot =
      new discord.Client(Platform.environment['DISCORD_TOKEN']);

  bot.onReady.listen((discord.ReadyEvent e) {
    print("Ready!");
  });

  bot.onMessage.listen((discord.MessageEvent e) {
    if (e.message.content == "!ping") {
      e.message.channel.sendMessage(content: "Pong!");
    }
  });
}

Documentation and examples

Dartdocs

The dartdocs page will always have the documentation for the latest release.

Dev docs

You can read about upcoming changes to the library on my website.

Wiki

Wiki documentation are designed to match the latest Nyxx release.

Roadmap

  • Better dartdocs documentation
  • More examples at wiki/more tutorial/Video tutorial
  • Bigger bot written in nyxx for example
  • Fix lint errors from dartanalyzer
  • Annotation driver flow for CommandsFramework?
  • Recheck all code and fix styling/small logic bugs
  • Support for Voice connection