diff --git a/BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/ExperimentalCommand.java b/BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/ExperimentalCommand.java new file mode 100644 index 00000000..a765a351 --- /dev/null +++ b/BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/ExperimentalCommand.java @@ -0,0 +1,31 @@ +/* + * This file is a part of the SteamWar software. + * + * Copyright (C) 2026 SteamWar.de-Serverteam + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ + +package de.steamwar.bausystem.features.experimental; + +import de.steamwar.command.SWCommand; +import de.steamwar.linkage.Linked; + +@Linked +public class ExperimentalCommand extends SWCommand { + + public ExperimentalCommand() { + super("experimental", "experiment"); + } +} diff --git a/BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/redstone_engine/RedstoneEngineCommand.java b/BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/redstone_engine/RedstoneEngine.java similarity index 93% rename from BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/redstone_engine/RedstoneEngineCommand.java rename to BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/redstone_engine/RedstoneEngine.java index 40c8ff08..8dc99349 100644 --- a/BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/redstone_engine/RedstoneEngineCommand.java +++ b/BauSystem/BauSystem_Main/src/de/steamwar/bausystem/features/experimental/redstone_engine/RedstoneEngine.java @@ -21,8 +21,8 @@ package de.steamwar.bausystem.features.experimental.redstone_engine; import de.steamwar.bausystem.region.Region; import de.steamwar.bausystem.utils.ScoreboardElement; +import de.steamwar.command.AbstractSWCommand; import de.steamwar.command.SWCommand; -import de.steamwar.linkage.Linked; import io.papermc.paper.configuration.WorldConfiguration; import net.kyori.adventure.text.Component; import net.kyori.adventure.text.format.NamedTextColor; @@ -37,18 +37,19 @@ import org.bukkit.event.player.PlayerJoinEvent; import java.util.Collection; import java.util.List; -@Linked -public class RedstoneEngineCommand extends SWCommand implements Listener, ScoreboardElement { +@AbstractSWCommand.PartOf(RedstoneEngine.class) +public class RedstoneEngine extends SWCommand implements Listener, ScoreboardElement { - public RedstoneEngineCommand() { - super("redstoneengine"); + public RedstoneEngine() { + super(""); } private WorldConfiguration.Misc getConfig() { return ((CraftWorld) Bukkit.getWorlds().get(0)).getHandle().paperConfig().misc; } - @Register + @Register("redstone") + @Register("redstoneengine") public void setRedstoneEngine(Player player, @StaticValue("alternate_current") String __, WorldConfiguration.Misc.AlternateCurrentUpdateOrder updateOrder) { WorldConfiguration.Misc misc = getConfig(); misc.redstoneImplementation = WorldConfiguration.Misc.RedstoneImplementation.ALTERNATE_CURRENT; @@ -56,7 +57,8 @@ public class RedstoneEngineCommand extends SWCommand implements Listener, Scoreb broadcastTitle(Bukkit.getOnlinePlayers()); } - @Register + @Register("redstone") + @Register("redstoneengine") public void setRedstoneEngine(Player player, WorldConfiguration.Misc.RedstoneImplementation implementation) { getConfig().redstoneImplementation = implementation; broadcastTitle(Bukkit.getOnlinePlayers());