mirror of
https://github.com/darksaid98/Carbon.git
synced 2026-12-03 06:28:54 +00:00
Bump adventure and fix startup issues
This commit is contained in:
1 parent
61a2b4cd0f
commit
8e7a625ad6
5 files changed
+19
-12
No files matched your search
@@ -7,7 +7,6 @@ import net.draycia.carbon.api.channels.ChannelRegistry;
|
||||
import net.draycia.carbon.api.channels.ChatChannel;
|
||||
import net.draycia.carbon.api.events.misc.CarbonEvents;
|
||||
import net.draycia.carbon.api.events.ChannelRegisterEvent;
|
||||
import net.draycia.carbon.common.commands.AliasedChannelCommand;
|
||||
import org.checkerframework.checker.nullness.qual.MonotonicNonNull;
|
||||
import org.checkerframework.checker.nullness.qual.NonNull;
|
||||
import org.checkerframework.checker.nullness.qual.Nullable;
|
||||
@@ -101,7 +100,6 @@ public class ChannelManager {
|
||||
|
||||
if (channel instanceof TextChannel) {
|
||||
prefix = ((TextChannel) channel).messagePrefix();
|
||||
new AliasedChannelCommand(this.carbonChat.commandManager(), (TextChannel) channel);
|
||||
}
|
||||
|
||||
if (prefix != null && !prefix.trim().isEmpty()) {
|
||||
|
||||
+1
-1
@@ -16,7 +16,7 @@ import java.util.stream.StreamSupport;
|
||||
public final class PlayerUserArgument<C> extends CommandArgument<C, PlayerUser> {
|
||||
|
||||
private PlayerUserArgument(final boolean required) {
|
||||
super(required, "channel", PlayerUserArgument::parser,
|
||||
super(required, "user", PlayerUserArgument::parser,
|
||||
"",
|
||||
PlayerUser.class, PlayerUserArgument::suggestions);
|
||||
}
|
||||
|
||||
+10
@@ -1,7 +1,11 @@
|
||||
package net.draycia.carbon.common.commands.misc;
|
||||
|
||||
import cloud.commandframework.CommandManager;
|
||||
import net.draycia.carbon.api.CarbonChatProvider;
|
||||
import net.draycia.carbon.api.channels.ChatChannel;
|
||||
import net.draycia.carbon.api.channels.TextChannel;
|
||||
import net.draycia.carbon.api.users.CarbonUser;
|
||||
import net.draycia.carbon.common.commands.AliasedChannelCommand;
|
||||
import net.draycia.carbon.common.commands.ChannelCommand;
|
||||
import net.draycia.carbon.common.commands.ChannelListCommand;
|
||||
import net.draycia.carbon.common.commands.ChatReloadCommand;
|
||||
@@ -41,6 +45,12 @@ public final class CommandRegistrar {
|
||||
new SpyChannelCommand(commandManager);
|
||||
new SudoChannelCommand(commandManager);
|
||||
new ToggleCommand(commandManager);
|
||||
|
||||
for (final ChatChannel channel : CarbonChatProvider.carbonChat().channelRegistry()) {
|
||||
if (channel instanceof TextChannel) {
|
||||
new AliasedChannelCommand(commandManager, (TextChannel) channel);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user