SteamWar/BauSystem2.0
Archiviert
12
0

Add StructureVoidCommand #52

Zusammengeführt
YoyoNow hat 1 Commits von StructureVoid nach master 2021-11-02 12:23:22 +01:00 zusammengeführt
2 geänderte Dateien mit 50 neuen und 0 gelöschten Zeilen

Datei anzeigen

@ -387,6 +387,8 @@ OTHER_TIME_RESULT=§7§oWhooosh
OTHER_WORLDSPAWN_HELP_1=§8/§eworldspawn §8-§e Teleportiere dich zum Spawn
# DebugStick
DEBUG-STICK_COMMAND_HELP=§8/§edebugstick §8-§7 Erhalte einen DebugStick
# StructureVoid
STRUCTURE-VOID_COMMAND_HELP=§8/§estructureVoid §8-§7 Erhalte ein StructureVoid
# NightVision
NIGHT-VISION_COMMAND_HELP=§8/§enightvision §8-§7 Schalte Nightvision an oder aus.
NIGHT-VISION_OFF=§eNightvision deaktiviert

Datei anzeigen

@ -0,0 +1,48 @@
/*
* This file is a part of the SteamWar software.
*
* Copyright (C) 2021 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 <https://www.gnu.org/licenses/>.
*/
package de.steamwar.bausystem.features.util;
import de.steamwar.bausystem.BauSystem;
import de.steamwar.bausystem.SWUtils;
import de.steamwar.bausystem.linkage.LinkageType;
import de.steamwar.bausystem.linkage.Linked;
import de.steamwar.command.SWCommand;
import org.bukkit.Material;
import org.bukkit.entity.Player;
import org.bukkit.inventory.ItemStack;
@Linked(LinkageType.COMMAND)
public class StructureVoidCommand extends SWCommand {
public StructureVoidCommand() {
super("structureVoid", "structure", "void", "structurevoid");
}
@Register(help = true)
public void genericHelp(Player p, String... args) {
BauSystem.MESSAGE.send("COMMAND_HELP_HEAD", p, "structureVoid");
BauSystem.MESSAGE.send("STRUCTURE-VOID_COMMAND_HELP", p);
}
@Register
public void genericCommand(Player p) {
SWUtils.giveItemToPlayer(p, new ItemStack(Material.STRUCTURE_VOID, 1));
}
}