Archiviert
13
0

lobby-update #16

Geschlossen
YoyoNow möchte 8 Commits von lobby-update nach master mergen
3 geänderte Dateien mit 7 neuen und 72 gelöschten Zeilen
Nur Änderungen aus Commit 3d55bd5df6 werden angezeigt - Alle Commits anzeigen

Datei anzeigen

@ -29,18 +29,18 @@ import org.bukkit.entity.Player;
public class FlyCommand implements CommandExecutor {
@Override
public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
if(!(sender instanceof Player))
if(!(sender instanceof Player)) {
Veraltet
Review

Klammer können weg

Klammer können weg
return false;
}
Player player = (Player) sender;
SteamwarUser steamwarUser = SteamwarUser.get(player.getUniqueId());
UserGroup userGroup = steamwarUser.getUserGroup();
if (userGroup == UserGroup.Member) {
player.sendMessage("§cDu verfügst nicht über die benötigten Rechte!");
player.sendMessage("§cUnbekannter Befehl.");
Veraltet
Review

Wenn dann einheitlich: Unbekannter Befehl.

Wenn dann einheitlich: Unbekannter Befehl.
return false;
}

Datei anzeigen

@ -28,13 +28,13 @@ import org.bukkit.util.Vector;
public class PlayerMoveListener implements Listener {
private static final Vector borderMinVector = new Vector(Config.BorderMinX, Config.BorderMinY, Config.BorderMinZ);
private static final Vector borderMaxVector = new Vector(Config.BorderMaxX, Config.BorderMaxY, Config.BorderMaxZ);
@EventHandler
public void handleWorldBorder(PlayerMoveEvent event) {
Location to = event.getTo();
if (!isInRegion(
new Vector(Config.BorderMinX, Config.BorderMinY, Config.BorderMinZ),
new Vector(Config.BorderMaxX, Config.BorderMaxY, Config.BorderMaxZ),
to.toVector())) {
if (!isInRegion(borderMinVector, borderMaxVector, to.toVector())) {
event.getPlayer().teleport(event.getFrom());
}
}

Datei anzeigen

@ -1,65 +0,0 @@
/*
*
* This file is a part of the SteamWar software.
*
* Copyright (C) 2020 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.lobby.particle;
import org.bukkit.Location;
import org.bukkit.Material;
import org.bukkit.Particle;
import org.bukkit.World;
import org.bukkit.entity.Player;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
public class WingsParticle extends SpecialParticle {
private static class Relative {
private double up = 0;
private double side = 0;
public Relative(double up, double side) {
this.up = up;
this.side = side;
}
}
private static final Set<Relative> particleRelatives = new HashSet<>();
private Particle particle;
public WingsParticle(Material material, String name, List<String> lore, Particle particle) {
super(material, name, lore);
this.particle = particle;
}
@Override
public void particle(World world, Player player, int deg) {
Location location = player.getLocation().add(0, 1.7, 0);
particleRelatives.forEach(relative -> {
});
}
}