SteamWar/MissileWars
Archiviert
13
0

Update1.0 #11

Geschlossen
YoyoNow möchte 11 Commits von Update1.0 nach master mergen
2 geänderte Dateien mit 9 neuen und 7 gelöschten Zeilen
Nur Änderungen aus Commit 388323e6b0 werden angezeigt - Alle Commits anzeigen

Datei anzeigen

@ -77,7 +77,8 @@ public class MWTeam {
return spawn; return spawn;
} }
public void join (Player p) { @SuppressWarnings("java:S1874")
public void join(Player p) {
players.add(p); players.add(p);
p.teleport(spawn); p.teleport(spawn);
p.setGameMode(GameMode.SURVIVAL); p.setGameMode(GameMode.SURVIVAL);
@ -87,11 +88,10 @@ public class MWTeam {
if (MissileWars.getFightState() == FightState.WAITING && !enemy().getPlayers().isEmpty()) if (MissileWars.getFightState() == FightState.WAITING && !enemy().getPlayers().isEmpty())
MissileWars.startRound(); MissileWars.startRound();
} }
public void leave (Player p) {
if(!players.contains(p))
return;
@SuppressWarnings("java:S1874")
public void leave(Player p) {
if(!players.contains(p)) return;
players.remove(p); players.remove(p);
sbteam.removePlayer(p); sbteam.removePlayer(p);
if (players.isEmpty() && MissileWars.getFightState() == FightState.FIGHTING) if (players.isEmpty() && MissileWars.getFightState() == FightState.FIGHTING)

Datei anzeigen

@ -20,7 +20,6 @@
package de.steamwar.misslewars.countdowns; package de.steamwar.misslewars.countdowns;
import de.steamwar.misslewars.*; import de.steamwar.misslewars.*;
import de.steamwar.misslewars.items.Missile;
import de.steamwar.misslewars.items.SpecialItem; import de.steamwar.misslewars.items.SpecialItem;
import org.bukkit.Bukkit; import org.bukkit.Bukkit;
import org.bukkit.Material; import org.bukkit.Material;
@ -29,7 +28,10 @@ import org.bukkit.inventory.Inventory;
import org.bukkit.inventory.ItemStack; import org.bukkit.inventory.ItemStack;
import org.bukkit.scheduler.BukkitTask; import org.bukkit.scheduler.BukkitTask;
import java.util.*; import java.util.ArrayList;
import java.util.EnumSet;
import java.util.List;
import java.util.Random;
public class ItemCountdown extends StateDependent { public class ItemCountdown extends StateDependent {