Signed-off-by: yoyosource <yoyosource@nidido.de>
Dieser Commit ist enthalten in:
Ursprung
b902fffb76
Commit
ca730f7b8f
@ -78,7 +78,7 @@ public class KillcheckerCommand extends SWCommand implements Listener {
|
|||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
Set<Region> regions = new HashSet<>();
|
Set<Region> regions = new HashSet<>();
|
||||||
visualizers.forEach((region, visualizer) -> {
|
visualizers.forEach((region, visualizer) -> {
|
||||||
if (visualizer.hide(player)) {
|
if (visualizer.disconnect(player)) {
|
||||||
regions.add(region);
|
regions.add(region);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -97,6 +97,7 @@ public class KillcheckerVisualizer {
|
|||||||
if (block.getType().isAir()) continue;
|
if (block.getType().isAir()) continue;
|
||||||
String name = block.getType().name();
|
String name = block.getType().name();
|
||||||
if (!name.endsWith("_WOOL") && !name.endsWith("_STAINED_GLASS") && !name.endsWith("_CONCRETE") && !name.endsWith("_TERRACOTTA")) continue;
|
if (!name.endsWith("_WOOL") && !name.endsWith("_STAINED_GLASS") && !name.endsWith("_CONCRETE") && !name.endsWith("_TERRACOTTA")) continue;
|
||||||
|
if (name.equals("_GLAZED_TERRACOTTA")) continue;
|
||||||
Cuboid cuboid = create(block.getType(), x, y, z);
|
Cuboid cuboid = create(block.getType(), x, y, z);
|
||||||
cuboids.add(cuboid);
|
cuboids.add(cuboid);
|
||||||
for (int dx = (int) cuboid.getX(); dx <= cuboid.getDx(); dx++) {
|
for (int dx = (int) cuboid.getX(); dx <= cuboid.getDx(); dx++) {
|
||||||
@ -378,6 +379,19 @@ public class KillcheckerVisualizer {
|
|||||||
bossBarService.remove(player, region, "killchecker");
|
bossBarService.remove(player, region, "killchecker");
|
||||||
if (players.isEmpty()) {
|
if (players.isEmpty()) {
|
||||||
outline.close();
|
outline.close();
|
||||||
|
inner.close();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean disconnect(Player player) {
|
||||||
|
players.remove(player);
|
||||||
|
areaPlayers.remove(player);
|
||||||
|
bossBarService.remove(player, region, "killchecker");
|
||||||
|
if (players.isEmpty()) {
|
||||||
|
outline.close();
|
||||||
|
inner.close();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren