Update default templates

This commit is contained in:
ME1312 2021-11-30 23:55:50 -05:00
parent a0b8df47ac
commit aef7a164e6
No known key found for this signature in database
GPG Key ID: FEFFE2F698E88FA8
28 changed files with 51 additions and 119 deletions

View File

@ -28,7 +28,7 @@
<dependency> <dependency>
<groupId>net.ME1312.Galaxi</groupId> <groupId>net.ME1312.Galaxi</groupId>
<artifactId>GalaxiUtil</artifactId> <artifactId>GalaxiUtil</artifactId>
<version>21w44c</version> <version>21w47d</version>
<scope>compile</scope> <scope>compile</scope>
</dependency> </dependency>
</dependencies> </dependencies>

View File

@ -84,7 +84,6 @@
<copy file="${basedir}/../Artifacts/SubServers.Client.Universal.jar" tofile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/client.jar" /> <copy file="${basedir}/../Artifacts/SubServers.Client.Universal.jar" tofile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/client.jar" />
<mkdir dir="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates" /> <mkdir dir="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates" />
<zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/forge.zip" includes="Forge/**" /> <zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/forge.zip" includes="Forge/**" />
<zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/paper.zip" includes="Paper/**" />
<zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/purpur.zip" includes="Purpur/**" /> <zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/purpur.zip" includes="Purpur/**" />
<zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/spigot.zip" includes="Spigot/**" /> <zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/spigot.zip" includes="Spigot/**" />
<zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/sponge.zip" includes="Sponge/**" /> <zip basedir="${basedir}/../SubServers.Creator" destfile="${project.build.directory}/classes/net/ME1312/SubServers/Bungee/Library/Files/Templates/sponge.zip" includes="Sponge/**" />

View File

@ -534,6 +534,11 @@ public abstract class Host implements ExtraDataHandler<String> {
return signature; return signature;
} }
@Override
public boolean equals(Object obj) {
return obj instanceof Host && signature.equals(((Host) obj).signature);
}
@Override @Override
public void addExtra(String handle, Object value) { public void addExtra(String handle, Object value) {
Util.nullpo(handle, value); Util.nullpo(handle, value);

View File

@ -156,6 +156,11 @@ public class Proxy implements ClientHandler, ExtraDataHandler<String> {
return signature; return signature;
} }
@Override
public boolean equals(Object obj) {
return obj instanceof Proxy && signature.equals(((Proxy) obj).signature);
}
@Override @Override
public void addExtra(String handle, Object value) { public void addExtra(String handle, Object value) {
Util.nullpo(handle, value); Util.nullpo(handle, value);

View File

@ -265,6 +265,11 @@ public class ServerImpl extends BungeeServerInfo implements Server {
return signature; return signature;
} }
@Override
public boolean equals(Object obj) {
return obj instanceof ServerImpl && signature.equals(((ServerImpl) obj).signature);
}
@Override @Override
public void addExtra(String handle, Object value) { public void addExtra(String handle, Object value) {
Util.nullpo(handle, value); Util.nullpo(handle, value);

View File

@ -537,4 +537,9 @@ public abstract class SubCreator {
* Reload SubCreator * Reload SubCreator
*/ */
public abstract void reload(); public abstract void reload();
@Override
public boolean equals(Object obj) {
return obj instanceof SubCreator && getHost().getSignature().equals(((SubCreator) obj).getHost().getSignature());
}
} }

View File

@ -188,7 +188,12 @@ public abstract class SubServerImpl extends ServerImpl implements SubServer {
return servers; return servers;
} }
@SuppressWarnings({"deprecation", "unchecked"}) @Override
public boolean equals(Object obj) {
return obj instanceof SubServerImpl && super.equals(obj);
}
@SuppressWarnings("deprecation")
@Override @Override
public ObjectMap<String> forSubData() { public ObjectMap<String> forSubData() {
ObjectMap<String> sinfo = super.forSubData(); ObjectMap<String> sinfo = super.forSubData();

View File

@ -92,7 +92,7 @@ public final class SubProxy extends BungeeCommon implements Listener {
public SubProtocol subprotocol; public SubProtocol subprotocol;
public SubDataServer subdata = null; public SubDataServer subdata = null;
public SubServer sudo = null; public SubServer sudo = null;
public static final Version version = Version.fromString("2.17.1a"); public static final Version version = Version.fromString("2.18a");
public final Proxy mProxy; public final Proxy mProxy;
public boolean canSudo = false; public boolean canSudo = false;
@ -145,9 +145,6 @@ public final class SubProxy extends BungeeCommon implements Listener {
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/spigot.zip"), new File(dir, "Templates")); Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/spigot.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Created ./SubServers/Templates/Spigot"); Logger.get("SubServers").info("Created ./SubServers/Templates/Spigot");
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/paper.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Created ./SubServers/Templates/Paper");
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/purpur.zip"), new File(dir, "Templates")); Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/purpur.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Created ./SubServers/Templates/Purpur"); Logger.get("SubServers").info("Created ./SubServers/Templates/Purpur");
@ -158,34 +155,30 @@ public final class SubProxy extends BungeeCommon implements Listener {
Logger.get("SubServers").info("Created ./SubServers/Templates/Sponge"); Logger.get("SubServers").info("Created ./SubServers/Templates/Sponge");
} else { } else {
long stamp = Math.round(Math.random() * 100000); long stamp = Math.round(Math.random() * 100000);
Version version = new Version("2.16a+"); Version tv1 = new Version("2.16a+");
Version tv2 = new Version("2.18a+");
if (new File(dir, "Templates/Vanilla/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Vanilla/template.yml"))).get().getVersion("Version", version)).compareTo(version) != 0) { if (new File(dir, "Templates/Vanilla/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Vanilla/template.yml"))).get().getVersion("Version", tv2)).compareTo(tv2) != 0) {
Files.move(new File(dir, "Templates/Vanilla").toPath(), new File(dir, "Templates/Vanilla." + stamp + ".x").toPath()); Files.move(new File(dir, "Templates/Vanilla").toPath(), new File(dir, "Templates/Vanilla." + stamp + ".x").toPath());
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/vanilla.zip"), new File(dir, "Templates")); Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/vanilla.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Updated ./SubServers/Templates/Vanilla"); Logger.get("SubServers").info("Updated ./SubServers/Templates/Vanilla");
} }
if (new File(dir, "Templates/Spigot/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Spigot/template.yml"))).get().getVersion("Version", version)).compareTo(version) != 0) { if (new File(dir, "Templates/Spigot/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Spigot/template.yml"))).get().getVersion("Version", tv1)).compareTo(tv1) != 0) {
Files.move(new File(dir, "Templates/Spigot").toPath(), new File(dir, "Templates/Spigot." + stamp + ".x").toPath()); Files.move(new File(dir, "Templates/Spigot").toPath(), new File(dir, "Templates/Spigot." + stamp + ".x").toPath());
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/spigot.zip"), new File(dir, "Templates")); Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/spigot.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Updated ./SubServers/Templates/Spigot"); Logger.get("SubServers").info("Updated ./SubServers/Templates/Spigot");
} }
if (new File(dir, "Templates/Paper/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Paper/template.yml"))).get().getVersion("Version", version)).compareTo(version) != 0) { if (new File(dir, "Templates/Purpur/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Purpur/template.yml"))).get().getVersion("Version", tv2)).compareTo(tv2) != 0) {
Files.move(new File(dir, "Templates/Paper").toPath(), new File(dir, "Templates/Paper." + stamp + ".x").toPath());
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/paper.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Updated ./SubServers/Templates/Paper");
}
if (new File(dir, "Templates/Purpur/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Purpur/template.yml"))).get().getVersion("Version", version)).compareTo(version) != 0) {
Files.move(new File(dir, "Templates/Purpur").toPath(), new File(dir, "Templates/Purpur." + stamp + ".x").toPath()); Files.move(new File(dir, "Templates/Purpur").toPath(), new File(dir, "Templates/Purpur." + stamp + ".x").toPath());
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/purpur.zip"), new File(dir, "Templates")); Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/purpur.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Updated ./SubServers/Templates/Purpur"); Logger.get("SubServers").info("Updated ./SubServers/Templates/Purpur");
} }
if (new File(dir, "Templates/Forge/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Forge/template.yml"))).get().getVersion("Version", version)).compareTo(version) != 0) { if (new File(dir, "Templates/Forge/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Forge/template.yml"))).get().getVersion("Version", tv2)).compareTo(tv2) != 0) {
Files.move(new File(dir, "Templates/Forge").toPath(), new File(dir, "Templates/Forge." + stamp + ".x").toPath()); Files.move(new File(dir, "Templates/Forge").toPath(), new File(dir, "Templates/Forge." + stamp + ".x").toPath());
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/forge.zip"), new File(dir, "Templates")); Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/forge.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Updated ./SubServers/Templates/Forge"); Logger.get("SubServers").info("Updated ./SubServers/Templates/Forge");
} }
if (new File(dir, "Templates/Sponge/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Sponge/template.yml"))).get().getVersion("Version", version)).compareTo(version) != 0) { if (new File(dir, "Templates/Sponge/template.yml").exists() && ((new YAMLConfig(new File(dir, "Templates/Sponge/template.yml"))).get().getVersion("Version", tv1)).compareTo(tv1) != 0) {
Files.move(new File(dir, "Templates/Sponge").toPath(), new File(dir, "Templates/Sponge." + stamp + ".x").toPath()); Files.move(new File(dir, "Templates/Sponge").toPath(), new File(dir, "Templates/Sponge." + stamp + ".x").toPath());
Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/sponge.zip"), new File(dir, "Templates")); Directories.unzip(SubProxy.class.getResourceAsStream("/net/ME1312/SubServers/Bungee/Library/Files/Templates/sponge.zip"), new File(dir, "Templates"));
Logger.get("SubServers").info("Updated ./SubServers/Templates/Sponge"); Logger.get("SubServers").info("Updated ./SubServers/Templates/Sponge");

View File

@ -1,6 +1,6 @@
name: SubServers-Client-Bukkit name: SubServers-Client-Bukkit
main: net.ME1312.SubServers.Client.Bukkit.SubPlugin main: net.ME1312.SubServers.Client.Bukkit.SubPlugin
version: "2.17.1a" version: "2.18a"
authors: ["ME1312"] authors: ["ME1312"]
softdepend: [TitleAPI, PlaceholderAPI] softdepend: [TitleAPI, PlaceholderAPI]
website: "https://github.com/ME1312/SubServers-2" website: "https://github.com/ME1312/SubServers-2"

View File

@ -18,7 +18,7 @@
<dependency> <dependency>
<groupId>net.ME1312.Galaxi</groupId> <groupId>net.ME1312.Galaxi</groupId>
<artifactId>GalaxiUtil</artifactId> <artifactId>GalaxiUtil</artifactId>
<version>21w44c</version> <version>21w47d</version>
<scope>compile</scope> <scope>compile</scope>
</dependency> </dependency>
<dependency> <dependency>

View File

@ -47,7 +47,7 @@ import static net.ME1312.SubServers.Client.Sponge.Library.AccessMode.NO_COMMANDS
/** /**
* SubServers Client Plugin Class * SubServers Client Plugin Class
*/ */
@Plugin(id = "subservers-client-sponge", name = "SubServers-Client-Sponge", authors = "ME1312", version = "2.17.1a", url = "https://github.com/ME1312/SubServers-2", description = "Take control of the server manager — from your servers") @Plugin(id = "subservers-client-sponge", name = "SubServers-Client-Sponge", authors = "ME1312", version = "2.18a", url = "https://github.com/ME1312/SubServers-2", description = "Take control of the server manager — from your servers")
public final class SubPlugin { public final class SubPlugin {
HashMap<Integer, SubDataClient> subdata = new HashMap<Integer, SubDataClient>(); HashMap<Integer, SubDataClient> subdata = new HashMap<Integer, SubDataClient>();
Pair<Long, Map<String, Map<String, String>>> lang = null; Pair<Long, Map<String, Map<String, String>>> lang = null;

View File

@ -1,4 +1,4 @@
name: SubServers-Console name: SubServers-Console
main: net.ME1312.SubServers.Console.ConsolePlugin main: net.ME1312.SubServers.Console.ConsolePlugin
version: 2.17.1a version: 2.18a
author: ME1312 author: ME1312

View File

@ -1,4 +1,4 @@
Version: '2.16a+' Version: '2.18a+'
Template: Template:
Enabled: true Enabled: true
Icon: 'anvil' Icon: 'anvil'

View File

@ -1,52 +0,0 @@
# SubCreator Paper Build Script
#
#!/usr/bin/env bash
if [[ -z "$version" ]]
then
echo ERROR: No Build Version Supplied
rm -Rf "$0"
exit 1
fi
function __DL() {
if [[ -x "$(command -v wget)" ]]; then
wget -O "$1" "$2"; return $?
else
curl -Lo "$1" "$2"; return $?
fi
}
function __Restore() {
if [[ -f "Paper.old.jar.x" ]]; then
if [[ -f "Paper.jar" ]]; then
rm -Rf Paper.jar
fi
mv Paper.old.jar.x Paper.jar
fi
}
echo Downloading Paper...
if [[ -f "Paper.jar" ]]; then
if [[ -f "Paper.old.jar.x" ]]; then
rm -Rf Paper.old.jar.x
fi
mv Paper.jar Paper.old.jar.x
fi
__DL Paper.jar "https://papermc.io/api/v1/paper/$version/latest/download"; __RETURN=$?
if [[ $__RETURN -eq 0 ]]; then
if [[ $(stat -c%s "Paper.jar") -ge 1000000 ]]; then
echo Cleaning Up...
rm -Rf "$0"
exit 0
else
echo ERROR: Received invalid jarfile when requesting Paper version $version:
cat Paper.jar
printf "\n"
__Restore
rm -Rf "$0"
exit 4
fi
else
echo ERROR: Failed downloading Paper. Is PaperMC.io down?
__Restore
rm -Rf "$0"
exit 3
fi
exit 2

View File

@ -1,2 +0,0 @@
#By using SubCreator to create your server you have indicated your agreement to the Minecraft EULA (https://account.mojang.com/documents/minecraft_eula).
eula=true

View File

@ -1,10 +0,0 @@
#Minecraft server properties
server-ip=SubServers::address
server-port=SubServers::port
online-mode=false
enable-query=false
broadcast-console-to-ops=false
announce-player-achievements=false
network-compression-threshold=-1
enable-command-block=true
motd=Some SubServer

View File

@ -1,3 +0,0 @@
config-version: 4
settings:
bungeecord: true

View File

@ -1,12 +0,0 @@
Version: '2.16a+'
Template:
Enabled: true
Icon: 'paper'
Build:
Server-Type: 'Spigot'
Use-Cache: false
Require-Version: true
Can-Update: true
Executable: 'bash build.sh'
Settings:
Executable: 'java -Xmx1024M -Dterminal.jline=false -jar Paper.jar nogui'

View File

@ -1,4 +1,4 @@
Version: '2.16a+' Version: '2.18a+'
Template: Template:
Enabled: true Enabled: true
Icon: 'purpur_block' Icon: 'purpur_block'

View File

@ -24,7 +24,7 @@ if [[ -z "$cache" ]] || [[ ! -f "$cache/Vanilla-$version.jar" ]]; then
fi fi
mkdir VanillaCord mkdir VanillaCord
echo Downloading the VanillaCord Launcher... echo Downloading the VanillaCord Launcher...
__DL VanillaCord/VanillaCord.jar https://dev.me1312.net/jenkins/job/VanillaCord/job/master/lastSuccessfulBuild/artifact/artifacts/VanillaCord.jar; __RETURN=$? __DL VanillaCord/VanillaCord.jar https://dev.me1312.net/jenkins/job/VanillaCord/lastSuccessfulBuild/artifact/artifacts/VanillaCord.jar; __RETURN=$?
if [[ $__RETURN -eq 0 ]]; then if [[ $__RETURN -eq 0 ]]; then
cd VanillaCord cd VanillaCord
echo Launching VanillaCord echo Launching VanillaCord

View File

@ -1,4 +1,4 @@
Version: '2.16a+' Version: '2.18a+'
Template: Template:
Enabled: true Enabled: true
Icon: 'bukkit:grass' Icon: 'bukkit:grass'

View File

@ -30,13 +30,13 @@
<dependency> <dependency>
<groupId>net.ME1312.Galaxi</groupId> <groupId>net.ME1312.Galaxi</groupId>
<artifactId>GalaxiEngine</artifactId> <artifactId>GalaxiEngine</artifactId>
<version>21w44c</version> <version>21w47d</version>
<scope>compile</scope> <scope>compile</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>net.ME1312.Galaxi</groupId> <groupId>net.ME1312.Galaxi</groupId>
<artifactId>GalaxiUI</artifactId> <artifactId>GalaxiUI</artifactId>
<version>21w44c</version> <version>21w47d</version>
<scope>runtime</scope> <scope>runtime</scope>
</dependency> </dependency>
<dependency> <dependency>

View File

@ -42,7 +42,7 @@ import java.util.jar.Manifest;
/** /**
* SubServers.Host Main Class * SubServers.Host Main Class
*/ */
@App(name = "SubServers.Host", version = "2.17.1a", authors = "ME1312", website = "https://github.com/ME1312/SubServers-2", description = "Host subservers on separate machines") @App(name = "SubServers.Host", version = "2.18a", authors = "ME1312", website = "https://github.com/ME1312/SubServers-2", description = "Host subservers on separate machines")
public final class ExHost { public final class ExHost {
HashMap<Integer, SubDataClient> subdata = new HashMap<Integer, SubDataClient>(); HashMap<Integer, SubDataClient> subdata = new HashMap<Integer, SubDataClient>();
Pair<Long, Map<String, Map<String, String>>> lang = null; Pair<Long, Map<String, Map<String, String>>> lang = null;

View File

@ -1008,12 +1008,10 @@ public class SubCommand {
i++; i++;
} }
LinkedList<Server> history = new LinkedList<Server>();
LinkedList<Server> servers = new LinkedList<Server>(); LinkedList<Server> servers = new LinkedList<Server>();
LinkedList<SubServer> subservers = new LinkedList<SubServer>(); LinkedList<SubServer> subservers = new LinkedList<SubServer>();
for (Server server : select) { for (Server server : select) {
if (!history.contains(server)) { if (!servers.contains(server)) {
history.add(server);
servers.add(server); servers.add(server);
if (server instanceof SubServer) if (server instanceof SubServer)
subservers.add((SubServer) server); subservers.add((SubServer) server);

View File

@ -74,7 +74,7 @@ public final class ExProxy extends BungeeCommon implements Listener {
public final Plugin plugin; public final Plugin plugin;
public final SubAPI api = new SubAPI(this); public final SubAPI api = new SubAPI(this);
public SubProtocol subprotocol; public SubProtocol subprotocol;
public static final Version version = Version.fromString("2.17.1a"); public static final Version version = Version.fromString("2.18a");
public final boolean isPatched; public final boolean isPatched;
public long lastReload = -1; public long lastReload = -1;

View File

@ -761,12 +761,10 @@ public final class SubCommand extends Command implements TabExecutor {
i++; i++;
} }
LinkedList<Server> history = new LinkedList<Server>();
LinkedList<Server> servers = new LinkedList<Server>(); LinkedList<Server> servers = new LinkedList<Server>();
LinkedList<SubServer> subservers = new LinkedList<SubServer>(); LinkedList<SubServer> subservers = new LinkedList<SubServer>();
for (Server server : select) { for (Server server : select) {
if (!history.contains(server)) { if (!servers.contains(server)) {
history.add(server);
servers.add(server); servers.add(server);
if (server instanceof SubServer) if (server instanceof SubServer)
subservers.add((SubServer) server); subservers.add((SubServer) server);

View File

@ -64,7 +64,7 @@ import java.nio.charset.Charset;
import java.util.*; import java.util.*;
import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeUnit;
@Plugin(id = "subservers-sync", name = "SubServers-Sync", authors = "ME1312", version = "2.17.1a/pr1", url = "https://github.com/ME1312/SubServers-2", description = "Dynamically sync player and server connection info over multiple proxy instances") @Plugin(id = "subservers-sync", name = "SubServers-Sync", authors = "ME1312", version = "2.18a", url = "https://github.com/ME1312/SubServers-2", description = "Dynamically sync player and server connection info over multiple proxy instances")
public class ExProxy { public class ExProxy {
HashMap<Integer, SubDataClient> subdata = new HashMap<Integer, SubDataClient>(); HashMap<Integer, SubDataClient> subdata = new HashMap<Integer, SubDataClient>();

View File

@ -766,12 +766,10 @@ public final class SubCommand implements SimpleCommand {
i++; i++;
} }
LinkedList<Server> history = new LinkedList<Server>();
LinkedList<Server> servers = new LinkedList<Server>(); LinkedList<Server> servers = new LinkedList<Server>();
LinkedList<SubServer> subservers = new LinkedList<SubServer>(); LinkedList<SubServer> subservers = new LinkedList<SubServer>();
for (Server server : select) { for (Server server : select) {
if (!history.contains(server)) { if (!servers.contains(server)) {
history.add(server);
servers.add(server); servers.add(server);
if (server instanceof SubServer) if (server instanceof SubServer)
subservers.add((SubServer) server); subservers.add((SubServer) server);