geforkt von Mirrors/Paper
151 Zeilen
8.4 KiB
Diff
151 Zeilen
8.4 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Chaoscaot <chaos@chaoscaot.de>
|
|
Date: Tue, 13 Aug 2024 11:46:11 +0200
|
|
Subject: [PATCH] SW Disable Commands
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/commands/Commands.java b/src/main/java/net/minecraft/commands/Commands.java
|
|
index 1d1e76de60e40224f5cb81893f9ee50fe987badb..c2367bcc8dafb71877259dfb46accb42a743d0ee 100644
|
|
--- a/src/main/java/net/minecraft/commands/Commands.java
|
|
+++ b/src/main/java/net/minecraft/commands/Commands.java
|
|
@@ -156,65 +156,64 @@ public class Commands {
|
|
|
|
public Commands(Commands.CommandSelection environment, CommandBuildContext commandRegistryAccess) {
|
|
// Paper
|
|
- AdvancementCommands.register(this.dispatcher);
|
|
- AttributeCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- ExecuteCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- BossBarCommands.register(this.dispatcher, commandRegistryAccess);
|
|
+ //AdvancementCommands.register(this.dispatcher);
|
|
+ //AttributeCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //ExecuteCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //BossBarCommands.register(this.dispatcher, commandRegistryAccess);
|
|
ClearInventoryCommands.register(this.dispatcher, commandRegistryAccess);
|
|
- CloneCommands.register(this.dispatcher, commandRegistryAccess);
|
|
- DamageCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- DataCommands.register(this.dispatcher);
|
|
- DataPackCommand.register(this.dispatcher);
|
|
- DebugCommand.register(this.dispatcher);
|
|
- DefaultGameModeCommands.register(this.dispatcher);
|
|
- DifficultyCommand.register(this.dispatcher);
|
|
+ //CloneCommands.register(this.dispatcher, commandRegistryAccess);
|
|
+ //DamageCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //DataCommands.register(this.dispatcher);
|
|
+ //DataPackCommand.register(this.dispatcher);
|
|
+ //DebugCommand.register(this.dispatcher);
|
|
+ //DefaultGameModeCommands.register(this.dispatcher);
|
|
+ //DifficultyCommand.register(this.dispatcher);
|
|
EffectCommands.register(this.dispatcher, commandRegistryAccess);
|
|
- EmoteCommands.register(this.dispatcher);
|
|
+ //EmoteCommands.register(this.dispatcher);
|
|
EnchantCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- ExperienceCommand.register(this.dispatcher);
|
|
- FillCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //ExperienceCommand.register(this.dispatcher);
|
|
+ //FillCommand.register(this.dispatcher, commandRegistryAccess);
|
|
FillBiomeCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- ForceLoadCommand.register(this.dispatcher);
|
|
- FunctionCommand.register(this.dispatcher);
|
|
+ //ForceLoadCommand.register(this.dispatcher);
|
|
+ //FunctionCommand.register(this.dispatcher);
|
|
GameModeCommand.register(this.dispatcher);
|
|
GameRuleCommand.register(this.dispatcher);
|
|
GiveCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- HelpCommand.register(this.dispatcher);
|
|
- ItemCommands.register(this.dispatcher, commandRegistryAccess);
|
|
+ //HelpCommand.register(this.dispatcher);
|
|
+ //ItemCommands.register(this.dispatcher, commandRegistryAccess);
|
|
KickCommand.register(this.dispatcher);
|
|
KillCommand.register(this.dispatcher);
|
|
- ListPlayersCommand.register(this.dispatcher);
|
|
- LocateCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- LootCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- MsgCommand.register(this.dispatcher);
|
|
- ParticleCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- PlaceCommand.register(this.dispatcher);
|
|
- PlaySoundCommand.register(this.dispatcher);
|
|
- RandomCommand.register(this.dispatcher);
|
|
- ReloadCommand.register(this.dispatcher);
|
|
- RecipeCommand.register(this.dispatcher);
|
|
- ReturnCommand.register(this.dispatcher);
|
|
- RideCommand.register(this.dispatcher);
|
|
- SayCommand.register(this.dispatcher);
|
|
- ScheduleCommand.register(this.dispatcher);
|
|
- ScoreboardCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- SeedCommand.register(this.dispatcher, environment != Commands.CommandSelection.INTEGRATED);
|
|
- SetBlockCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- SetSpawnCommand.register(this.dispatcher);
|
|
+ //ListPlayersCommand.register(this.dispatcher);
|
|
+ //LocateCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //LootCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //MsgCommand.register(this.dispatcher);
|
|
+ //ParticleCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //PlaceCommand.register(this.dispatcher);
|
|
+ //PlaySoundCommand.register(this.dispatcher);
|
|
+ //ReloadCommand.register(this.dispatcher);
|
|
+ //RecipeCommand.register(this.dispatcher);
|
|
+ //ReturnCommand.register(this.dispatcher);
|
|
+ //RideCommand.register(this.dispatcher);
|
|
+ //SayCommand.register(this.dispatcher);
|
|
+ //ScheduleCommand.register(this.dispatcher);
|
|
+ //ScoreboardCommand.register(this.dispatcher);
|
|
+ //SeedCommand.register(this.dispatcher, environment != Commands.CommandSelection.INTEGRATED);
|
|
+ //SetBlockCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //SetSpawnCommand.register(this.dispatcher);
|
|
SetWorldSpawnCommand.register(this.dispatcher);
|
|
SpectateCommand.register(this.dispatcher);
|
|
- SpreadPlayersCommand.register(this.dispatcher);
|
|
- StopSoundCommand.register(this.dispatcher);
|
|
+ //SpreadPlayersCommand.register(this.dispatcher);
|
|
+ //StopSoundCommand.register(this.dispatcher);
|
|
SummonCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- TagCommand.register(this.dispatcher);
|
|
- TeamCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- TeamMsgCommand.register(this.dispatcher);
|
|
+ //TagCommand.register(this.dispatcher);
|
|
+ //TeamCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //TeamMsgCommand.register(this.dispatcher);
|
|
TeleportCommand.register(this.dispatcher);
|
|
- TellRawCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //TellRawCommand.register(this.dispatcher, commandRegistryAccess);
|
|
TickCommand.register(this.dispatcher);
|
|
TimeCommand.register(this.dispatcher);
|
|
- TitleCommand.register(this.dispatcher, commandRegistryAccess);
|
|
- TriggerCommand.register(this.dispatcher);
|
|
+ //TitleCommand.register(this.dispatcher, commandRegistryAccess);
|
|
+ //TriggerCommand.register(this.dispatcher);
|
|
WeatherCommand.register(this.dispatcher);
|
|
WorldBorderCommand.register(this.dispatcher);
|
|
if (JvmProfiler.INSTANCE.isAvailable()) {
|
|
@@ -235,20 +234,20 @@ public class Commands {
|
|
}
|
|
|
|
if (environment.includeDedicated) {
|
|
- BanIpCommands.register(this.dispatcher);
|
|
- BanListCommands.register(this.dispatcher);
|
|
- BanPlayerCommands.register(this.dispatcher);
|
|
- DeOpCommands.register(this.dispatcher);
|
|
- OpCommand.register(this.dispatcher);
|
|
- PardonCommand.register(this.dispatcher);
|
|
- PardonIpCommand.register(this.dispatcher);
|
|
- PerfCommand.register(this.dispatcher);
|
|
+ //BanIpCommands.register(this.dispatcher);
|
|
+ //BanListCommands.register(this.dispatcher);
|
|
+ //BanPlayerCommands.register(this.dispatcher);
|
|
+ //DeOpCommands.register(this.dispatcher);
|
|
+ //OpCommand.register(this.dispatcher);
|
|
+ //PardonCommand.register(this.dispatcher);
|
|
+ //PardonIpCommand.register(this.dispatcher);
|
|
+ //PerfCommand.register(this.dispatcher);
|
|
SaveAllCommand.register(this.dispatcher);
|
|
SaveOffCommand.register(this.dispatcher);
|
|
SaveOnCommand.register(this.dispatcher);
|
|
- SetPlayerIdleTimeoutCommand.register(this.dispatcher);
|
|
+ //SetPlayerIdleTimeoutCommand.register(this.dispatcher);
|
|
StopCommand.register(this.dispatcher);
|
|
- TransferCommand.register(this.dispatcher);
|
|
+ //TransferCommand.register(this.dispatcher);
|
|
WhitelistCommand.register(this.dispatcher);
|
|
}
|
|
|