mirror of
https://github.com/ayunami2000/ayunViaProxyEagUtils.git
synced 2024-12-22 06:44:11 -08:00
Way for anyone to connect to Eaglercraft servers
This commit is contained in:
parent
af12ad126a
commit
350296d2bb
|
@ -12,6 +12,7 @@ public class FunnyConfig extends Config {
|
|||
public static boolean premiumSkins = false;
|
||||
public static boolean eaglerSkins = true;
|
||||
public static boolean eaglerVoice = true;
|
||||
public static int eaglerServerMode = 0;
|
||||
|
||||
protected FunnyConfig(File configFile) {
|
||||
super(configFile);
|
||||
|
@ -36,6 +37,10 @@ public class FunnyConfig extends Config {
|
|||
if (item instanceof Boolean) {
|
||||
eaglerVoice = (Boolean) item;
|
||||
}
|
||||
item = map.get("eagler-server-mode");
|
||||
if (item instanceof Integer) {
|
||||
eaglerServerMode = (Integer) item;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -90,6 +90,12 @@ public class Main extends ViaProxyPlugin {
|
|||
addr = ((ProxyConnection) proxyConnection).getServerAddress();
|
||||
}
|
||||
|
||||
if (FunnyConfig.eaglerServerMode == 1) {
|
||||
c2p.attr(secureWs).set(false);
|
||||
} else if (FunnyConfig.eaglerServerMode == 2) {
|
||||
c2p.attr(secureWs).set(true);
|
||||
}
|
||||
|
||||
if (c2p.hasAttr(secureWs)) {
|
||||
doWsServerStuff(ch, proxyConnection, c2p, addr);
|
||||
if (!event.isLegacyPassthrough()) {
|
||||
|
|
|
@ -3,4 +3,9 @@ premium-skins: false
|
|||
# Sync Eagler skins
|
||||
eagler-skins: true
|
||||
# Enable Eagler voice chat
|
||||
eagler-voice: true
|
||||
eagler-voice: true
|
||||
# Eaglercraft server mode
|
||||
# 0 - Default (non-Eaglercraft)
|
||||
# 1 - Force non-secure (ws)
|
||||
# 2 - Force secure (wss)
|
||||
eagler-server-mode: 0
|
Loading…
Reference in New Issue
Block a user