RedstoneTester #202
@ -24,7 +24,7 @@ import de.steamwar.bausystem.Permission;
|
|||||||
import de.steamwar.bausystem.SWUtils;
|
import de.steamwar.bausystem.SWUtils;
|
||||||
import de.steamwar.bausystem.world.RedstoneListener;
|
import de.steamwar.bausystem.world.RedstoneListener;
|
||||||
import de.steamwar.bausystem.world.Welt;
|
import de.steamwar.bausystem.world.Welt;
|
||||||
import de.steamwar.core.Core;
|
import de.steamwar.core.VersionedRunnable;
|
||||||
import org.bukkit.command.Command;
|
import org.bukkit.command.Command;
|
||||||
import org.bukkit.command.CommandExecutor;
|
import org.bukkit.command.CommandExecutor;
|
||||||
import org.bukkit.command.CommandSender;
|
import org.bukkit.command.CommandSender;
|
||||||
@ -45,17 +45,15 @@ public class CommandRedstoneTester implements CommandExecutor {
|
|||||||
if (!(commandSender instanceof Player))
|
if (!(commandSender instanceof Player))
|
||||||
return false;
|
return false;
|
||||||
Player player = (Player) commandSender;
|
Player player = (Player) commandSender;
|
||||||
if (Core.getVersion() >= 15) {
|
VersionedRunnable.call(new VersionedRunnable(() -> {
|
||||||
player.sendMessage(BauSystem.PREFIX + "Der RedstoneTester ist nicht in der 1.12 verfügbar");
|
player.sendMessage(BauSystem.PREFIX + "Der RedstoneTester ist nicht in der 1.12 verfügbar");
|
||||||
return false;
|
}, 8), new VersionedRunnable(() -> {
|
||||||
}
|
|
||||||
|
|
||||||
if (!permissionCheck(player)) {
|
if (!permissionCheck(player)) {
|
||||||
return false;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
player.sendMessage(BauSystem.PREFIX + "Messe die Zeit zwischen der Aktivierung zweier Redstone Komponenten");
|
player.sendMessage(BauSystem.PREFIX + "Messe die Zeit zwischen der Aktivierung zweier Redstone Komponenten");
|
||||||
SWUtils.giveItemToPlayer(player, RedstoneListener.WAND);
|
SWUtils.giveItemToPlayer(player, RedstoneListener.WAND);
|
||||||
|
}, 15));
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren