Simplify/Improve Module/Messages configuration system

This commit is contained in:
LinsaFTW 2023-02-21 11:23:56 -03:00
parent 3da7f18f2b
commit b11d198ca4
6 changed files with 149 additions and 183 deletions

View File

@ -1,4 +1,4 @@
From 3f5bcf44e1f1e2d0ea733170d0b22b91dab2111a Mon Sep 17 00:00:00 2001
From 681805834a7f83cccb8de7878b8ffacbdb4b6d0d Mon Sep 17 00:00:00 2001
From: linsaftw <25271111+linsaftw@users.noreply.github.com>
Date: Sat, 1 May 2021 14:17:48 -0300
Subject: [PATCH] FlameCord module system
@ -36,14 +36,13 @@ index f3d5c0290..fb3d8ca2e 100644
\ No newline at end of file
diff --git a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/ModulesConfiguration.java b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/ModulesConfiguration.java
new file mode 100644
index 000000000..6c5bb9617
index 000000000..a6cb2638f
--- /dev/null
+++ b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/ModulesConfiguration.java
@@ -0,0 +1,49 @@
@@ -0,0 +1,35 @@
+package dev._2lstudios.flamecord.configuration;
+
+import java.io.File;
+import java.io.IOException;
+
+import net.md_5.bungee.config.Configuration;
+import net.md_5.bungee.config.ConfigurationProvider;
@ -60,37 +59,24 @@ index 000000000..6c5bb9617
+ public boolean serverEnabled = true;
+
+ public ModulesConfiguration(final ConfigurationProvider configurationProvider) {
+ try {
+ final String fileName = "./modules.yml";
+ final File configurationFile = new File(fileName);
+ final Configuration configuration;
+ final boolean configurationExists = configurationFile.exists();
+ final File configurationFile = new File("./modules.yml");
+ final Configuration configuration = load(configurationFile);
+
+ if (!configurationExists) {
+ configuration = new Configuration();
+ } else {
+ configuration = configurationProvider.load(configurationFile);
+ }
+ this.alertEnabled = setIfUnexistant("alert.enabled", this.alertEnabled, configuration);
+ this.findEnabled = setIfUnexistant("find.enabled", this.findEnabled, configuration);
+ this.ipEnabled = setIfUnexistant("ip.enabled", this.ipEnabled, configuration);
+ this.listEnabled = setIfUnexistant("list.enabled", this.listEnabled, configuration);
+ this.permsEnabled = setIfUnexistant("perms.enabled", this.permsEnabled, configuration);
+ this.reloadEnabled = setIfUnexistant("reload.enabled", this.reloadEnabled, configuration);
+ this.sendEnabled = setIfUnexistant("send.enabled", this.sendEnabled, configuration);
+ this.serverEnabled = setIfUnexistant("server.enabled", this.serverEnabled, configuration);
+ this.reconnectEnabled = setIfUnexistant("reconnect.enabled", this.reconnectEnabled, configuration);
+
+ this.alertEnabled = setIfUnexistant("alert.enabled", this.alertEnabled, configuration);
+ this.findEnabled = setIfUnexistant("find.enabled", this.findEnabled, configuration);
+ this.ipEnabled = setIfUnexistant("ip.enabled", this.ipEnabled, configuration);
+ this.listEnabled = setIfUnexistant("list.enabled", this.listEnabled, configuration);
+ this.permsEnabled = setIfUnexistant("perms.enabled", this.permsEnabled, configuration);
+ this.reloadEnabled = setIfUnexistant("reload.enabled", this.reloadEnabled, configuration);
+ this.sendEnabled = setIfUnexistant("send.enabled", this.sendEnabled, configuration);
+ this.serverEnabled = setIfUnexistant("server.enabled", this.serverEnabled, configuration);
+ this.reconnectEnabled = setIfUnexistant("reconnect.enabled", this.reconnectEnabled,
+ configuration);
+
+ configurationProvider.save(configuration, configurationFile);
+ } catch (final IOException e) {
+ e.printStackTrace();
+ }
+ save(configuration, configurationFile);
+ }
+}
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 39986d522..0eb9ae146 100644
index 0d8f02d25..d58227fd9 100644
--- a/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
+++ b/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
@@ -11,6 +11,8 @@ import com.google.gson.Gson;

View File

@ -1,4 +1,4 @@
From fbf8efb44cceaa714da0ca83a04695ad4ba1c4e3 Mon Sep 17 00:00:00 2001
From 168e63822c7f19251ff48a96fb341b230d662143 Mon Sep 17 00:00:00 2001
From: linsaftw <25271111+linsaftw@users.noreply.github.com>
Date: Sat, 1 May 2021 13:40:39 -0300
Subject: [PATCH] FlameCord message configuration
@ -35,14 +35,13 @@ index fb3d8ca2e..676ba95b9 100644
\ No newline at end of file
diff --git a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
new file mode 100644
index 000000000..21381bb45
index 000000000..ae1794385
--- /dev/null
+++ b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
@@ -0,0 +1,115 @@
@@ -0,0 +1,102 @@
+package dev._2lstudios.flamecord.configuration;
+
+import java.io.File;
+import java.io.IOException;
+import java.text.MessageFormat;
+import java.util.HashMap;
+import java.util.Map;
@ -59,90 +58,78 @@ index 000000000..21381bb45
+ public MessagesConfiguration(final Logger logger, final ConfigurationProvider configurationProvider) {
+ this.logger = logger;
+
+ try {
+ final String fileName = "./messages.yml";
+ final File configurationFile = new File(fileName);
+ final Configuration configuration;
+ final boolean configurationExists = configurationFile.exists();
+ final File configurationFile = new File("./messages.yml");
+ final Configuration configuration = load(configurationFile);
+
+ if (!configurationExists) {
+ configuration = new Configuration();
+ } else {
+ configuration = configurationProvider.load(configurationFile);
+ // FlameCord
+ setIfUnexistant("flamecord_reload", "&aAll files had been successfully reloaded!", configuration);
+ setIfUnexistant("flamecord_help",
+ "&aFlameCord&b {0}&a by&b LinsaFTW\n&e /flamecord reload&7 >&b Reloads FlameCord files!\n&e /flamecord firewall <add/remove> <ip>&7 >&b Firewall certain ips!\n&e /bplugins&7 >&b Show the plugin list!\n&e /bip <player>&7 >&b Show the ip and info of a player!\n&e /flamecord help&7 >&b Shows this message!",
+ configuration);
+ setIfUnexistant("flamecord_nopermission", "&cYou don't have permission to do this!", configuration);
+
+ // BungeeCord
+ setIfUnexistant("alert", "&8[&4Alert&8]&r ", configuration);
+ setIfUnexistant("already_connected", "&cYou are already connected to this server!", configuration);
+ setIfUnexistant("already_connected_proxy", "&cYou are already connected to this proxy!", configuration);
+ setIfUnexistant("already_connecting", "&cAlready connecting to this server!", configuration);
+ setIfUnexistant("command_list", "&a[{0}] &e({1}): &r{2}", configuration);
+ setIfUnexistant("connect_kick", "&cKicked whilst connecting to {0}: {1}", configuration);
+ setIfUnexistant("current_server", "&6You are currently connected to {0}.", configuration);
+ setIfUnexistant("fallback_kick",
+ "&cCould not connect to a default or fallback server, please try again later: {0}", configuration);
+ setIfUnexistant("fallback_lobby",
+ "&cCould not connect to target server, you have been moved to a fallback server.", configuration);
+ setIfUnexistant("lost_connection", "[Proxy] Lost connection to server.", configuration);
+ setIfUnexistant("mojang_fail", "Error occurred while contacting login servers, are they down?",
+ configuration);
+ setIfUnexistant("no_permission", "&cYou do not have permission to execute this command!", configuration);
+ setIfUnexistant("no_server", "&cThe specified server does not exist.", configuration);
+ setIfUnexistant("no_server_permission", "&cYou don't have permission to access this server.",
+ configuration);
+ setIfUnexistant("outdated_client", "Outdated client! Please use {0}", configuration);
+ setIfUnexistant("outdated_server", "Outdated server! I'm still on {0}", configuration);
+ setIfUnexistant("proxy_full", "Server is full!", configuration);
+ setIfUnexistant("restart", "[Proxy] Proxy restarting.", configuration);
+ setIfUnexistant("server_list", "&6You may connect to the following servers at this time: ", configuration);
+ setIfUnexistant("server_went_down",
+ "&cThe server you were previously on went down, you have been connected to a fallback server",
+ configuration);
+ setIfUnexistant("total_players", "Total players online: {0}", configuration);
+ setIfUnexistant("name_invalid", "Username contains invalid characters.", configuration);
+ setIfUnexistant("ping_cannot_connect", "&c[Bungee] Can't connect to server.", configuration);
+ setIfUnexistant("offline_mode_player", "Not authenticated with Minecraft.net", configuration);
+ setIfUnexistant("secure_profile_required", "A secure profile is required to join this server.", configuration);
+ setIfUnexistant("secure_profile_expired", "Secure profile expired.", configuration);
+ setIfUnexistant("secure_profile_invalid", "Secure profile invalid.", configuration);
+ setIfUnexistant("message_needed", "&cYou must supply a message.", configuration);
+ setIfUnexistant("error_occurred_player",
+ "&cAn error occurred while parsing your message. (Hover for details)", configuration);
+ setIfUnexistant("error_occurred_console", "&cAn error occurred while parsing your message: {0}",
+ configuration);
+ setIfUnexistant("server_command_hover_players", "{0} players", configuration);
+ setIfUnexistant("click_to_connect", "Click to connect to the server", configuration);
+ setIfUnexistant("username_needed", "&cPlease follow this command by a user name.", configuration);
+ setIfUnexistant("user_not_online", "&cThat user is not online.", configuration);
+ setIfUnexistant("user_online_at", "&a{0} &ris online at {1}", configuration);
+ setIfUnexistant("send_cmd_usage",
+ "&cNot enough arguments, usage: /send <server|player|all|current> <target>", configuration);
+ setIfUnexistant("player_only", "&cOnly in game players can use this command", configuration);
+ setIfUnexistant("you_got_summoned", "&6Summoned to {0} by {1}", configuration);
+ setIfUnexistant("command_perms_groups", "&6You have the following groups: {0}", configuration);
+ setIfUnexistant("command_perms_permission", "&9- {0}", configuration);
+ setIfUnexistant("command_ip", "&9IP of {0} is {1}", configuration);
+ setIfUnexistant("illegal_chat_characters", "&cIllegal characters in chat ({0})", configuration);
+
+ for (final String key : configuration.getKeys()) {
+ final Object value = configuration.get(key);
+
+ if (value instanceof String) {
+ this.messages.put(key, ChatColor.translateAlternateColorCodes('&', (String) value));
+ }
+
+ // FlameCord
+ setIfUnexistant("flamecord_reload", "&aAll files had been successfully reloaded!", configuration);
+ setIfUnexistant("flamecord_help",
+ "&aFlameCord&b {0}&a by&b LinsaFTW\n&e /flamecord reload&7 >&b Reloads FlameCord files!\n&e /flamecord firewall <add/remove> <ip>&7 >&b Firewall certain ips!\n&e /bplugins&7 >&b Show the plugin list!\n&e /bip <player>&7 >&b Show the ip and info of a player!\n&e /flamecord help&7 >&b Shows this message!",
+ configuration);
+ setIfUnexistant("flamecord_nopermission", "&cYou don't have permission to do this!", configuration);
+
+ // BungeeCord
+ setIfUnexistant("alert", "&8[&4Alert&8]&r ", configuration);
+ setIfUnexistant("already_connected", "&cYou are already connected to this server!", configuration);
+ setIfUnexistant("already_connected_proxy", "&cYou are already connected to this proxy!", configuration);
+ setIfUnexistant("already_connecting", "&cAlready connecting to this server!", configuration);
+ setIfUnexistant("command_list", "&a[{0}] &e({1}): &r{2}", configuration);
+ setIfUnexistant("connect_kick", "&cKicked whilst connecting to {0}: {1}", configuration);
+ setIfUnexistant("current_server", "&6You are currently connected to {0}.", configuration);
+ setIfUnexistant("fallback_kick",
+ "&cCould not connect to a default or fallback server, please try again later: {0}", configuration);
+ setIfUnexistant("fallback_lobby",
+ "&cCould not connect to target server, you have been moved to a fallback server.", configuration);
+ setIfUnexistant("lost_connection", "[Proxy] Lost connection to server.", configuration);
+ setIfUnexistant("mojang_fail", "Error occurred while contacting login servers, are they down?",
+ configuration);
+ setIfUnexistant("no_permission", "&cYou do not have permission to execute this command!", configuration);
+ setIfUnexistant("no_server", "&cThe specified server does not exist.", configuration);
+ setIfUnexistant("no_server_permission", "&cYou don't have permission to access this server.",
+ configuration);
+ setIfUnexistant("outdated_client", "Outdated client! Please use {0}", configuration);
+ setIfUnexistant("outdated_server", "Outdated server! I'm still on {0}", configuration);
+ setIfUnexistant("proxy_full", "Server is full!", configuration);
+ setIfUnexistant("restart", "[Proxy] Proxy restarting.", configuration);
+ setIfUnexistant("server_list", "&6You may connect to the following servers at this time: ", configuration);
+ setIfUnexistant("server_went_down",
+ "&cThe server you were previously on went down, you have been connected to a fallback server",
+ configuration);
+ setIfUnexistant("total_players", "Total players online: {0}", configuration);
+ setIfUnexistant("name_invalid", "Username contains invalid characters.", configuration);
+ setIfUnexistant("ping_cannot_connect", "&c[Bungee] Can't connect to server.", configuration);
+ setIfUnexistant("offline_mode_player", "Not authenticated with Minecraft.net", configuration);
+ setIfUnexistant("secure_profile_required", "A secure profile is required to join this server.", configuration);
+ setIfUnexistant("secure_profile_expired", "Secure profile expired.", configuration);
+ setIfUnexistant("secure_profile_invalid", "Secure profile invalid.", configuration);
+ setIfUnexistant("message_needed", "&cYou must supply a message.", configuration);
+ setIfUnexistant("error_occurred_player",
+ "&cAn error occurred while parsing your message. (Hover for details)", configuration);
+ setIfUnexistant("error_occurred_console", "&cAn error occurred while parsing your message: {0}",
+ configuration);
+ setIfUnexistant("server_command_hover_players", "{0} players", configuration);
+ setIfUnexistant("click_to_connect", "Click to connect to the server", configuration);
+ setIfUnexistant("username_needed", "&cPlease follow this command by a user name.", configuration);
+ setIfUnexistant("user_not_online", "&cThat user is not online.", configuration);
+ setIfUnexistant("user_online_at", "&a{0} &ris online at {1}", configuration);
+ setIfUnexistant("send_cmd_usage",
+ "&cNot enough arguments, usage: /send <server|player|all|current> <target>", configuration);
+ setIfUnexistant("player_only", "&cOnly in game players can use this command", configuration);
+ setIfUnexistant("you_got_summoned", "&6Summoned to {0} by {1}", configuration);
+ setIfUnexistant("command_perms_groups", "&6You have the following groups: {0}", configuration);
+ setIfUnexistant("command_perms_permission", "&9- {0}", configuration);
+ setIfUnexistant("command_ip", "&9IP of {0} is {1}", configuration);
+ setIfUnexistant("illegal_chat_characters", "&cIllegal characters in chat ({0})", configuration);
+
+ configurationProvider.save(configuration, configurationFile);
+
+ for (final String key : configuration.getKeys()) {
+ final Object value = configuration.get(key);
+
+ if (value instanceof String) {
+ this.messages.put(key, ChatColor.translateAlternateColorCodes('&', (String) value));
+ }
+ }
+ } catch (final IOException e) {
+ e.printStackTrace();
+ }
+
+ save(configuration, configurationFile);
+ }
+
+ public String getTranslation(final String name, final Object... args) {
@ -218,7 +205,7 @@ index 021b38d43..fb81adee0 100644
}
}
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 0eb9ae146..857b0b622 100644
index d58227fd9..8994454c7 100644
--- a/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
+++ b/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
@@ -620,8 +620,8 @@ public class BungeeCord extends ProxyServer

View File

@ -1,4 +1,4 @@
From 802403a3d743e4b95d3b9b4845b9ff2302303b20 Mon Sep 17 00:00:00 2001
From 1c5bedd68d8b2f9d2fa1b221be26a852df25b970 Mon Sep 17 00:00:00 2001
From: LinsaFTW <25271111+linsaftw@users.noreply.github.com>
Date: Fri, 4 Mar 2022 13:35:53 -0300
Subject: [PATCH] Antibot System
@ -1467,32 +1467,32 @@ index 14665b1f6..179bb1c3e 100644
save(configuration, configurationFile);
}
diff --git a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
index 21381bb45..37bccaebd 100644
index ae1794385..6175d8e2d 100644
--- a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
+++ b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
@@ -90,6 +90,22 @@ public class MessagesConfiguration extends FlameConfig {
setIfUnexistant("command_ip", "&9IP of {0} is {1}", configuration);
setIfUnexistant("illegal_chat_characters", "&cIllegal characters in chat ({0})", configuration);
@@ -80,6 +80,22 @@ public class MessagesConfiguration extends FlameConfig {
setIfUnexistant("command_ip", "&9IP of {0} is {1}", configuration);
setIfUnexistant("illegal_chat_characters", "&cIllegal characters in chat ({0})", configuration);
+ // FlameCord start - Antibot System
+ setIfUnexistant("antibot_accounts", "&c&lFlameCord\n\n&cYou have too many accounts! ({0})\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_fastchat", "&c&lFlameCord\n\n&cYou are chatting too fast!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_firewall", "&c&lFlameCord\n\n&cYou are blocked from this server!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_nickname", "&c&lFlameCord\n\n&cYour nickname was detected as bot! ({0})\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_password", "&c&lFlameCord\n\n&cYour password is used by other players! ({0})\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_ratelimit", "&c&lFlameCord\n\n&cYou are connecting too fast! ({0})\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_reconnect", "&c&lFlameCord\n\n&cReconnect {0} more times to enter!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_country", "&c&lFlameCord\n\n&cYour country {0} is blacklisted!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_stats", "&c&lFlameCord Antibot Stats\n &7■ Total Pings: &a{0}\n &7■ Total Connections: &b{1}\n\n &7■ Current Pings: &a{2}\n &7■ Current Connections: &b{3}", configuration);
+
+ setIfUnexistant("flamecord_firewall_help", "&c/flamecord firewall <add/remove> <ip>", configuration);
+ setIfUnexistant("flamecord_firewall_add", "&cThe ip {0} was added to the firewall!", configuration);
+ setIfUnexistant("flamecord_firewall_remove", "&cThe ip {0} was removed from the firewall!", configuration);
+ // FlameCord end - Antibot System
+ // FlameCord start - Antibot System
+ setIfUnexistant("antibot_accounts", "&c&lFlameCord\n\n&cYou have too many accounts! ({0})\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_fastchat", "&c&lFlameCord\n\n&cYou are chatting too fast!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_firewall", "&c&lFlameCord\n\n&cYou are blocked from this server!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_nickname", "&c&lFlameCord\n\n&cYour nickname was detected as bot! ({0})\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_password", "&c&lFlameCord\n\n&cYour password is used by other players! ({0})\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_ratelimit", "&c&lFlameCord\n\n&cYou are connecting too fast! ({0})\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_reconnect", "&c&lFlameCord\n\n&cReconnect {0} more times to enter!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_country", "&c&lFlameCord\n\n&cYour country {0} is blacklisted!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
+ setIfUnexistant("antibot_stats", "&c&lFlameCord Antibot Stats\n &7■ Total Pings: &a{0}\n &7■ Total Connections: &b{1}\n\n &7■ Current Pings: &a{2}\n &7■ Current Connections: &b{3}", configuration);
+
+ setIfUnexistant("flamecord_firewall_help", "&c/flamecord firewall <add/remove> <ip>", configuration);
+ setIfUnexistant("flamecord_firewall_add", "&cThe ip {0} was added to the firewall!", configuration);
+ setIfUnexistant("flamecord_firewall_remove", "&cThe ip {0} was removed from the firewall!", configuration);
+ // FlameCord end - Antibot System
+
configurationProvider.save(configuration, configurationFile);
for (final String key : configuration.getKeys()) {
final Object value = configuration.get(key);
for (final String key : configuration.getKeys()) {
diff --git a/flamecord/src/main/java/dev/_2lstudios/flamecord/enums/PacketsCheckResult.java b/flamecord/src/main/java/dev/_2lstudios/flamecord/enums/PacketsCheckResult.java
new file mode 100644
index 000000000..285810ea1

View File

@ -1,35 +1,28 @@
From 67d06f64115453c920b0a596c59301a6167a93aa Mon Sep 17 00:00:00 2001
From f37bca815bffe22461c5b2760596ef18d56a1070 Mon Sep 17 00:00:00 2001
From: LinsaFTW <25271111+linsaftw@users.noreply.github.com>
Date: Wed, 11 Jan 2023 10:14:12 -0300
Subject: [PATCH] Bungee Plugins Command
diff --git a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
index 37bccaeb..af3d9078 100644
index 6175d8e2d..2ea33a94b 100644
--- a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
+++ b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
@@ -100,11 +100,17 @@ public class MessagesConfiguration extends FlameConfig {
setIfUnexistant("antibot_reconnect", "&c&lFlameCord\n\n&cReconnect {0} more times to enter!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
setIfUnexistant("antibot_country", "&c&lFlameCord\n\n&cYour country {0} is blacklisted!\n\n&cError? Contact us on discord.gg/gF36AT3", configuration);
setIfUnexistant("antibot_stats", "&c&lFlameCord Antibot Stats\n &7■ Total Pings: &a{0}\n &7■ Total Connections: &b{1}\n\n &7■ Current Pings: &a{2}\n &7■ Current Connections: &b{3}", configuration);
-
+
+ // Firewall
setIfUnexistant("flamecord_firewall_help", "&c/flamecord firewall <add/remove> <ip>", configuration);
setIfUnexistant("flamecord_firewall_add", "&cThe ip {0} was added to the firewall!", configuration);
setIfUnexistant("flamecord_firewall_remove", "&cThe ip {0} was removed from the firewall!", configuration);
// FlameCord end - Antibot System
+
+ // FlameCord - Bungee Plugins Command
+ setIfUnexistant("flamecord_bplugins_nopermission", "&cYou don't have permission to do this!", configuration);
+ setIfUnexistant("flamecord_bplugins_separator", ", ", configuration);
+ setIfUnexistant("flamecord_bplugins_header", "&aPlugins ({0}): ", configuration);
@@ -96,6 +96,11 @@ public class MessagesConfiguration extends FlameConfig {
setIfUnexistant("flamecord_firewall_remove", "&cThe ip {0} was removed from the firewall!", configuration);
// FlameCord end - Antibot System
configurationProvider.save(configuration, configurationFile);
+ // FlameCord - Bungee Plugins Command
+ setIfUnexistant("flamecord_bplugins_nopermission", "&cYou don't have permission to do this!", configuration);
+ setIfUnexistant("flamecord_bplugins_separator", ", ", configuration);
+ setIfUnexistant("flamecord_bplugins_header", "&aPlugins ({0}): ", configuration);
+
for (final String key : configuration.getKeys()) {
final Object value = configuration.get(key);
diff --git a/proxy/src/main/java/dev/_2lstudios/flamecord/commands/BungeePluginsCommand.java b/proxy/src/main/java/dev/_2lstudios/flamecord/commands/BungeePluginsCommand.java
new file mode 100644
index 00000000..2e20e9dc
index 000000000..2e20e9dca
--- /dev/null
+++ b/proxy/src/main/java/dev/_2lstudios/flamecord/commands/BungeePluginsCommand.java
@@ -0,0 +1,45 @@
@ -79,7 +72,7 @@ index 00000000..2e20e9dc
+ }
+}
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 44e28adc..705196d5 100644
index 62712330e..ec5fd4af2 100644
--- a/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
+++ b/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
@@ -11,6 +11,7 @@ import com.google.gson.Gson;

View File

@ -1,29 +1,29 @@
From 7c646bd7d69fcef97ee37642bc4ea3269a53eff5 Mon Sep 17 00:00:00 2001
From 79f33268f3f154170f55362decf8fcc8b99a68f8 Mon Sep 17 00:00:00 2001
From: LinsaFTW <25271111+linsaftw@users.noreply.github.com>
Date: Sun, 15 Jan 2023 10:12:45 -0300
Subject: [PATCH] Bungee IP Command
diff --git a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
index af3d9078..34b4a630 100644
index 2ea33a94b..e42bb29d5 100644
--- a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
+++ b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
@@ -112,6 +112,12 @@ public class MessagesConfiguration extends FlameConfig {
setIfUnexistant("flamecord_bplugins_separator", ", ", configuration);
setIfUnexistant("flamecord_bplugins_header", "&aPlugins ({0}): ", configuration);
@@ -101,6 +101,12 @@ public class MessagesConfiguration extends FlameConfig {
setIfUnexistant("flamecord_bplugins_separator", ", ", configuration);
setIfUnexistant("flamecord_bplugins_header", "&aPlugins ({0}): ", configuration);
+ // FlameCord - Bungee IP Command
+ setIfUnexistant("flamecord_bip_nopermission", "&cYou don't have permission to do this!", configuration);
+ setIfUnexistant("flamecord_bip_offline", "&cThe player is not online!", configuration);
+ setIfUnexistant("flamecord_bip_usage", "&c/bip <player>", configuration);
+ setIfUnexistant("flamecord_bip", "&aInformation about {0}&a:\n&aUUID: &b{1}\n&aIP: &b{2}\n&aPing: &b{3}ms\n&aLocale: &b{4}\n&aView Distance: &b{5}\n&aCurrent Server: &b{6}", configuration);
+ // FlameCord - Bungee IP Command
+ setIfUnexistant("flamecord_bip_nopermission", "&cYou don't have permission to do this!", configuration);
+ setIfUnexistant("flamecord_bip_offline", "&cThe player is not online!", configuration);
+ setIfUnexistant("flamecord_bip_usage", "&c/bip <player>", configuration);
+ setIfUnexistant("flamecord_bip", "&aInformation about {0}&a:\n&aUUID: &b{1}\n&aIP: &b{2}\n&aPing: &b{3}ms\n&aLocale: &b{4}\n&aView Distance: &b{5}\n&aCurrent Server: &b{6}", configuration);
+
configurationProvider.save(configuration, configurationFile);
for (final String key : configuration.getKeys()) {
final Object value = configuration.get(key);
for (final String key : configuration.getKeys()) {
diff --git a/proxy/src/main/java/dev/_2lstudios/flamecord/commands/BungeeIPCommand.java b/proxy/src/main/java/dev/_2lstudios/flamecord/commands/BungeeIPCommand.java
new file mode 100644
index 00000000..85313491
index 000000000..85313491e
--- /dev/null
+++ b/proxy/src/main/java/dev/_2lstudios/flamecord/commands/BungeeIPCommand.java
@@ -0,0 +1,45 @@
@ -73,7 +73,7 @@ index 00000000..85313491
+ }
+}
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 705196d5..64fef85f 100644
index ec5fd4af2..f5059666e 100644
--- a/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
+++ b/proxy/src/main/java/net/md_5/bungee/BungeeCord.java
@@ -11,6 +11,7 @@ import com.google.gson.Gson;

View File

@ -1,25 +1,25 @@
From f217a96188ebda80c60e8d83e1bf4795cedc6ad2 Mon Sep 17 00:00:00 2001
From daefdd3d718eecc9ac09fbece9e7baff22e1c195 Mon Sep 17 00:00:00 2001
From: LinsaFTW <25271111+linsaftw@users.noreply.github.com>
Date: Sun, 15 Jan 2023 19:03:34 -0300
Subject: [PATCH] List Command Format
diff --git a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
index 34b4a630..febf19b4 100644
index e42bb29d5..555319a7f 100644
--- a/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
+++ b/flamecord/src/main/java/dev/_2lstudios/flamecord/configuration/MessagesConfiguration.java
@@ -118,6 +118,9 @@ public class MessagesConfiguration extends FlameConfig {
setIfUnexistant("flamecord_bip_usage", "&c/bip <player>", configuration);
setIfUnexistant("flamecord_bip", "&aInformation about {0}&a:\n&aUUID: &b{1}\n&aIP: &b{2}\n&aPing: &b{3}ms\n&aLocale: &b{4}\n&aView Distance: &b{5}\n&aCurrent Server: &b{6}", configuration);
@@ -107,6 +107,9 @@ public class MessagesConfiguration extends FlameConfig {
setIfUnexistant("flamecord_bip_usage", "&c/bip <player>", configuration);
setIfUnexistant("flamecord_bip", "&aInformation about {0}&a:\n&aUUID: &b{1}\n&aIP: &b{2}\n&aPing: &b{3}ms\n&aLocale: &b{4}\n&aView Distance: &b{5}\n&aCurrent Server: &b{6}", configuration);
+ // FlameCord - List Command Format
+ setIfUnexistant("command_list_format", "&aServers:&r", configuration);
+ // FlameCord - List Command Format
+ setIfUnexistant("command_list_format", "&aServers:&r", configuration);
+
configurationProvider.save(configuration, configurationFile);
for (final String key : configuration.getKeys()) {
final Object value = configuration.get(key);
for (final String key : configuration.getKeys()) {
diff --git a/module/cmd-list/src/main/java/net/md_5/bungee/module/cmd/list/CommandList.java b/module/cmd-list/src/main/java/net/md_5/bungee/module/cmd/list/CommandList.java
index c2227110..0a589931 100644
index c22271105..0a5899319 100644
--- a/module/cmd-list/src/main/java/net/md_5/bungee/module/cmd/list/CommandList.java
+++ b/module/cmd-list/src/main/java/net/md_5/bungee/module/cmd/list/CommandList.java
@@ -25,6 +25,9 @@ public class CommandList extends Command