Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] Updating James to work with slash commands #173

Draft
wants to merge 25 commits into
base: master
Choose a base branch
from
Draft

Conversation

warp-core
Copy link

@warp-core warp-core commented Oct 31, 2021

To do:

  • Finish this to do list

  • Test everything

  • Ensure coding style uniformity

  • Lookup, Show and Showimage currently do not work as slash commands, I'm not sure what the issue is.

  • Update to slash commands:

    • AudioPlayerSendHandler, Playlists and TrackScheduler should be compatible with both Commands and SlashCommands as they are now.
    • Audio should support both Commands and SlashCommands and I don't think it needs changing until we want to remove normal commands now.
    • I think the audio commands are done.
    • I think Util is done.
    • Creatortools commands need to be done:
      • CRConvert
      • SwizzleImage
      • Template
    • Info commands need to be done:
      • Help (this one is probably less useful with slash commands)
      • Info
      • Ping
    • Misc commands:
      • Birb
      • Cat
      • Dog
      • Translate
    • Moderation commands
      • Activity
      • Move
      • OptIn
      • OptOut
      • Purge
      • Timeout
    • Eval
    • Finish updating James.java
    • Add anything new needed to JamesSlashCommand.java
    • Add new moderation functionality:
  • Fix bugs:

@warp-core
Copy link
Author

Timeout works differently as a slash command than the normal command. It can no longer handle multiple users at a time but the time can be given in units of seconds, minutes, hours, days, or weeks and a reason can be given (though I didn't have it do anything with that reason yet).
This is effectively how Brig Bot does it (though, with slightly less logging at the moment) which is the bot of choice for timeouts in ESC at the moment, so that seems fine.

@warp-core warp-core marked this pull request as draft November 2, 2021 01:53
Changed the way Playlist.remove() works so it takes an index in the array holding the queue instead of the number corresponding to where the song to be removed would appear in the queue embed and changed Audio.remove() accordingly.
Also removed a couple of (apparently) unused immports.
For whatever reason, I didn't upload changes I made here before. Doing that now.
Somewhere along the line, code got replicated here, I'm guessing it was when merging the master into this branch.
This should be the id of the server/guild the commands should be registered in.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant