64 lines
4.2 KiB
Diff
64 lines
4.2 KiB
Diff
|
From 40ee61cc9b114b89dfabfc3f0f070edf18c2bd03 Mon Sep 17 00:00:00 2001
|
||
|
From: LinsaFTW <25271111+linsaftw@users.noreply.github.com>
|
||
|
Date: Tue, 8 Jun 2021 22:24:27 -0300
|
||
|
Subject: [PATCH] FlameCord rebrand
|
||
|
|
||
|
|
||
|
diff --git a/proxy/src/main/java/io/github/waterfallmc/waterfall/conf/WaterfallConfiguration.java b/proxy/src/main/java/io/github/waterfallmc/waterfall/conf/WaterfallConfiguration.java
|
||
|
index e31fb00ae..ff4bbf34d 100644
|
||
|
--- a/proxy/src/main/java/io/github/waterfallmc/waterfall/conf/WaterfallConfiguration.java
|
||
|
+++ b/proxy/src/main/java/io/github/waterfallmc/waterfall/conf/WaterfallConfiguration.java
|
||
|
@@ -68,7 +68,8 @@ public class WaterfallConfiguration extends Configuration {
|
||
|
YamlConfig config = new YamlConfig(new File("waterfall.yml"));
|
||
|
config.load(false); // Load, but no permissions
|
||
|
logInitialHandlerConnections = config.getBoolean( "log_initial_handler_connections", logInitialHandlerConnections );
|
||
|
- gameVersion = config.getString("game_version", "").isEmpty() ? Joiner.on(", ").join(ProtocolConstants.SUPPORTED_VERSIONS) : config.getString("game_version", "");
|
||
|
+ // FlameCord - Make the version look better
|
||
|
+ gameVersion = config.getString("game_version", "").isEmpty() ? ProtocolConstants.SUPPORTED_VERSIONS.get(0) + "-" + ProtocolConstants.SUPPORTED_VERSIONS.get(ProtocolConstants.SUPPORTED_VERSIONS.size() - 1) : config.getString("game_version", "");
|
||
|
useNettyDnsResolver = config.getBoolean("use_netty_dns_resolver", useNettyDnsResolver);
|
||
|
// Throttling options
|
||
|
tabThrottle = config.getInt("throttling.tab_complete", tabThrottle);
|
||
|
diff --git a/proxy/src/main/java/net/md_5/bungee/BungeeCord.java b/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
|
||
|
index a4b58d9c6..40ceeb18d 100644
|
||
|
--- a/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
|
||
|
+++ b/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
|
||
|
@@ -545,7 +545,7 @@ public class BungeeCord extends ProxyServer
|
||
|
@Override
|
||
|
public String getVersion()
|
||
|
{
|
||
|
- return ( BungeeCord.class.getPackage().getImplementationVersion() == null ) ? "unknown" : BungeeCord.class.getPackage().getImplementationVersion();
|
||
|
+ return "0.8.5";
|
||
|
}
|
||
|
|
||
|
public void reloadMessages()
|
||
|
diff --git a/proxy/src/main/java/net/md_5/bungee/command/CommandBungee.java b/proxy/src/main/java/net/md_5/bungee/command/CommandBungee.java
|
||
|
index 820f7b03c..aeda79639 100644
|
||
|
--- a/proxy/src/main/java/net/md_5/bungee/command/CommandBungee.java
|
||
|
+++ b/proxy/src/main/java/net/md_5/bungee/command/CommandBungee.java
|
||
|
@@ -16,6 +16,7 @@ public class CommandBungee extends Command
|
||
|
@Override
|
||
|
public void execute(CommandSender sender, String[] args)
|
||
|
{
|
||
|
- sender.sendMessage( ChatColor.BLUE + "This server is running FlameCord version " + ProxyServer.getInstance().getVersion() + " by md_5" );
|
||
|
+ // FlameCord - Use custom version message
|
||
|
+ sender.sendMessage( ChatColor.translateAlternateColorCodes( '&', "&eThis server is running &c" + ProxyServer.getInstance().getName() + "&e version &a" + ProxyServer.getInstance().getVersion() + "&e by &bLinsaFTW & Sammwy&e." ) );
|
||
|
}
|
||
|
}
|
||
|
diff --git a/query/src/main/java/net/md_5/bungee/query/QueryHandler.java b/query/src/main/java/net/md_5/bungee/query/QueryHandler.java
|
||
|
index 0c1ecfb8e..b2b199969 100644
|
||
|
--- a/query/src/main/java/net/md_5/bungee/query/QueryHandler.java
|
||
|
+++ b/query/src/main/java/net/md_5/bungee/query/QueryHandler.java
|
||
|
@@ -103,7 +103,8 @@ public class QueryHandler extends SimpleChannelInboundHandler<DatagramPacket>
|
||
|
// Waterfall start
|
||
|
List<String> players = bungee.getPlayers().stream().map(ProxiedPlayer::getName).collect(Collectors.toList());
|
||
|
|
||
|
- ProxyQueryEvent event = new ProxyQueryEvent(listener, new QueryResult(listener.getMotd(), "SMP", "Waterfall_Proxy",
|
||
|
+ // FlameCord - Rebrand
|
||
|
+ ProxyQueryEvent event = new ProxyQueryEvent(listener, new QueryResult(listener.getMotd(), "SMP", "FlameCord_Proxy",
|
||
|
bungee.getOnlineCount(), listener.getMaxPlayers(), listener.getHost().getPort(),
|
||
|
listener.getHost().getHostString(), "MINECRAFT", players, bungee.getGameVersion()));
|
||
|
QueryResult result = bungee.getPluginManager().callEvent(event).getResult();
|
||
|
--
|
||
|
2.32.0
|
||
|
|