Mirror von
https://github.com/GeyserMC/Geyser.git
synchronisiert 2024-11-20 06:50:09 +01:00
Register /geyser stop
only on standalone (#2569)
We don't want to condone stopping Geyser in the middle of a plugin session, especially when there's no way to start it back up again.
Dieser Commit ist enthalten in:
Ursprung
52ef3d392a
Commit
7454033277
@ -22,8 +22,6 @@ permissions:
|
||||
description: Puts an items in your offhand.
|
||||
geyser.command.reload:
|
||||
description: Reloads the Geyser configurations. Kicks all players when used!
|
||||
geyser.command.shutdown:
|
||||
description: Shuts down Geyser.
|
||||
geyser.command.statistics:
|
||||
description: Shows the statistics of the player on the server.
|
||||
geyser.command.version:
|
||||
|
@ -27,6 +27,7 @@ package org.geysermc.connector.command;
|
||||
|
||||
import lombok.Getter;
|
||||
|
||||
import org.geysermc.common.PlatformType;
|
||||
import org.geysermc.connector.GeyserConnector;
|
||||
import org.geysermc.connector.command.defaults.*;
|
||||
import org.geysermc.connector.network.session.GeyserSession;
|
||||
@ -47,13 +48,15 @@ public abstract class CommandManager {
|
||||
registerCommand(new HelpCommand(connector, "help", "geyser.commands.help.desc", "geyser.command.help"));
|
||||
registerCommand(new ListCommand(connector, "list", "geyser.commands.list.desc", "geyser.command.list"));
|
||||
registerCommand(new ReloadCommand(connector, "reload", "geyser.commands.reload.desc", "geyser.command.reload"));
|
||||
registerCommand(new StopCommand(connector, "stop", "geyser.commands.stop.desc", "geyser.command.stop"));
|
||||
registerCommand(new OffhandCommand(connector, "offhand", "geyser.commands.offhand.desc", "geyser.command.offhand"));
|
||||
registerCommand(new DumpCommand(connector, "dump", "geyser.commands.dump.desc", "geyser.command.dump"));
|
||||
registerCommand(new VersionCommand(connector, "version", "geyser.commands.version.desc", "geyser.command.version"));
|
||||
registerCommand(new SettingsCommand(connector, "settings", "geyser.commands.settings.desc", "geyser.command.settings"));
|
||||
registerCommand(new StatisticsCommand(connector, "statistics", "geyser.commands.statistics.desc", "geyser.command.statistics"));
|
||||
registerCommand(new AdvancementsCommand("advancements", "geyser.commands.advancements.desc", "geyser.command.advancements"));
|
||||
if (GeyserConnector.getInstance().getPlatformType() == PlatformType.STANDALONE) {
|
||||
registerCommand(new StopCommand(connector, "stop", "geyser.commands.stop.desc", "geyser.command.stop"));
|
||||
}
|
||||
}
|
||||
|
||||
public void registerCommand(GeyserCommand command) {
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren