Coder Social home page Coder Social logo

alexandercolen / annie-may-discord-bot Goto Github PK

View Code? Open in Web Editor NEW
12.0 12.0 1.0 1.32 MB

Discord bot written in C# for AniList anime/manga lookup.

Home Page: https://discord.com/oauth2/authorize?client_id=701143398526222386&permissions=388160&scope=bot

C# 100.00%
anilist anime csharp discord discord-bot discord-net graphql manga mongodb

annie-may-discord-bot's People

Contributors

alexandercolen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

soaringgecko

annie-may-discord-bot's Issues

Migrate to a new database.

MongoDB is not ideal for expanding, especially the caching of data, and is causing blockage for other issues. ( #3 )

Migrate the data to PostgreSQL and include DB creation scripts within the code base.

Perhaps couple this with the move to a Docker container.

Stick to proper naming conventions in all classes.

Go through all the code in the project and make sure that all the variables are named in the same way.

Main culprit is the Models.DiscordUser class.

Also add some documentation guidelines to the wiki on how to adhere to these standards.

Write summaries and comments explaining the code.

Clear and concise one-liners as summary description and map out all the parameters and return values.

Might want to get rid of:
[Summary("This is a simple method summary.")]
and replace with:

/// <summary>
/// This is a more descriptive method summary.
/// </summary>
/// <param name="aParameter">I am the method parameter.</param>
/// <returns>I am the return value.</returns>

Make sure that every method is at least covered by a summary, ideally add comments within code with reasons for a loop, if, and return statement.

Fetch random Planned media entries.

Should default to random media from Anilist.

Multiple possible overrides:

  • Specify anime or manga. Will become its own issue eventually™.
  • Random entry from someone's list. Will become its own issue eventually™.
  • Random entry from the user's Planned list.

Add lookup for staff members

Should be similar to Character & Studio, so reuse as many elements as you can from that.

Probably best to refactor some code for less duplication as well?

Add MyAnimeList support

Minimum functionality:

  • Add database support for MAL
  • Merge user scores of both MAL & Anilist when fetching media data
  • Have users add MAL on server setup
    • Make sure to also ask for MAL or anilist preference

Add custom status rotation

Change status from a list of predetermined statuses every X seconds.

Make sure to keep the ~help before the custom status!

Random die rolls / coin flips.

Randomly roll a die or flip a coin, allow user overrides to roll between certain numbers.

Potentially roll multiple times?

Improve search results for Characters & Studios.

Solve it using the Levenshtein utility just like was done for anime searching.

Steps to resolve this issue:

  1. Fetch a list of characters based on the search criteria.
  2. Run characters with all their aliases through the Levenshtein algorithm.
  3. Return the best response to the user.

Improve search results for Media.

Currently being solved using Levenshtein algorithm, but the result is not as desired.
Sometimes the searched query is not even close to the actual entry that is known to exist that we want to find.

Null media status values on userlists breaks media lookup.

Caused by the looking up of users' lists and trying to parse their media status.
Error converting value {null} to type 'AnnieMayDiscordBot.Enums.Anilist.MediaStatus'. Path 'data.MediaListCollection.lists[0].entries[42].media.status', line 1, position 12942.

Fixing #41 by refactoring the way it is handled may fix this issue.

Fix missing newlines in Help commands.

There needs to be 2 newlines before and after regex.

Needs to be fixed for these:

.WithDescription($"Change settings for the server that the message was sent in.\nOnly server administrators are allowed to do these actions.\n" +
$"_Regex_ `settings( ((prefix .+)|((userscores|scoring|scores) (true|false))))?`\n\n" +

.WithDescription($"Generate some random dice rolls, coinflips, and more." +
$"_Regex_ `(random )?((coin)?(flip)?|((roll|dic?e)( -?\\d+( -?\\d+)?)?))`\n\n" +

Write custom command handler.

Will make it more clear how to add more commands for other users and give more ways to add fluff to the bot, such as rewriting the :3 thing.

Allow custom lookup of user scores

Only show distribution of their scores. Can make use of the ScoreDistribution class (Annie/Models/Anilist/ScoreDistribution.cs)

Allow custom overloading using >, <, = and != including combinations of these.

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.