Skip to content

Commit

Permalink
✨ silent-channelをデフォルトオンにできる設定を追加
Browse files Browse the repository at this point in the history
  • Loading branch information
acrylic-style committed Jul 22, 2023
1 parent b755e60 commit e122387
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>net.azisaba</groupId>
<artifactId>RyuZUPluginChat</artifactId>
<version>4.4.3</version>
<version>4.5.0</version>
<packaging>jar</packaging>

<name>${project.artifactId}</name>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ public class RPCConfig {
private String vcCommandLunaChatChannel;

private boolean defaultDisablePrivateChatInspect;
private boolean defaultDisableChannelChatInspect;

private final List<DiscordMessageConnection> messageConnections = new ArrayList<>();

Expand Down Expand Up @@ -78,6 +79,7 @@ public void load() {
vcCommandLunaChatChannel = conf.getString("discord.vc-command-lunachat-channel", null);

defaultDisablePrivateChatInspect = conf.getBoolean("default-disable-private-chat-inspect", false);
defaultDisableChannelChatInspect = conf.getBoolean("default-disable-channel-chat-inspect", false);

ConfigurationSection section = conf.getConfigurationSection("discord.connections");
if (section == null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ public void onJoin(PlayerJoinEvent e) {
if (plugin.getRpcConfig().isDefaultDisablePrivateChatInspect()) {
plugin.getPrivateChatInspectHandler().setDisable(p.getUniqueId(), true);
}
if (plugin.getRpcConfig().isDefaultDisableChannelChatInspect()) {
plugin.getChannelChatInspectHandler().setDisable(p.getUniqueId(), true);
}
}

@EventHandler
Expand Down

0 comments on commit e122387

Please sign in to comment.