Make skilling activity configurable in Discord
Make showing of skilling activity configurable in Discord plugin. Signed-off-by: Tomas Slusny <slusnucky@gmail.com>
This commit is contained in:
@@ -50,4 +50,15 @@ public interface DiscordConfig extends Config
|
||||
{
|
||||
return 10;
|
||||
}
|
||||
|
||||
@ConfigItem(
|
||||
keyName = "showSkillActivity",
|
||||
name = "Show activity while skilling",
|
||||
description = "Configures if your activity while training skills should be shown.",
|
||||
position = 2
|
||||
)
|
||||
default boolean showSkillingActivity()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -126,7 +126,7 @@ public class DiscordPlugin extends Plugin
|
||||
|
||||
final DiscordGameEventType discordGameEventType = DiscordGameEventType.fromSkill(event.getSkill());
|
||||
|
||||
if (discordGameEventType != null)
|
||||
if (discordGameEventType != null && config.showSkillingActivity())
|
||||
{
|
||||
discordState.triggerEvent(discordGameEventType, config.actionDelay());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user