diff --git a/src/main/java/me/machinemaker/papertweaks/RootCommand.java b/src/main/java/me/machinemaker/papertweaks/RootCommand.java index 36d2c8b2..675bcaae 100644 --- a/src/main/java/me/machinemaker/papertweaks/RootCommand.java +++ b/src/main/java/me/machinemaker/papertweaks/RootCommand.java @@ -80,7 +80,7 @@ public RootCommand(final ModuleManager moduleManager, @Named("modules") final Co } public void registerCommands() { - this.builder = this.manager.commandBuilder("vanillatweaks", RichDescription.translatable("commands.root"), "vt", "vtweaks"); + this.builder = this.manager.commandBuilder("vanillatweaks", RichDescription.translatable("commands.root"), "vt", "vtweaks", "pt", "papertweaks", "ptweaks"); this.manager.command(this.simple("reload") .handler(this.sync(this::reloadEverything)) diff --git a/src/main/java/me/machinemaker/papertweaks/adventure/TranslationRegistry.java b/src/main/java/me/machinemaker/papertweaks/adventure/TranslationRegistry.java index 599f1983..6573c09d 100644 --- a/src/main/java/me/machinemaker/papertweaks/adventure/TranslationRegistry.java +++ b/src/main/java/me/machinemaker/papertweaks/adventure/TranslationRegistry.java @@ -31,7 +31,7 @@ public final class TranslationRegistry { - private static final Key LANG_KEY = Key.key("vanillatweaks", "lang"); + private static final Key LANG_KEY = Key.key("papertweaks", "lang"); private static final Map TRANSLATIONS = Maps.newConcurrentMap(); private static final net.kyori.adventure.translation.TranslationRegistry ADVENTURE_REGISTRY = net.kyori.adventure.translation.TranslationRegistry.create(LANG_KEY); diff --git a/src/main/java/me/machinemaker/papertweaks/cloud/MetaKeys.java b/src/main/java/me/machinemaker/papertweaks/cloud/MetaKeys.java index 9d81d189..c0ca8cc6 100644 --- a/src/main/java/me/machinemaker/papertweaks/cloud/MetaKeys.java +++ b/src/main/java/me/machinemaker/papertweaks/cloud/MetaKeys.java @@ -24,7 +24,7 @@ public final class MetaKeys { - public static final CommandMeta.Key GAMEMODE_KEY = CommandMeta.Key.of(GameMode.class, "vanillatweaks:gamemode"); + public static final CommandMeta.Key GAMEMODE_KEY = CommandMeta.Key.of(GameMode.class, "papertweaks:gamemode"); private MetaKeys() { } diff --git a/src/main/java/me/machinemaker/papertweaks/cloud/cooldown/CommandCooldown.java b/src/main/java/me/machinemaker/papertweaks/cloud/cooldown/CommandCooldown.java index a6f87884..917ec838 100644 --- a/src/main/java/me/machinemaker/papertweaks/cloud/cooldown/CommandCooldown.java +++ b/src/main/java/me/machinemaker/papertweaks/cloud/cooldown/CommandCooldown.java @@ -37,7 +37,7 @@ */ public interface CommandCooldown { - CommandMeta.Key> COMMAND_META_KEY = CommandMeta.Key.of(new TypeToken<>() {}, "vanillatweaks:command_cooldown"); + CommandMeta.Key> COMMAND_META_KEY = CommandMeta.Key.of(new TypeToken<>() {}, "papertweaks:command_cooldown"); /** * Apply this {@link CommandCooldown} to a {@link Command.Builder} instance. diff --git a/src/main/java/me/machinemaker/papertweaks/cloud/processors/SimpleSuggestionProcessor.java b/src/main/java/me/machinemaker/papertweaks/cloud/processors/SimpleSuggestionProcessor.java index dfb09fca..4cbe250a 100644 --- a/src/main/java/me/machinemaker/papertweaks/cloud/processors/SimpleSuggestionProcessor.java +++ b/src/main/java/me/machinemaker/papertweaks/cloud/processors/SimpleSuggestionProcessor.java @@ -32,7 +32,7 @@ public final class SimpleSuggestionProcessor implements CommandSuggestionProcessor { - public static final CloudKey IGNORE_CASE = SimpleCloudKey.of("vanillatweaks:suggestions/ignore_case", TypeToken.get(Boolean.class)); + public static final CloudKey IGNORE_CASE = SimpleCloudKey.of("papertweaks:suggestions/ignore_case", TypeToken.get(Boolean.class)); @Override public List apply(final CommandPreprocessingContext context, final List strings) { diff --git a/src/main/java/me/machinemaker/papertweaks/modules/ModuleCommand.java b/src/main/java/me/machinemaker/papertweaks/modules/ModuleCommand.java index 9547ee2c..e0c2b3b2 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/ModuleCommand.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/ModuleCommand.java @@ -63,7 +63,7 @@ public abstract class ModuleCommand extends VanillaTweaksCommand { - private static final CommandMeta.Key MODULE_OWNER = CommandMeta.Key.of(ModuleBase.class, "vanillatweaks:commands/module_owner"); + private static final CommandMeta.Key MODULE_OWNER = CommandMeta.Key.of(ModuleBase.class, "papertweaks:commands/module_owner"); private static final MinecraftHelp.HelpColors MODULE_HELP_COLORS = MinecraftHelp.HelpColors.of( TextColor.color(0x70B3B3), NamedTextColor.AQUA, diff --git a/src/main/java/me/machinemaker/papertweaks/modules/experimental/elevators/Elevators.java b/src/main/java/me/machinemaker/papertweaks/modules/experimental/elevators/Elevators.java index a0cfd62e..1322eae6 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/experimental/elevators/Elevators.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/experimental/elevators/Elevators.java @@ -32,7 +32,7 @@ @ModuleInfo(name = "Elevators", configPath = "experimental.elevators", description = "Create vertical elevators on wool blocks by throwing an enderpearl on the wool block") public class Elevators extends ModuleBase { - static final PDCKey IS_ELEVATOR = PDCKey.bool(Keys.key("is_elevator")); + static final PDCKey IS_ELEVATOR = PDCKey.bool(Keys.legacyKey("is_elevator")); @Override protected Class lifecycle() { diff --git a/src/main/java/me/machinemaker/papertweaks/modules/experimental/xpmanagement/XPManagement.java b/src/main/java/me/machinemaker/papertweaks/modules/experimental/xpmanagement/XPManagement.java index 4866f484..95878bc7 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/experimental/xpmanagement/XPManagement.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/experimental/xpmanagement/XPManagement.java @@ -35,7 +35,7 @@ @ModuleInfo(name = "XPManagement", configPath = "experimental.xp-management", description = "Store XP in bottles, smelt in furnace to retrieve XP") public class XPManagement extends ModuleBase { - private static final NamespacedKey XP_RECIPE_KEY = Keys.key("xp_management_recipe"); + private static final NamespacedKey XP_RECIPE_KEY = Keys.legacyKey("xp_management_recipe"); private static final FurnaceRecipe XP_RECIPE = new FurnaceRecipe(XP_RECIPE_KEY, new ItemStack(Material.GLASS_BOTTLE), Material.EXPERIENCE_BOTTLE, 12, 1); @Override diff --git a/src/main/java/me/machinemaker/papertweaks/modules/hermitcraft/tag/Tag.java b/src/main/java/me/machinemaker/papertweaks/modules/hermitcraft/tag/Tag.java index aa56a536..dca1c60a 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/hermitcraft/tag/Tag.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/hermitcraft/tag/Tag.java @@ -42,8 +42,8 @@ public class Tag extends ModuleBase { static final ItemStack TAG_ITEM = new ItemStack(Material.NAME_TAG); - static final PDCKey IT = PDCKey.bool(Keys.key("tag")); - static final PDCKey COOLDOWN = PDCKey.forLong(Keys.key("cooldown")); + static final PDCKey IT = PDCKey.bool(Keys.legacyKey("tag")); + static final PDCKey COOLDOWN = PDCKey.forLong(Keys.legacyKey("cooldown")); static { final ItemMeta meta = TAG_ITEM.getItemMeta(); diff --git a/src/main/java/me/machinemaker/papertweaks/modules/hermitcraft/thundershrine/ThunderShrine.java b/src/main/java/me/machinemaker/papertweaks/modules/hermitcraft/thundershrine/ThunderShrine.java index 60c4c078..4e39afc1 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/hermitcraft/thundershrine/ThunderShrine.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/hermitcraft/thundershrine/ThunderShrine.java @@ -32,7 +32,7 @@ @ModuleInfo(name = "ThunderShrine", configPath = "hermitcraft.thunder-shrine", description = "Create a shrine to summon thunderstorms") public class ThunderShrine extends ModuleBase { - static final PDCKey SHRINE = PDCKey.uuid(Keys.key("shrine")); + static final PDCKey SHRINE = PDCKey.uuid(Keys.legacyKey("shrine")); @Override protected Class lifecycle() { diff --git a/src/main/java/me/machinemaker/papertweaks/modules/items/armoredelytra/ItemDropRunnable.java b/src/main/java/me/machinemaker/papertweaks/modules/items/armoredelytra/ItemDropRunnable.java index a58829a2..ccb58f05 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/items/armoredelytra/ItemDropRunnable.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/items/armoredelytra/ItemDropRunnable.java @@ -56,8 +56,8 @@ class ItemDropRunnable extends BukkitRunnable { - static final PDCKey ELYTRA_ITEM = PDCKey.itemStack(Keys.key("ae.elytra_item")); - static final PDCKey CHESTPLATE_ITEM = PDCKey.itemStack(Keys.key("ae.chestplate_item")); + static final PDCKey ELYTRA_ITEM = PDCKey.itemStack(Keys.legacyKey("ae.elytra_item")); + static final PDCKey CHESTPLATE_ITEM = PDCKey.itemStack(Keys.legacyKey("ae.chestplate_item")); private final Item item; private final LookingFor lookingFor; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/items/armoredelytra/ItemListener.java b/src/main/java/me/machinemaker/papertweaks/modules/items/armoredelytra/ItemListener.java index fcd8774e..59bbaa8d 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/items/armoredelytra/ItemListener.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/items/armoredelytra/ItemListener.java @@ -33,7 +33,7 @@ class ItemListener implements ModuleListener { - static final PDCKey IS_ARMORED_ELYTRA = PDCKey.bool(Keys.key("ae.is_armored_elytra")); + static final PDCKey IS_ARMORED_ELYTRA = PDCKey.bool(Keys.legacyKey("ae.is_armored_elytra")); private final Plugin plugin; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/items/wrenches/Lifecycle.java b/src/main/java/me/machinemaker/papertweaks/modules/items/wrenches/Lifecycle.java index a96cae24..5485bbbd 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/items/wrenches/Lifecycle.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/items/wrenches/Lifecycle.java @@ -47,7 +47,7 @@ class Lifecycle extends ModuleLifecycle { static final byte[] RESOURCE_PACK_HASH = new BigInteger("1ACF79C491B3CB9EEE50816AD0CC1FC45AABA147", 16).toByteArray(); static final ItemStack WRENCH = new ItemStack(Material.CARROT_ON_A_STICK, 1); - static final NamespacedKey WRENCH_RECIPE_KEY = Keys.key("redstone_wrench"); + static final NamespacedKey WRENCH_RECIPE_KEY = Keys.legacyKey("redstone_wrench"); static final ShapedRecipe WRENCH_RECIPE = new ShapedRecipe(WRENCH_RECIPE_KEY, WRENCH) .shape( " # ", diff --git a/src/main/java/me/machinemaker/papertweaks/modules/other/persistentheads/BlockListener.java b/src/main/java/me/machinemaker/papertweaks/modules/other/persistentheads/BlockListener.java index 53260cb8..1418b8f7 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/other/persistentheads/BlockListener.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/other/persistentheads/BlockListener.java @@ -55,8 +55,8 @@ class BlockListener implements ModuleListener { - private static final PDCKey HEAD_NAME = new PDCKey<>(Keys.key("head_name"), PaperDataTypes.COMPONENT); - private static final PDCKey> HEAD_LORE = new PDCKey<>(Keys.key("head_lore"), PaperDataTypes.COMPONENT_LIST); + private static final PDCKey HEAD_NAME = new PDCKey<>(Keys.legacyKey("head_name"), PaperDataTypes.COMPONENT); + private static final PDCKey> HEAD_LORE = new PDCKey<>(Keys.legacyKey("head_lore"), PaperDataTypes.COMPONENT_LIST); private final Plugin plugin; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/survival/afkdisplay/AFKDisplay.java b/src/main/java/me/machinemaker/papertweaks/modules/survival/afkdisplay/AFKDisplay.java index ff972298..141bc6a5 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/survival/afkdisplay/AFKDisplay.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/survival/afkdisplay/AFKDisplay.java @@ -33,7 +33,7 @@ @ModuleInfo(name = "AFKDisplay", configPath = "survival.afk-display", description = "Tracks player AFK status") public class AFKDisplay extends ModuleBase { - public static final PDCKey AFK_DISPLAY = PDCKey.bool(Keys.key("afk")); + public static final PDCKey AFK_DISPLAY = PDCKey.bool(Keys.legacyKey("afk")); @Override protected Class lifecycle() { diff --git a/src/main/java/me/machinemaker/papertweaks/modules/survival/coordinateshud/HUDRunnable.java b/src/main/java/me/machinemaker/papertweaks/modules/survival/coordinateshud/HUDRunnable.java index 6c578ec3..1b960f4c 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/survival/coordinateshud/HUDRunnable.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/survival/coordinateshud/HUDRunnable.java @@ -29,7 +29,6 @@ import me.machinemaker.papertweaks.pdc.PDCKey; import me.machinemaker.papertweaks.utils.Keys; import me.machinemaker.papertweaks.utils.runnables.TimerRunnable; -import net.kyori.adventure.audience.Audience; import net.kyori.adventure.text.Component; import net.kyori.adventure.text.TextComponent; import net.kyori.adventure.text.format.NamedTextColor; @@ -42,7 +41,7 @@ @Singleton class HUDRunnable extends TimerRunnable { - private static final PDCKey COORDINATES_HUD_KEY = PDCKey.bool(Keys.key("coordinateshud")); + private static final PDCKey COORDINATES_HUD_KEY = PDCKey.bool(Keys.legacyKey("coordinateshud")); private final Set enabled = ConcurrentHashMap.newKeySet(); private final Config config; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/survival/graves/PlayerListener.java b/src/main/java/me/machinemaker/papertweaks/modules/survival/graves/PlayerListener.java index b4cb8cc9..e8c445bd 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/survival/graves/PlayerListener.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/survival/graves/PlayerListener.java @@ -25,7 +25,6 @@ import me.machinemaker.papertweaks.modules.ModuleListener; import me.machinemaker.papertweaks.utils.CachedHashObjectWrapper; import me.machinemaker.papertweaks.utils.Keys; -import net.kyori.adventure.audience.Audience; import org.apache.commons.lang3.mutable.MutableInt; import org.bukkit.Bukkit; import org.bukkit.Location; @@ -73,18 +72,18 @@ class PlayerListener implements ModuleListener { - static final NamespacedKey GRAVE_KEY = Keys.key("graves.grave_key"); + static final NamespacedKey GRAVE_KEY = Keys.legacyKey("graves.grave_key"); - static final NamespacedKey LAST_GRAVE_LOCATION = Keys.key("graves.last_grave_location"); + static final NamespacedKey LAST_GRAVE_LOCATION = Keys.legacyKey("graves.last_grave_location"); - private static final NamespacedKey PROTECTED = Keys.key("protected"); - private static final NamespacedKey TIMESTAMP = Keys.key("timestamp"); - private static final NamespacedKey PLAYER_UUID = Keys.key("player_uuid"); - private static final NamespacedKey PLAYER_ALL_CONTENTS = Keys.key("player_all_contents"); - private static final NamespacedKey PLAYER_EXPERIENCE = Keys.key("graves.player_experience"); - private static final @Deprecated NamespacedKey PLAYER_INV_CONTENTS = Keys.key("player_inventory_contents"); - private static final @Deprecated NamespacedKey PLAYER_ARM_CONTENTS = Keys.key("player_armor_contents"); - private static final @Deprecated NamespacedKey PLAYER_EXTRA_CONTENTS = Keys.key("player_extra_contents"); + private static final NamespacedKey PROTECTED = Keys.legacyKey("protected"); + private static final NamespacedKey TIMESTAMP = Keys.legacyKey("timestamp"); + private static final NamespacedKey PLAYER_UUID = Keys.legacyKey("player_uuid"); + private static final NamespacedKey PLAYER_ALL_CONTENTS = Keys.legacyKey("player_all_contents"); + private static final NamespacedKey PLAYER_EXPERIENCE = Keys.legacyKey("graves.player_experience"); + private static final @Deprecated NamespacedKey PLAYER_INV_CONTENTS = Keys.legacyKey("player_inventory_contents"); + private static final @Deprecated NamespacedKey PLAYER_ARM_CONTENTS = Keys.legacyKey("player_armor_contents"); + private static final @Deprecated NamespacedKey PLAYER_EXTRA_CONTENTS = Keys.legacyKey("player_extra_contents"); private final JavaPlugin plugin; private final Config config; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/back/Back.java b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/back/Back.java index 04eacad0..caeb6f74 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/back/Back.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/back/Back.java @@ -38,7 +38,7 @@ @ModuleInfo(name = "Back", configPath = "teleportation.back", description = "Adds a /back command to teleport back to previous locations") public class Back extends ModuleBase { - static final PDCKey BACK_LOCATION = new PDCKey<>(Keys.key("back/location"), DataTypes.LOCATION); + static final PDCKey BACK_LOCATION = new PDCKey<>(Keys.legacyKey("back/location"), DataTypes.LOCATION); @Override protected void configure() { diff --git a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/back/Commands.java b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/back/Commands.java index 4c241714..760ea58e 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/back/Commands.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/back/Commands.java @@ -38,7 +38,7 @@ @ModuleCommand.Info(value = "back", i18n = "back", perm = "back", infoOnRoot = false) class Commands extends ConfiguredModuleCommand { - static final CloudKey BACK_COMMAND_COOLDOWN_KEY = SimpleCloudKey.of("vanillatweaks:back_cmd_cooldown"); + static final CloudKey BACK_COMMAND_COOLDOWN_KEY = SimpleCloudKey.of("papertweaks:back_cmd_cooldown"); private final Config config; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/homes/Commands.java b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/homes/Commands.java index 9a77e5a5..99803ea7 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/homes/Commands.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/homes/Commands.java @@ -47,7 +47,7 @@ @ModuleCommand.Info(value = "homes", i18n = "homes", perm = "homes") class Commands extends ConfiguredModuleCommand { - static final CloudKey HOME_COMMAND_COOLDOWN_KEY = SimpleCloudKey.of("vanillatweaks:home_cmd_cooldown"); + static final CloudKey HOME_COMMAND_COOLDOWN_KEY = SimpleCloudKey.of("papertweaks:home_cmd_cooldown"); private final HomesDAO homesDAO; private final Config config; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/spawn/Commands.java b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/spawn/Commands.java index 8c29f33d..5c09d31b 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/spawn/Commands.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/spawn/Commands.java @@ -51,7 +51,7 @@ class Commands extends ModuleCommand { private static final CommandArgument WORLD_ARG = WorldArgument.of("world"); static final Map AWAITING_TELEPORT = Maps.newHashMap(); - static final CloudKey SPAWN_CMD_COOLDOWN_KEY = SimpleCloudKey.of("vanillatweaks:spawn_cmd_cooldown"); + static final CloudKey SPAWN_CMD_COOLDOWN_KEY = SimpleCloudKey.of("papertweaks:spawn_cmd_cooldown"); private final JavaPlugin plugin; private final Config config; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/tpa/Commands.java b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/tpa/Commands.java index 273bb07d..01e44d98 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/teleportation/tpa/Commands.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/teleportation/tpa/Commands.java @@ -45,7 +45,7 @@ @ModuleCommand.Info(value = "tpa", i18n = "tpa", perm = "tpa") class Commands extends ConfiguredModuleCommand { - static final CloudKey TPA_REQUEST_COOLDOWN_KEY = SimpleCloudKey.of("vanillatweaks:tpa_request_cmd_cooldown"); + static final CloudKey TPA_REQUEST_COOLDOWN_KEY = SimpleCloudKey.of("papertweaks:tpa_request_cmd_cooldown"); private final TPAManager tpaManager; private final Config config; diff --git a/src/main/java/me/machinemaker/papertweaks/modules/utilities/spawningspheres/Commands.java b/src/main/java/me/machinemaker/papertweaks/modules/utilities/spawningspheres/Commands.java index 1d865262..791d9280 100644 --- a/src/main/java/me/machinemaker/papertweaks/modules/utilities/spawningspheres/Commands.java +++ b/src/main/java/me/machinemaker/papertweaks/modules/utilities/spawningspheres/Commands.java @@ -48,7 +48,7 @@ @ModuleCommand.Info(value = "spawningspheres", aliases = {"spawnsphere", "ss"}, i18n = "spawning-spheres", perm = "spawningspheres") class Commands extends ConfiguredModuleCommand { - private static final PDCKey COLOR_KEY = PDCKey.enums(Keys.key("color"), Color.class); + private static final PDCKey COLOR_KEY = PDCKey.enums(Keys.legacyKey("color"), Color.class); private static final double PHI = Math.PI * (3.0 - Math.sqrt(5.0)); private static final DespawnDistances DESPAWN_DISTANCES = Services.service(DespawnDistances.Provider.class) diff --git a/src/main/java/me/machinemaker/papertweaks/settings/SettingKey.java b/src/main/java/me/machinemaker/papertweaks/settings/SettingKey.java index 3bc9c5f9..06bb114d 100644 --- a/src/main/java/me/machinemaker/papertweaks/settings/SettingKey.java +++ b/src/main/java/me/machinemaker/papertweaks/settings/SettingKey.java @@ -25,6 +25,6 @@ public record SettingKey(NamespacedKey key) { public SettingKey(final String key) { - this(Keys.key(key)); + this(Keys.legacyKey(key)); } } diff --git a/src/main/java/me/machinemaker/papertweaks/tags/Tags.java b/src/main/java/me/machinemaker/papertweaks/tags/Tags.java index 7548cd39..617894f0 100644 --- a/src/main/java/me/machinemaker/papertweaks/tags/Tags.java +++ b/src/main/java/me/machinemaker/papertweaks/tags/Tags.java @@ -63,6 +63,6 @@ private Tags() { .endsWith("_CHESTPLATE").verify(6).build(); private static MaterialTag.Builder material(String name) { - return MaterialTag.builder(Keys.key(name)); + return MaterialTag.builder(Keys.legacyKey(name)); } } diff --git a/src/main/java/me/machinemaker/papertweaks/utils/Keys.java b/src/main/java/me/machinemaker/papertweaks/utils/Keys.java index faed3b00..c83a12bf 100644 --- a/src/main/java/me/machinemaker/papertweaks/utils/Keys.java +++ b/src/main/java/me/machinemaker/papertweaks/utils/Keys.java @@ -24,11 +24,16 @@ public final class Keys { - private static final String NAMESPACE = "vanillatweaks"; + private static final String LEGACY_NAMESPACE = "vanillatweaks"; + private static final String NAMESPACE = "papertweaks"; private Keys() { } + public static NamespacedKey legacyKey(final String string) { + return new NamespacedKey(LEGACY_NAMESPACE, string); + } + public static NamespacedKey key(final String string) { return new NamespacedKey(NAMESPACE, string); } diff --git a/src/main/resources/paper-plugin.yml b/src/main/resources/paper-plugin.yml index d898fe39..ff61becd 100644 --- a/src/main/resources/paper-plugin.yml +++ b/src/main/resources/paper-plugin.yml @@ -1,11 +1,10 @@ -name: VanillaTweaks +name: PaperTweaks version: ${version} main: me.machinemaker.papertweaks.PaperTweaks api-version: "1.20" authors: - Machine_Maker description: A replacement for the VanillaTweaks datapack -prefix: PaperTweaks dependencies: server: