13
0

Merge pull request 'Adding custom tablist name capabilities' (#9) from customTablistNames into master

Reviewed-by: Chaoscaot <chaoscaot444@gmail.com>
Dieser Commit ist enthalten in:
Lixfel 2020-10-29 19:52:35 +01:00
Commit a7f0dd4792

Datei anzeigen

@ -31,8 +31,10 @@ import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.net.InetSocketAddress;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.concurrent.TimeUnit;
import java.util.logging.Level;
import java.util.logging.Logger;
@ -68,6 +70,7 @@ public class Subserver implements Runnable {
private boolean started;
private final List<ProxiedPlayer> cachedPlayers = new LinkedList<>();
private final Map<ProxiedPlayer, String> tablistNames = new HashMap<>();
public Subserver(Servertype type, String serverName, int port, String... command){
this(type, serverName, port, () -> {}, command);
@ -103,6 +106,9 @@ public class Subserver implements Runnable {
public Servertype getType(){
return type;
}
public Map<ProxiedPlayer, String> getTablistNames(){
return tablistNames;
}
public void sendPlayer(ProxiedPlayer p){
if(!started){