Skip to content

Releases: Greenadine/acf-javacord

0.5.1-SNAPSHOT

20 Oct 02:01
cf78be5
Compare
Choose a tag to compare
0.5.1-SNAPSHOT Pre-release
Pre-release

Bugfixes

  • Fixed breaking bug where arguments for slash commands for context resolving were being stored in an unmodifiable list.

0.5.0

09 Oct 05:19
Compare
Choose a tag to compare
0.5.0 Pre-release
Pre-release

Highlights

  • Updated to Javacord 3.8.0.
  • Added near-full support for slash commands! Name and description localizations will follow in a later update.

Improvements

  • Added MessageCommandManager, a command manager for solely message commands (AKA old Discord commands).
  • Added SlashCommandManager, a command manager for solely slash commands.
  • Added MessageCommandEvent and SlashCommandEvent, which are to be used instead of JavacordCommandEvent when working with message- and slash commands, respectively.
  • Added context resolvers for ChannelCategory. ServerForumChannel, ServerThreadChannel and StageVoiceChannel.

Breaking changes

  • JavacordCommandManager is now a convenience class for creating a command manager for both message- and slash commands.
  • Removed deprecated embedBuilder() from JavacordCommandEvent.
  • Removed context resolver for CustomEmoji.

0.4.0

13 Mar 08:08
Compare
Choose a tag to compare
0.4.0 Pre-release
Pre-release

Highlights

  • Updated to Javacord 3.7.0.

Improvements

  • Added newEmbed() in favor of embedBuilder() to JavacordCommandEvent. JavacordCommandEvent::embedBuilder() is now deprecated.
  • Added getServerBoostingSinceTimestamp() to Member.
  • Added getServerAvatarHash() to Member.
  • An exception (UserNotMemberOfServerException) will now be thrown once an instance of Member is being constructed where the User is not currently present in the Server.

Bugfixes

  • Correctly implemented a few methods of Member implemented from User.

Breaking changes

  • Changed the signature of ban(int) to ban(Duration) in Member.
  • Changed the signature of ban(int, String) to ban(Duration, String) in Member.

v0.2

22 Jun 15:05
Compare
Choose a tag to compare
v0.2 Pre-release
Pre-release

Additions

  • Added UnicodeEmoji - an object which represents a Unicode emoji, and allows creating Emoji objects of Unicode emojis.
  • Added Require annotation - can be used on any object extending Channel to force require command input.
  • Additions to Member:
    • Added getStatus() - returns the member's current status, same as User#getStatus().
    • Added getStatusOnClient(DiscordClient) - returns the member's current status on the given client, same as User#getStatusOnClient(DiscordClient).
    • Added getUserFlags() - returns the member's user flags, same as User#getUserFlags().
    • Added getActivities() - returns the member's current activities, same as User#getActivities().
    • Added hasDefaultAvatar() - returns whether the member has the default Discord avatar set on their profile, same as User#hasDefaultAvatar().
    • Added getMutualServers() - returns the Servers the member has mutual with the API.
    • Added isInVoiceChannel() - returns whether the member is connected to a voice channel within its server.
    • Added isConnected(ServerVoiceChannel) - returns whether the member is connected to the given ServerVoiceChannel, same as User#isConnected(ServerVoiceChannel).
  • Added context resolvers for Emoji, UnicodeEmoji, Channel, PrivateChannel, GroupChannel, VoiceChannel and ServerVoiceChannel objects.

Changes

  • Changes to Member:
    • getHighestRole() now returns an Optional<Role> instead of a Role.
  • Changed context resolvers of User and Member to a regular context resolvers, instead of issuer aware.
  • Switched to using regex matching instead of manual string comparing when checking for tagged entities in context resolvers.

Bug fixes

  • Context resolvers of Role, CustomEmoji and KnownCustomEmoji now properly handle being annotated with Optional.

v0.1.1

31 May 20:15
d5cd8ab
Compare
Choose a tag to compare
v0.1.1 Pre-release
Pre-release
  • Update to Javacord v3.3.0 (from v3.1.2).
  • Renamed co.aikar.commands.annotations to co.aikar.commands.annotation for consistency.
  • Made some changes to the JavacordCommandEvent object.
    • Added new methods:
      • replyf(), a convenience reply method with formatting capabilities according to String.format().
      • getExecCommandLabel(), which will return the currently used command execution label.
      • getUser(), which will return the User that is associated with current command execution.
      • getMember(), which will return the Member that is associated with current command execution.
    • Internally sent messages now use an embed with a red color instead of regular messages.
  • Made some changes to the Member object.
    • Added new methods:
      • getAvatar(), which returns the Member's avatar.
      • getMentionTag(), which returns the Member's mention tag, according to User#getMentionTag()
      • getNicknameMentionTag(), which returns the Member's nickname mention tag, according to User#getNicknameMentionTag().
    • Changed getJoinedAtTimestamp() to return an Instant instead of an Optional<Instant>.
  • Added context resolvers for CustomEmoji and KnownCustomEmoji objects.
  • Changed context resolver for User, Member, TextChannel and ServerTextChannel objects to an issuer aware context resolver.
  • Slightly improved context resolvers for User and Member objects.
    • It is now possible to annotate User and Member objects with SelfUser, which will always return the bot's instance of both objects.
    • It is now possible to flag User and Member objects with "other" with @Flags("other"), which will force the context resolver to require a user-provided argument.
  • Some code cleanup.

v0.1

20 Jan 18:36
e8dae3c
Compare
Choose a tag to compare
v0.1 Pre-release
Pre-release

Installation

Add the .jar file to a new /libs folder (or a different one) within the project.

Maven

<dependency>
    <groupId>com.github.greenadine</groupId>
    <artifactId>acf-javacord</artifactId>
    <version>0.1</version>
    <scope>system</scope>
    <systemPath>${project.basedir}/libs/javacord-0.1.jar</systemPath>
</dependency>

Gradle

repositories {
    flatDir {
        dirs 'libs'
    }
}

dependencies {
    implementation files('libs/acf-javacord-0.1.jar')
}