SteamWar/BauSystem2.0
Archiviert
12
0

Translatable #62

Zusammengeführt
YoyoNow hat 47 Commits von Translatable nach master 2021-12-27 16:38:13 +01:00 zusammengeführt
3 geänderte Dateien mit 13 neuen und 29 gelöschten Zeilen
Nur Änderungen aus Commit 788b65575f werden angezeigt - Alle Commits anzeigen

Datei anzeigen

@ -19,7 +19,6 @@
package de.steamwar.bausystem.features.util; package de.steamwar.bausystem.features.util;
import de.steamwar.bausystem.BauSystem;
import de.steamwar.bausystem.SWUtils; import de.steamwar.bausystem.SWUtils;
import de.steamwar.bausystem.linkage.LinkageType; import de.steamwar.bausystem.linkage.LinkageType;
import de.steamwar.bausystem.linkage.Linked; import de.steamwar.bausystem.linkage.Linked;
@ -33,18 +32,9 @@ public class StructureVoidCommand extends SWCommand {
public StructureVoidCommand() { public StructureVoidCommand() {
super("structureVoid", "structure", "void", "structurevoid"); super("structureVoid", "structure", "void", "structurevoid");
setMessage(BauSystem.MESSAGE);
} }
/* @Register(description = "STRUCTURE_VOID_COMMAND_HELP")
@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(description = "STRUCTURE-VOID_COMMAND_HELP")
public void genericCommand(Player p) { public void genericCommand(Player p) {
SWUtils.giveItemToPlayer(p, new ItemStack(Material.STRUCTURE_VOID, 1)); SWUtils.giveItemToPlayer(p, new ItemStack(Material.STRUCTURE_VOID, 1));
} }

Datei anzeigen

@ -19,11 +19,11 @@
package de.steamwar.bausystem.features.util; package de.steamwar.bausystem.features.util;
import de.steamwar.bausystem.SWUtils; import de.steamwar.bausystem.BauSystem;
import de.steamwar.bausystem.config.ColorConfig;
import de.steamwar.bausystem.linkage.LinkageType; import de.steamwar.bausystem.linkage.LinkageType;
import de.steamwar.bausystem.linkage.Linked; import de.steamwar.bausystem.linkage.Linked;
import de.steamwar.command.SWCommand; import de.steamwar.command.SWCommand;
import net.md_5.bungee.api.ChatMessageType;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.potion.PotionEffect; import org.bukkit.potion.PotionEffect;
import org.bukkit.potion.PotionEffectType; import org.bukkit.potion.PotionEffectType;
@ -35,19 +35,14 @@ public class WaterVisionCommand extends SWCommand {
super("watervision", "wv"); super("watervision", "wv");
} }
@Register(help = true) @Register(description = "WATER_VISION_HELP")
public void help(final Player p, final String... args) {
p.sendMessage(ColorConfig.OTHER + "/" + ColorConfig.HIGHLIGHT + "watervision " + ColorConfig.OTHER + "-" + ColorConfig.BASE + " Schalte Watervision an oder aus.");
}
@Register
public void genericCommand(Player p) { public void genericCommand(Player p) {
if (p.hasPotionEffect(PotionEffectType.WATER_BREATHING)) { if (p.hasPotionEffect(PotionEffectType.WATER_BREATHING)) {
p.removePotionEffect(PotionEffectType.WATER_BREATHING); p.removePotionEffect(PotionEffectType.WATER_BREATHING);
SWUtils.sendToActionbar(p, ColorConfig.HIGHLIGHT + "Wassersicht deaktiviert"); BauSystem.MESSAGE.sendPrefixless("WATER_VISION_DISABLE", p, ChatMessageType.ACTION_BAR);
return; return;
} }
p.addPotionEffect(new PotionEffect(PotionEffectType.WATER_BREATHING, 1000000, 255, false, false)); p.addPotionEffect(new PotionEffect(PotionEffectType.WATER_BREATHING, 1000000, 255, false, false));
SWUtils.sendToActionbar(p, ColorConfig.HIGHLIGHT + "Wassersicht aktiviert"); BauSystem.MESSAGE.sendPrefixless("WATER_VISION_ENABLE", p, ChatMessageType.ACTION_BAR);
} }
} }

Datei anzeigen

@ -37,9 +37,8 @@ public class WorldEditListener implements Listener {
if (!isWorldEditCommand(e.getMessage().split(" ")[0])) return; if (!isWorldEditCommand(e.getMessage().split(" ")[0])) return;
Player p = e.getPlayer(); Player p = e.getPlayer();
if (!Permission.hasPermission(p, Permission.WORLDEDIT)) { if (!Permission.hasPermission(p, Permission.WORLDEDIT)) {
p.sendMessage(BauSystem.PREFIX + "§cDu darfst hier kein WorldEdit benutzen"); BauSystem.MESSAGE.send("WORLD_EDIT_NO_PERMS", p);
e.setCancelled(true); e.setCancelled(true);
} }
} }