TotalFreedomMod/src/main/java/me/totalfreedom/totalfreedommod/config/ConfigEntry.java

261 lines
11 KiB
Java
Raw Normal View History

package me.totalfreedom.totalfreedommod.config;
2013-08-17 22:24:40 +00:00
import java.util.List;
import me.totalfreedom.totalfreedommod.TotalFreedomMod;
public enum ConfigEntry
2013-08-17 22:24:40 +00:00
{
FORCE_IP_ENABLED(Boolean.class, "forceip.enabled"),
FORCE_IP_PORT(Integer.class, "forceip.port"),
FORCE_IP_KICKMSG(String.class, "forceip.kickmsg"),
//
2014-04-26 11:21:36 +00:00
ALLOW_EXPLOSIONS(Boolean.class, "allow.explosions"),
ALLOW_FIRE_PLACE(Boolean.class, "allow.fire_place"),
ALLOW_FIRE_SPREAD(Boolean.class, "allow.fire_spread"),
ALLOW_FLUID_SPREAD(Boolean.class, "allow.fluid_spread"),
ALLOW_LAVA_DAMAGE(Boolean.class, "allow.lava_damage"),
ALLOW_LAVA_PLACE(Boolean.class, "allow.lava_place"),
ALLOW_TNT_MINECARTS(Boolean.class, "allow.tnt_minecarts"),
ALLOW_WATER_PLACE(Boolean.class, "allow.water_place"),
2017-11-11 17:09:57 +00:00
ALLOW_REDSTONE(Boolean.class, "allow.redstone"),
ALLOW_FIREWORK_EXPLOSION(Boolean.class, "allow.fireworks"),
ALLOW_FROSTWALKER(Boolean.class, "allow.frostwalker"),
2019-02-22 23:16:08 +00:00
ALLOW_UNSAFE_ENCHANTMENTS(Boolean.class, "allow.unsafe_enchantments"),
2019-07-31 04:35:41 +00:00
ALLOW_BELLS(Boolean.class, "allow.bells"),
2019-08-27 23:25:50 +00:00
ALLOW_ARMOR_STANDS(Boolean.class, "allow.armorstands"),
2019-12-10 00:59:17 +00:00
ALLOW_MINECARTS(Boolean.class, "allow.minecarts"),
ALLOW_STRUCTURE_BLOCKS(Boolean.class, "allow.structureblocks"),
ALLOW_JIGSAWS(Boolean.class, "allow.jigsaws"),
ALLOW_GRINDSTONES(Boolean.class, "allow.grindstones"),
ALLOW_JUKEBOXES(Boolean.class, "allow.jukeboxes"),
ALLOW_SPAWNERS(Boolean.class, "allow.spawners"),
2020-02-09 04:52:43 +00:00
ALLOW_BEEHIVES(Boolean.class, "allow.beehives"),
2020-07-02 12:13:20 +00:00
ALLOW_RESPAWN_ANCHORS(Boolean.class, "allow.respawnanchors"),
2020-05-29 10:14:21 +00:00
AUTO_TP(Boolean.class, "allow.auto_tp"),
AUTO_CLEAR(Boolean.class, "allow.auto_clear"),
ALLOW_GRAVITY(Boolean.class, "allow.gravity"),
//
2017-12-23 04:07:36 +00:00
BLOCKED_CHATCODES(String.class, "blocked_chatcodes"),
//
MOB_LIMITER_ENABLED(Boolean.class, "moblimiter.enabled"),
MOB_LIMITER_MAX(Integer.class, "moblimiter.max"),
2014-04-26 11:21:36 +00:00
MOB_LIMITER_DISABLE_DRAGON(Boolean.class, "moblimiter.disable.dragon"),
MOB_LIMITER_DISABLE_GHAST(Boolean.class, "moblimiter.disable.ghast"),
MOB_LIMITER_DISABLE_GIANT(Boolean.class, "moblimiter.disable.giant"),
MOB_LIMITER_DISABLE_SLIME(Boolean.class, "moblimiter.disable.slime"),
//
HTTPD_ENABLED(Boolean.class, "httpd.enabled"),
2020-08-17 22:17:45 +00:00
HTTPD_HOST(String.class, "httpd.host"),
HTTPD_PORT(Integer.class, "httpd.port"),
HTTPD_PUBLIC_FOLDER(String.class, "httpd.public_folder"),
//
SERVER_COLORFUL_MOTD(Boolean.class, "server.colorful_motd"),
SERVER_NAME(String.class, "server.name"),
SERVER_ADDRESS(String.class, "server.address"),
SERVER_MOTD(String.class, "server.motd"),
2019-12-25 01:05:36 +00:00
SERVER_LOGIN_TITLE(String.class, "server.login_title.title"),
SERVER_LOGIN_SUBTITLE(String.class, "server.login_title.subtitle"),
SERVER_OWNERS(List.class, "server.owners"),
2018-05-13 19:49:13 +00:00
SERVER_EXECUTIVES(List.class, "server.executives"),
SERVER_ASSISTANT_EXECUTIVES(List.class, "server.assistant_executives"),
2019-04-23 07:36:51 +00:00
SERVER_MASTER_BUILDER_MANAGEMENT(List.class, "server.master_builder_management"),
SERVER_BAN_URL(String.class, "server.ban_url"),
2020-08-10 00:49:52 +00:00
SERVER_INDEFBAN_URL(String.class, "server.indefban_url"),
2019-07-11 02:13:57 +00:00
SERVER_TABLIST_HEADER(String.class, "server.tablist_header"),
SERVER_TABLIST_FOOTER(String.class, "server.tablist_footer"),
2013-08-17 22:24:40 +00:00
//
2020-01-04 23:35:41 +00:00
SERVER_BAN_MOTD(String.class, "server.motds.ban"),
SERVER_ADMINMODE_MOTD(String.class, "server.motds.adminmode"),
2020-01-04 23:35:41 +00:00
SERVER_LOCKDOWN_MOTD(String.class, "server.motds.lockdown"),
SERVER_WHITELIST_MOTD(String.class, "server.motds.whitelist"),
SERVER_FULL_MOTD(String.class, "server.motds.full"),
//
DISCORD_VERIFICATION(Boolean.class, "discord.verification"),
2017-12-29 18:12:47 +00:00
DISCORD_TOKEN(String.class, "discord.token"),
2019-04-21 00:16:00 +00:00
DISCORD_REPORT_CHANNEL_ID(String.class, "discord.report_channel_id"),
2019-11-28 09:08:36 +00:00
DISCORD_CHAT_CHANNEL_ID(String.class, "discord.chat_channel_id"),
2020-11-15 02:13:59 +00:00
DISCORD_ADMINCHAT_CHANNEL_ID(String.class, "discord.adminchat_channel_id"),
2019-04-21 00:16:00 +00:00
DISCORD_ROLE_SYNC(Boolean.class, "discord.role_sync"),
DISCORD_SERVER_ID(String.class, "discord.server_id"),
2019-11-03 21:40:05 +00:00
DISCORD_MASTER_BUILDER_ROLE_ID(String.class, "discord.master_builder_role_id"),
DISCORD_NEW_ADMIN_ROLE_ID(String.class, "discord.admin_role_id"),
DISCORD_SENIOR_ADMIN_ROLE_ID(String.class, "discord.senior_admin_role_id"),
2019-11-03 21:40:05 +00:00
DISCORD_DEVELOPER_ROLE_ID(String.class, "discord.developer_role_id"),
2021-04-26 07:23:24 +00:00
DISCORD_ASSISTANT_EXECUTIVE_ROLE_ID(String.class, "discord.assistant_executive_role_id"),
2019-11-03 21:40:05 +00:00
DISCORD_EXECUTIVE_ROLE_ID(String.class, "discord.executive_role_id"),
DISCORD_SERVER_OWNER_ROLE_ID(String.class, "discord.server_owner_role_id"),
DISCORD_INVITE_LINK(String.class, "discord.invite_link"),
2019-11-02 01:28:07 +00:00
//
2020-09-14 09:36:25 +00:00
PTERO_URL(String.class, "ptero.url"),
PTERO_DEFAULT_EMAIL_DOMAIN(String.class, "ptero.default_email_domain"),
PTERO_SERVER_UUID(String.class, "ptero.server_uuid"),
PTERO_ADMIN_KEY(String.class, "ptero.admin_key"),
PTERO_SERVER_KEY(String.class, "ptero.server_key"),
2020-08-08 05:51:09 +00:00
//
2019-11-02 01:28:07 +00:00
SHOP_ENABLED(Boolean.class, "shop.enabled"),
2020-04-08 02:20:01 +00:00
SHOP_TITLE(String.class, "shop.title"),
2019-11-02 01:28:07 +00:00
SHOP_PREFIX(String.class, "shop.prefix"),
2020-04-08 02:20:01 +00:00
SHOP_COINS_PER_VOTE(Integer.class, "shop.coins_per_vote"),
2020-04-08 08:34:08 +00:00
SHOP_REACTIONS_ENABLED(Boolean.class, "shop.reactions.enabled"),
SHOP_REACTIONS_INTERVAL(Integer.class, "shop.reactions.interval"),
2020-07-02 08:42:27 +00:00
SHOP_REACTIONS_TIME(Double.class, "shop.reactions.time"),
2020-04-08 08:34:08 +00:00
SHOP_REACTIONS_COINS_PER_WIN(Integer.class, "shop.reactions.coins_per_win"),
SHOP_REACTIONS_STRING_LENGTH(Integer.class, "shop.reactions.string_length"),
SHOP_LOGIN_MESSAGES(List.class, "shop.login_messages"),
2020-04-08 02:20:01 +00:00
SHOP_PRICES_GRAPPLING_HOOK(Integer.class, "shop.prices.grappling_hook"),
SHOP_PRICES_LIGHTNING_ROD(Integer.class, "shop.prices.lightning_rod"),
SHOP_PRICES_FIRE_BALL(Integer.class, "shop.prices.fire_ball"),
SHOP_PRICES_RIDEABLE_PEARL(Integer.class, "shop.prices.rideable_pearl"),
2020-07-02 08:42:27 +00:00
SHOP_PRICES_STACKING_POTATO(Integer.class, "shop.prices.stacking_potato"),
SHOP_PRICES_CLOWN_FISH(Integer.class, "shop.prices.clown_fish"),
SHOP_PRICES_LOGIN_MESSAGES(Integer.class, "shop.prices.login_messages"),
2021-09-03 19:53:33 +00:00
SHOP_PRICES_RAINBOW_TRAIL(Integer.class, "shop.prices.rainbow_trail"),
2017-12-29 18:12:47 +00:00
//
ADMINLIST_CLEAN_THESHOLD_HOURS(Integer.class, "adminlist.clean_threshold_hours"),
ADMINLIST_CONSOLE_IS_ADMIN(Boolean.class, "adminlist.console_is_admin"),
2013-08-17 22:24:40 +00:00
//
2019-02-22 23:16:08 +00:00
COREPROTECT_MYSQL_ENABLED(Boolean.class, "coreprotect.enabled"),
COREPROTECT_MYSQL_HOST(String.class, "coreprotect.host"),
COREPROTECT_MYSQL_PORT(String.class, "coreprotect.port"),
COREPROTECT_MYSQL_USERNAME(String.class, "coreprotect.username"),
COREPROTECT_MYSQL_PASSWORD(String.class, "coreprotect.password"),
COREPROTECT_MYSQL_DATABASE(String.class, "coreprotect.database"),
2017-11-11 17:09:57 +00:00
//
DISABLE_NIGHT(Boolean.class, "disable.night"),
DISABLE_WEATHER(Boolean.class, "disable.weather"),
//
ENABLE_PREPROCESS_LOG(Boolean.class, "preprocess_log"),
ENABLE_PET_PROTECT(Boolean.class, "petprotect.enabled"),
//
LANDMINES_ENABLED(Boolean.class, "landmines_enabled"),
TOSSMOB_ENABLED(Boolean.class, "tossmob_enabled"),
AUTOKICK_ENABLED(Boolean.class, "autokick.enabled"),
MP44_ENABLED(Boolean.class, "mp44_enabled"),
2019-12-10 00:59:17 +00:00
FOURCHAN_ENABLED(Boolean.class, "4chan_enabled"),
//
NUKE_MONITOR_ENABLED(Boolean.class, "nukemonitor.enabled"),
2014-04-26 11:21:36 +00:00
NUKE_MONITOR_COUNT_BREAK(Integer.class, "nukemonitor.count_break"),
NUKE_MONITOR_COUNT_PLACE(Integer.class, "nukemonitor.count_place"),
NUKE_MONITOR_RANGE(Double.class, "nukemonitor.range"),
//
AUTOKICK_THRESHOLD(Double.class, "autokick.threshold"),
2014-04-26 11:21:36 +00:00
AUTOKICK_TIME(Integer.class, "autokick.time"),
2013-08-17 22:24:40 +00:00
//
LOGS_SECRET(String.class, "logs.secret"),
LOGS_URL(String.class, "logs.url"),
2013-08-17 22:24:40 +00:00
//
FLATLANDS_GENERATE(Boolean.class, "flatlands.generate"),
FLATLANDS_GENERATE_PARAMS(String.class, "flatlands.generate_params"),
//
ANNOUNCER_ENABLED(Boolean.class, "announcer.enabled"),
ANNOUNCER_INTERVAL(Integer.class, "announcer.interval"),
ANNOUNCER_PREFIX(String.class, "announcer.prefix"),
ANNOUNCER_ANNOUNCEMENTS(List.class, "announcer.announcements"),
//
EXPLOSIVE_RADIUS(Double.class, "explosive_radius"),
FREECAM_TRIGGER_COUNT(Integer.class, "freecam_trigger_count"),
SERVICE_CHECKER_URL(String.class, "service_checker_url"),
BLOCKED_COMMANDS(List.class, "blocked_commands.global"),
MUTED_BLOCKED_COMMANDS(List.class, "blocked_commands.muted"),
WILDCARD_BLOCKED_COMMANDS(List.class, "blocked_commands.wildcard"),
FORBIDDEN_WORDS(List.class, "forbidden_words"),
HOST_SENDER_NAMES(List.class, "host_sender_names"),
FAMOUS_PLAYERS(List.class, "famous_players"),
ADMIN_ONLY_MODE(Boolean.class, "admin_only_mode"),
ADMIN_INFO(List.class, "admininfo"),
2020-08-17 22:17:45 +00:00
VOTING_INFO(List.class, "votinginfo"),
2019-01-12 03:05:12 +00:00
MASTER_BUILDER_INFO(List.class, "masterbuilderinfo"),
FIRST_JOIN_INFO(List.class, "first_join_info.text"),
FIRST_JOIN_INFO_ENABLED(Boolean.class, "first_join_info.enabled"),
AUTO_ENTITY_WIPE(Boolean.class, "auto_wipe"),
2020-08-01 04:10:44 +00:00
TOGGLE_CHAT(Boolean.class, "toggle_chat"),
DEVELOPER_MODE(Boolean.class, "developer_mode"),
ANTISPAM_MINUTES(Integer.class, "antispam_minutes");
2013-08-17 22:24:40 +00:00
//
private final Class<?> type;
private final String configName;
ConfigEntry(Class<?> type, String configName)
2013-08-17 22:24:40 +00:00
{
this.type = type;
this.configName = configName;
}
public static ConfigEntry findConfigEntry(String name)
{
name = name.toLowerCase().replace("_", "");
for (ConfigEntry entry : values())
{
if (entry.toString().toLowerCase().replace("_", "").equals(name))
{
return entry;
}
}
return null;
}
2013-08-17 22:24:40 +00:00
public Class<?> getType()
{
return type;
}
public String getConfigName()
{
return configName;
}
public String getString()
{
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
return getConfig().getString(this);
2013-08-17 22:24:40 +00:00
}
public Double getDouble()
{
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
return getConfig().getDouble(this);
2013-08-17 22:24:40 +00:00
}
public void setDouble(Double value)
2013-08-17 22:24:40 +00:00
{
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
getConfig().setDouble(this, value);
2013-08-17 22:24:40 +00:00
}
public Boolean getBoolean()
{
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
return getConfig().getBoolean(this);
2013-08-17 22:24:40 +00:00
}
2013-08-18 18:52:46 +00:00
public Boolean setBoolean(Boolean value)
2013-08-17 22:24:40 +00:00
{
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
getConfig().setBoolean(this, value);
2013-08-18 18:52:46 +00:00
return value;
2013-08-17 22:24:40 +00:00
}
public Integer getInteger()
{
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
return getConfig().getInteger(this);
2013-08-17 22:24:40 +00:00
}
public void setInteger(Integer value)
2013-08-17 22:24:40 +00:00
{
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
getConfig().setInteger(this, value);
2013-08-17 22:24:40 +00:00
}
2013-08-28 19:40:14 +00:00
public List<?> getList()
2013-08-17 22:24:40 +00:00
{
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
return getConfig().getList(this);
}
@SuppressWarnings("unchecked")
public List<String> getStringList()
{
return (List<String>)getList();
TotalFreedomMod Electrum Version 5.0 This TotalFreedomMod release implements many changes. Most notably, the internals have been completely revamped. TotalFreedomMod now relies on the Aero library for core mechanics such as command handling and services. Another important change is the UUID system. In TotalFreedomMod Electrum, it has been completely removed. The core reason for this is that the system as a whole was very bugged. Additionally, it did not solve the primary reason for its conception: preserving player data when the player changes their username. This is because TotalFreedomMod servers usually run in offline-mode. This meaning that some of the players joining do not have a registerd Mojang UUID whatsoever. All in all, the UUID system was buggy, and it did not fix the reason it was implemented, so it has been completely removed. The admin list and the ban list now use usernames and IPs again. Lastly, many smaller changes have been implemented. Due to the amount of changes, they have not been named individualy. Please refer to the issues below for more details. Fixes #342 Fixes #350 Fixes #380 Fixes #684 Fixes #704 Fixes #716 Fixes #735 Fixes #745 Fixes #784 Fixes #765 Fixes #791 Fixes #805 Fixes #826 Fixes #883 Fixes #1524 Fixes #1534 Fixes #1536 Fixes #1538 Fixes #1545 Fixes #1546 Fixes #1568 Fixes #1627 Resolves #403 Resolves #435 Resolves #597 Resolves #603 Resolves #628 Resolves #690 Resolves #708 Resolves #747 Resolves #748 Resolves #749 Resolves #764 Resolves #767 Resolves #782 Resolves #809 Resolves #803 Resolves #811 Resolves #813 Resolves #830 Resolves #848 Resolves #856 Resolves #876 Resolves #908 Resolves #992 Resolves #1018 Resolves #1432 Resolves #1446 Resolves #1494 Resolves #1501 Resolves #1526 Resolves #1540 Resolves #1550 Resolves #1560 Resolves #1561 Resolves #1578 Resolves #1613
2016-05-12 19:40:39 +00:00
}
private MainConfig getConfig()
{
2020-12-26 23:54:15 +00:00
return TotalFreedomMod.getPlugin().config;
2013-08-17 22:24:40 +00:00
}
2017-12-23 04:07:36 +00:00
}