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

Allow configuring which types of messages get sent as webhook for Discord #5158

Open
wants to merge 5 commits into
base: 2.x
Choose a base branch
from

Conversation

diademiemi
Copy link
Contributor

@diademiemi diademiemi commented Nov 16, 2022

Information

This PR partially closes #5155

Details

Proposed feature:
Allow configuring which types of messages get sent as a webhook.

Currently when enabling the webhook feature all player specific messages get sent as a webhook. This may not always be desired since this also includes joining the server, deaths, advancements etc.

Environments tested:

OS: Fedora 36

Java version: 17.0.5

  • Most recent Paper version (1.XX.Y, git-Paper-BUILD)
  • CraftBukkit/Spigot/Paper 1.12.2
  • CraftBukkit 1.8.8
    Don't see how this could differ on other server versions.

Demonstration:

This should send all messages as the normal bot user still, but leave chat messages, afk messages and actions as the player.
(Chat messages use a different code path and can't be configured like this, neither can server messages obviously)

send-types-as-player:
  join: false
  # Leave messages sent when a player leaves the Minecraft server.
  first-join: false
  # Leave messages sent when a player leaves the Minecraft server.
  leave: false
  # Death messages sent when a player dies on the Minecraft server.
  death: false
  # AFK status change messages sent when a player's AFK status changes.
  afk: true
  # Achievement/advancement messages sent when a player is awarded an achievement/advancement.
  advancement: false
  # Action messages sent when a player runs the /me or /action commands.
  action: true

image

(first-join option is from #5160)
(placeholder in username is from #5159)

@pop4959 pop4959 added type: enhancement Features and feature requests. module: discord Issues or PRs for the EssentialsDiscord module labels May 5, 2023
@diademiemi
Copy link
Contributor Author

Hey @pop4959, this PR has been open for 1.5 years now, do you have the chance to look at this and potentially merge it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module: discord Issues or PRs for the EssentialsDiscord module type: enhancement Features and feature requests.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants