forked from SteamWar/SteamWar
Format code
This commit is contained in:
@@ -40,8 +40,7 @@ public class FightserverPortal implements PortalHandler, Comparable<FightserverP
|
||||
public static FightserverPortal findFree(String gamemode) {
|
||||
List<FightserverPortal> list = portals.getOrDefault(gamemode, Collections.emptyList());
|
||||
for (FightserverPortal portal : list) {
|
||||
if (portal.server == null)
|
||||
return portal;
|
||||
if (portal.server == null) return portal;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
@@ -107,10 +106,11 @@ public class FightserverPortal implements PortalHandler, Comparable<FightserverP
|
||||
|
||||
FightInfoPacket info = server.current();
|
||||
|
||||
if (fightStateCountdown(info.getFightState()))
|
||||
if (fightStateCountdown(info.getFightState())) {
|
||||
hologram.updateText(String.format("§7%s §e%s §7%d§8:§7%02d", server.getServerName(), fightStateMapper(info.getFightState()), info.getCountdown() / 60, info.getCountdown() % 60));
|
||||
else
|
||||
} else {
|
||||
hologram.updateText(String.format("§7%s §e%s", server.getServerName(), fightStateMapper(info.getFightState())));
|
||||
}
|
||||
}
|
||||
|
||||
public void updateBluePlayers() {
|
||||
@@ -137,8 +137,7 @@ public class FightserverPortal implements PortalHandler, Comparable<FightserverP
|
||||
});
|
||||
|
||||
for (SteamwarUser user : remainingPlayers) {
|
||||
if (remainingLocations.isEmpty())
|
||||
break;
|
||||
if (remainingLocations.isEmpty()) break;
|
||||
|
||||
npcs.add(new NPC(remainingLocations.remove(0), user.getUUID(), user.getUserName()));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user