idk what i fucked up here all files are new in git?

This commit is contained in:
destro174
2021-06-20 22:03:39 +02:00
parent a5c23d842d
commit 5bea7c95f9
41 changed files with 21 additions and 49 deletions
Regular → Executable
View File
-2
View File
@@ -1,7 +1,6 @@
package com.alttd.chat;
import com.alttd.chat.commands.GlobalAdminChat;
import com.alttd.chat.commands.GlobalChat;
import com.alttd.chat.config.Config;
import com.alttd.chat.handlers.ChatHandler;
import com.alttd.chat.handlers.ServerHandler;
@@ -84,7 +83,6 @@ public class VelocityChat {
public void loadCommands() {
new GlobalAdminChat(server);
new GlobalChat(server);
// all (proxy)commands go here
}
-2
View File
@@ -1,7 +1,6 @@
package com.alttd.chat.commands;
import com.alttd.chat.VelocityChat;
import com.alttd.chat.events.GlobalAdminChatEvent;
import com.alttd.chat.config.Config;
import com.mojang.brigadier.arguments.StringArgumentType;
import com.mojang.brigadier.builder.LiteralArgumentBuilder;
@@ -10,7 +9,6 @@ import com.mojang.brigadier.tree.LiteralCommandNode;
import com.velocitypowered.api.command.BrigadierCommand;
import com.velocitypowered.api.command.CommandMeta;
import com.velocitypowered.api.command.CommandSource;
import com.velocitypowered.api.proxy.Player;
import com.velocitypowered.api.proxy.ProxyServer;
public class GlobalAdminChat {
@@ -1,43 +0,0 @@
package com.alttd.chat.commands;
import com.alttd.chat.VelocityChat;
import com.alttd.chat.config.Config;
import com.mojang.brigadier.arguments.StringArgumentType;
import com.mojang.brigadier.builder.LiteralArgumentBuilder;
import com.mojang.brigadier.builder.RequiredArgumentBuilder;
import com.mojang.brigadier.tree.LiteralCommandNode;
import com.velocitypowered.api.command.BrigadierCommand;
import com.velocitypowered.api.command.CommandMeta;
import com.velocitypowered.api.command.CommandSource;
import com.velocitypowered.api.proxy.Player;
import com.velocitypowered.api.proxy.ProxyServer;
public class GlobalChat {
public GlobalChat(ProxyServer proxyServer) {
// LiteralCommandNode<CommandSource> command = LiteralArgumentBuilder
// .<CommandSource>literal("globalchat")
// .requires(ctx -> ctx.hasPermission("command.proxy.globalchat"))// TODO permission system? load permissions from config?
// .requires(ctx -> ctx instanceof Player) // players only can use this
// .then(RequiredArgumentBuilder
// .<CommandSource, String>argument("message", StringArgumentType.greedyString())
// .executes(context -> {
// VelocityChat.getPlugin().getChatHandler().globalChat((Player) context.getSource(), context.getArgument("message", String.class));
// return 1;
// })
// )
// .executes(context -> 0) // todo info message /usage
// .build();
//
// BrigadierCommand brigadierCommand = new BrigadierCommand(command);
//
// CommandMeta.Builder metaBuilder = proxyServer.getCommandManager().metaBuilder(brigadierCommand);
//
// for (String alias : Config.GCALIAS) {
// metaBuilder.aliases(alias);
// }
// CommandMeta meta = metaBuilder.build();
//
// proxyServer.getCommandManager().register(meta, brigadierCommand);
}
}
View File
View File
View File
View File
View File
View File
View File
View File
View File