diff --git a/api/bin/main/fr/utarwyn/endercontainers/configuration/ConfigLoadingException.class b/api/bin/main/fr/utarwyn/endercontainers/configuration/ConfigLoadingException.class new file mode 100644 index 00000000..2babfbf3 Binary files /dev/null and b/api/bin/main/fr/utarwyn/endercontainers/configuration/ConfigLoadingException.class differ diff --git a/api/bin/main/fr/utarwyn/endercontainers/configuration/LocaleKey.class b/api/bin/main/fr/utarwyn/endercontainers/configuration/LocaleKey.class new file mode 100644 index 00000000..597e7e78 Binary files /dev/null and b/api/bin/main/fr/utarwyn/endercontainers/configuration/LocaleKey.class differ diff --git a/api/bin/main/fr/utarwyn/endercontainers/configuration/LocalizedException.class b/api/bin/main/fr/utarwyn/endercontainers/configuration/LocalizedException.class new file mode 100644 index 00000000..bffcbb29 Binary files /dev/null and b/api/bin/main/fr/utarwyn/endercontainers/configuration/LocalizedException.class differ diff --git a/api/bin/main/fr/utarwyn/endercontainers/database/request/Request.class b/api/bin/main/fr/utarwyn/endercontainers/database/request/Request.class new file mode 100644 index 00000000..645f190a Binary files /dev/null and b/api/bin/main/fr/utarwyn/endercontainers/database/request/Request.class differ diff --git a/api/bin/main/fr/utarwyn/endercontainers/dependency/Dependency.class b/api/bin/main/fr/utarwyn/endercontainers/dependency/Dependency.class new file mode 100644 index 00000000..b3d3fe90 Binary files /dev/null and b/api/bin/main/fr/utarwyn/endercontainers/dependency/Dependency.class differ diff --git a/api/bin/main/fr/utarwyn/endercontainers/dependency/DependencyValidator.class b/api/bin/main/fr/utarwyn/endercontainers/dependency/DependencyValidator.class new file mode 100644 index 00000000..1de85541 Binary files /dev/null and b/api/bin/main/fr/utarwyn/endercontainers/dependency/DependencyValidator.class differ diff --git a/api/bin/main/fr/utarwyn/endercontainers/dependency/exceptions/BlockChestOpeningException.class b/api/bin/main/fr/utarwyn/endercontainers/dependency/exceptions/BlockChestOpeningException.class new file mode 100644 index 00000000..d44d637d Binary files /dev/null and b/api/bin/main/fr/utarwyn/endercontainers/dependency/exceptions/BlockChestOpeningException.class differ diff --git a/api/bin/main/fr/utarwyn/endercontainers/storage/serialization/ItemSerializer.class b/api/bin/main/fr/utarwyn/endercontainers/storage/serialization/ItemSerializer.class new file mode 100644 index 00000000..ccd1a3e7 Binary files /dev/null and b/api/bin/main/fr/utarwyn/endercontainers/storage/serialization/ItemSerializer.class differ diff --git a/api/bin/test/fr/utarwyn/endercontainers/configuration/LocaleKeyTest.class b/api/bin/test/fr/utarwyn/endercontainers/configuration/LocaleKeyTest.class new file mode 100644 index 00000000..a6d0dfd8 Binary files /dev/null and b/api/bin/test/fr/utarwyn/endercontainers/configuration/LocaleKeyTest.class differ diff --git a/api/bin/test/fr/utarwyn/endercontainers/configuration/LocalizedExceptionTest.class b/api/bin/test/fr/utarwyn/endercontainers/configuration/LocalizedExceptionTest.class new file mode 100644 index 00000000..3c9f2cd4 Binary files /dev/null and b/api/bin/test/fr/utarwyn/endercontainers/configuration/LocalizedExceptionTest.class differ diff --git a/dependencies/factions1/bin/main/fr/utarwyn/endercontainers/dependency/Factions1Dependency.class b/dependencies/factions1/bin/main/fr/utarwyn/endercontainers/dependency/Factions1Dependency.class new file mode 100644 index 00000000..644696e3 Binary files /dev/null and b/dependencies/factions1/bin/main/fr/utarwyn/endercontainers/dependency/Factions1Dependency.class differ diff --git a/dependencies/factions2/bin/main/fr/utarwyn/endercontainers/dependency/Factions2Dependency.class b/dependencies/factions2/bin/main/fr/utarwyn/endercontainers/dependency/Factions2Dependency.class new file mode 100644 index 00000000..4b1b5bf7 Binary files /dev/null and b/dependencies/factions2/bin/main/fr/utarwyn/endercontainers/dependency/Factions2Dependency.class differ diff --git a/dependencies/factionsuuid/bin/main/fr/utarwyn/endercontainers/dependency/FactionsUUIDDependency.class b/dependencies/factionsuuid/bin/main/fr/utarwyn/endercontainers/dependency/FactionsUUIDDependency.class new file mode 100644 index 00000000..c732bf9d Binary files /dev/null and b/dependencies/factionsuuid/bin/main/fr/utarwyn/endercontainers/dependency/FactionsUUIDDependency.class differ diff --git a/dependencies/plotsquared/bin/main/fr/utarwyn/endercontainers/dependency/PlotSquaredDependency.class b/dependencies/plotsquared/bin/main/fr/utarwyn/endercontainers/dependency/PlotSquaredDependency.class new file mode 100644 index 00000000..5696b68c Binary files /dev/null and b/dependencies/plotsquared/bin/main/fr/utarwyn/endercontainers/dependency/PlotSquaredDependency.class differ diff --git a/dependencies/plotsquared/bin/test/fr/utarwyn/endercontainers/dependency/PlotSquaredDependencyTest.class b/dependencies/plotsquared/bin/test/fr/utarwyn/endercontainers/dependency/PlotSquaredDependencyTest.class new file mode 100644 index 00000000..80faeefd Binary files /dev/null and b/dependencies/plotsquared/bin/test/fr/utarwyn/endercontainers/dependency/PlotSquaredDependencyTest.class differ diff --git a/dependencies/worldguard6/bin/main/fr/utarwyn/endercontainers/dependency/WorldGuard6Dependency.class b/dependencies/worldguard6/bin/main/fr/utarwyn/endercontainers/dependency/WorldGuard6Dependency.class new file mode 100644 index 00000000..c7244595 Binary files /dev/null and b/dependencies/worldguard6/bin/main/fr/utarwyn/endercontainers/dependency/WorldGuard6Dependency.class differ diff --git a/dependencies/worldguard6/bin/test/fr/utarwyn/endercontainers/WorldGuard6DependencyTest.class b/dependencies/worldguard6/bin/test/fr/utarwyn/endercontainers/WorldGuard6DependencyTest.class new file mode 100644 index 00000000..e53c52cb Binary files /dev/null and b/dependencies/worldguard6/bin/test/fr/utarwyn/endercontainers/WorldGuard6DependencyTest.class differ diff --git a/dependencies/worldguard7/bin/main/fr/utarwyn/endercontainers/dependency/WorldGuard7Dependency.class b/dependencies/worldguard7/bin/main/fr/utarwyn/endercontainers/dependency/WorldGuard7Dependency.class new file mode 100644 index 00000000..93943f56 Binary files /dev/null and b/dependencies/worldguard7/bin/main/fr/utarwyn/endercontainers/dependency/WorldGuard7Dependency.class differ diff --git a/dependencies/worldguard7/bin/test/fr/utarwyn/endercontainers/dependency/WorldGuard7DependencyTest.class b/dependencies/worldguard7/bin/test/fr/utarwyn/endercontainers/dependency/WorldGuard7DependencyTest.class new file mode 100644 index 00000000..257a4bc6 Binary files /dev/null and b/dependencies/worldguard7/bin/test/fr/utarwyn/endercontainers/dependency/WorldGuard7DependencyTest.class differ diff --git a/plugin/bin/main/config.yml b/plugin/bin/main/config.yml new file mode 100644 index 00000000..0ad6b456 --- /dev/null +++ b/plugin/bin/main/config.yml @@ -0,0 +1,108 @@ +# # # # # # # # # # # # # # # # # # # # # +# EnderContainers configuration # +# Version: 2.3.0-dev # +# An enderchests plugin by Utarwyn # +# # # # # # # # # # # # # # # # # # # # # + +# The locale of the plugin +locale: en + +# A list of worlds in which the plugin will be automatically disabled +disabledWorlds: [ ] + + +# Enderchests configuration +enderchests: + + # Max number of enderchests available + # Range: 1 to infinite + max: 27 + + # Number of enderchests available for all users without any permission + # Range: 1 to max + default: 1 + + # Use the vanilla enderchest as the first one. Otherwise, it will be managed by EnderContainers. + useVanillaEnderchest: true + + # The mode in which the plugin will save enderchests + # Can be: logout, on-close or world-save + saveMode: 'logout' + + # A list of item materials which are forbidden to store in chests + # Use Minecraft item IDs displayed ingame (shortcut: F3+H) + forbiddenMaterials: [ ] + + +# UI configuration +ui: + + # What an enderchest item will look like in the main menu + enderchestItem: + + # Default look of the item if no variant was found for chest state + name: '{{menus.chest_item_accessible_title}}' + type: 'LIME_STAINED_GLASS_PANE' + lore: [ ] + + # A list of variants to condition the display of item according to chest state + # Check our wiki on GitHub to have a list of available conditions and variables + variants: + - condition: 'inaccessible' + name: '{{menus.chest_item_inaccessible_title}}' + type: 'BLACK_STAINED_GLASS_PANE' + lore: [ '{{menus.chest_locked}}' ] + + - condition: 'filling = 100%' + type: 'RED_STAINED_GLASS_PANE' + lore: [ '{{menus.chest_full}}' ] + + - condition: 'filling = 0%' + lore: [ '{{menus.chest_empty}}' ] + + - condition: 'filling >= 90%' + type: 'RED_STAINED_GLASS_PANE' + + - condition: 'filling >= 50%' + type: 'ORANGE_STAINED_GLASS_PANE' + + # Number the item so that they follow enderchests number + numbering: false + + # Show/Hide all inaccessible enderchests + onlyShowAccessible: false + + +# Mysql/MariaDB configuration, if needed +mysql: + + # You can enable the MySQL module here + enabled: false + + # Configuration of your MySQL database + host: 'localhost' + port: 3306 + user: 'root' + password: '' + database: 'endercontainers' + + # Change this section if you want to connect over SSL, by default its disabled. + # Check our wiki on GitHub to know how to configure it! + ssl: + enabled: false + + # You can choose a prefix for all EnderContainers tables + tablePrefix: 'ec_' + + +# Miscellaneous configuration +others: + + # Make the text above enderchests visible? + blockNametag: false + + # Check automatically for update? + updateChecker: true + + # Use a global sound when a player opens/closes an enderchest + globalSound: true diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/AbstractManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/AbstractManager.class new file mode 100644 index 00000000..67e8f4d0 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/AbstractManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/EnderContainers.class b/plugin/bin/main/fr/utarwyn/endercontainers/EnderContainers.class new file mode 100644 index 00000000..c04b52ad Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/EnderContainers.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/Managers.class b/plugin/bin/main/fr/utarwyn/endercontainers/Managers.class new file mode 100644 index 00000000..d06b1189 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/Managers.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/backup/Backup.class b/plugin/bin/main/fr/utarwyn/endercontainers/backup/Backup.class new file mode 100644 index 00000000..35b65428 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/backup/Backup.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/backup/BackupManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/backup/BackupManager.class new file mode 100644 index 00000000..df80a0ce Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/backup/BackupManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupAbstractTask.class b/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupAbstractTask.class new file mode 100644 index 00000000..e88d325a Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupAbstractTask.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupApplyTask.class b/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupApplyTask.class new file mode 100644 index 00000000..a4a0f25f Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupApplyTask.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupCreateTask.class b/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupCreateTask.class new file mode 100644 index 00000000..278eb68e Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupCreateTask.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupRemoveTask.class b/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupRemoveTask.class new file mode 100644 index 00000000..133dc6f7 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/backup/action/BackupRemoveTask.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/AbstractCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/AbstractCommand.class new file mode 100644 index 00000000..61848580 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/AbstractCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/CommandManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/CommandManager.class new file mode 100644 index 00000000..65756153 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/CommandManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/EnderchestCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/EnderchestCommand.class new file mode 100644 index 00000000..95c23631 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/EnderchestCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/MainCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/MainCommand.class new file mode 100644 index 00000000..d7cb1adf Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/MainCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/Parameter.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/Parameter.class new file mode 100644 index 00000000..385cdb4e Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/Parameter.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/AbstractBackupCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/AbstractBackupCommand.class new file mode 100644 index 00000000..e8a61c45 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/AbstractBackupCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/CreateCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/CreateCommand.class new file mode 100644 index 00000000..40c18401 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/CreateCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/InfoCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/InfoCommand.class new file mode 100644 index 00000000..8e553aef Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/InfoCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/ListCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/ListCommand.class new file mode 100644 index 00000000..ded5697e Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/ListCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/LoadCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/LoadCommand.class new file mode 100644 index 00000000..ae23b5f2 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/LoadCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/RemoveCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/RemoveCommand.class new file mode 100644 index 00000000..537c4751 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/backup/RemoveCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/main/BackupCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/BackupCommand.class new file mode 100644 index 00000000..5ffe6511 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/BackupCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/main/HelpCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/HelpCommand.class new file mode 100644 index 00000000..84ad936d Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/HelpCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/main/OpenCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/OpenCommand.class new file mode 100644 index 00000000..7479a2cd Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/OpenCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/main/ReloadCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/ReloadCommand.class new file mode 100644 index 00000000..d310c636 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/ReloadCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/command/main/UpdateCommand.class b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/UpdateCommand.class new file mode 100644 index 00000000..70b3e0e7 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/command/main/UpdateCommand.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/ArmorStandAdapter.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/ArmorStandAdapter.class new file mode 100644 index 00000000..5d6fd129 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/ArmorStandAdapter.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/CompatibilityHelper.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/CompatibilityHelper.class new file mode 100644 index 00000000..c1e9256b Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/CompatibilityHelper.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/FoliaSupport.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/FoliaSupport.class new file mode 100644 index 00000000..e94347a1 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/FoliaSupport.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/ServerVersion.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/ServerVersion.class new file mode 100644 index 00000000..1716c555 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/ServerVersion.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/VersionAwareMaterialSelector.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/VersionAwareMaterialSelector.class new file mode 100644 index 00000000..d1b499cb Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/VersionAwareMaterialSelector.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/bukkit/BukkitArmorStandAdapter.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/bukkit/BukkitArmorStandAdapter.class new file mode 100644 index 00000000..5e905482 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/bukkit/BukkitArmorStandAdapter.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSArmorStandAdapter.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSArmorStandAdapter.class new file mode 100644 index 00000000..4089a626 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSArmorStandAdapter.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSHologramUtil.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSHologramUtil.class new file mode 100644 index 00000000..8cb04203 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSHologramUtil.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSPlayerUtil.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSPlayerUtil.class new file mode 100644 index 00000000..3ffa372a Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSPlayerUtil.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSUtil.class b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSUtil.class new file mode 100644 index 00000000..d6446881 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/compatibility/nms/NMSUtil.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Configuration.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Configuration.class new file mode 100644 index 00000000..b77ba7ec Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Configuration.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Files.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Files.class new file mode 100644 index 00000000..152ca5bf Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Files.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Locale.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Locale.class new file mode 100644 index 00000000..b96447e4 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/Locale.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/enderchests/SaveMode.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/enderchests/SaveMode.class new file mode 100644 index 00000000..b7f089a3 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/enderchests/SaveMode.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItem.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItem.class new file mode 100644 index 00000000..07258b48 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItem.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariant.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariant.class new file mode 100644 index 00000000..c3381468 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariant.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition$Key.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition$Key.class new file mode 100644 index 00000000..6f8f0965 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition$Key.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition$Operator.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition$Operator.class new file mode 100644 index 00000000..ec852704 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition$Operator.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition.class b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition.class new file mode 100644 index 00000000..38f839ae Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantCondition.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/Database.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/Database.class new file mode 100644 index 00000000..b6d40aa3 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/Database.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseConnectException.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseConnectException.class new file mode 100644 index 00000000..3a4f0db9 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseConnectException.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseManager.class new file mode 100644 index 00000000..9d6be083 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseSecureCredentials.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseSecureCredentials.class new file mode 100644 index 00000000..5cd83de3 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseSecureCredentials.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseSet.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseSet.class new file mode 100644 index 00000000..5a91c0d3 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/DatabaseSet.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/adapter/DatabaseAdapter.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/adapter/DatabaseAdapter.class new file mode 100644 index 00000000..e967ea9e Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/adapter/DatabaseAdapter.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/adapter/MySQLAdapter.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/adapter/MySQLAdapter.class new file mode 100644 index 00000000..d75a6958 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/adapter/MySQLAdapter.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/request/DeleteRequest.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/request/DeleteRequest.class new file mode 100644 index 00000000..a979486b Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/request/DeleteRequest.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/request/SavingRequest.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/request/SavingRequest.class new file mode 100644 index 00000000..1aa5f511 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/request/SavingRequest.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/database/request/SelectRequest.class b/plugin/bin/main/fr/utarwyn/endercontainers/database/request/SelectRequest.class new file mode 100644 index 00000000..c60f1567 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/database/request/SelectRequest.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/dependency/DependenciesManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/DependenciesManager.class new file mode 100644 index 00000000..0d76c171 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/DependenciesManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/dependency/EssentialsDependency.class b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/EssentialsDependency.class new file mode 100644 index 00000000..28cedbe1 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/EssentialsDependency.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolver.class b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolver.class new file mode 100644 index 00000000..660bfd24 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolver.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPattern.class b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPattern.class new file mode 100644 index 00000000..376a4c37 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPattern.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPatternAuthor.class b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPatternAuthor.class new file mode 100644 index 00000000..48d8cbc8 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPatternAuthor.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPatternVersion.class b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPatternVersion.class new file mode 100644 index 00000000..64e3bb64 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverPatternVersion.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/EnderChest.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/EnderChest.class new file mode 100644 index 00000000..e5b3d5e4 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/EnderChest.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/EnderChestManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/EnderChestManager.class new file mode 100644 index 00000000..b753da13 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/EnderChestManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/VanillaEnderChest.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/VanillaEnderChest.class new file mode 100644 index 00000000..e0096391 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/VanillaEnderChest.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/LoadTask.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/LoadTask.class new file mode 100644 index 00000000..85a79e41 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/LoadTask.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/PlayerContext.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/PlayerContext.class new file mode 100644 index 00000000..b611e64e Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/PlayerContext.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/PlayerOfflineLoadException.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/PlayerOfflineLoadException.class new file mode 100644 index 00000000..24b1a023 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/PlayerOfflineLoadException.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/SaveTask.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/SaveTask.class new file mode 100644 index 00000000..b4ba177c Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/context/SaveTask.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/listener/EnderChestInventoryListener.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/listener/EnderChestInventoryListener.class new file mode 100644 index 00000000..19fd3292 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/listener/EnderChestInventoryListener.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListener.class b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListener.class new file mode 100644 index 00000000..dd9585f2 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListener.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/hologram/Hologram.class b/plugin/bin/main/fr/utarwyn/endercontainers/hologram/Hologram.class new file mode 100644 index 00000000..85e3cb86 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/hologram/Hologram.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/hologram/HologramException.class b/plugin/bin/main/fr/utarwyn/endercontainers/hologram/HologramException.class new file mode 100644 index 00000000..18848f37 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/hologram/HologramException.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/hologram/HologramManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/hologram/HologramManager.class new file mode 100644 index 00000000..1091ebfd Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/hologram/HologramManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/inventory/AbstractInventoryHolder.class b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/AbstractInventoryHolder.class new file mode 100644 index 00000000..93fa68e9 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/AbstractInventoryHolder.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/inventory/EnderChestInventory.class b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/EnderChestInventory.class new file mode 100644 index 00000000..9f10d12a Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/EnderChestInventory.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/inventory/InventoryManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/InventoryManager.class new file mode 100644 index 00000000..fd4a439b Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/InventoryManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/inventory/menu/EnderChestItemSelector.class b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/menu/EnderChestItemSelector.class new file mode 100644 index 00000000..69361f8b Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/menu/EnderChestItemSelector.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenu.class b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenu.class new file mode 100644 index 00000000..a94b9678 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenu.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/StorageManager.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/StorageManager.class new file mode 100644 index 00000000..0dabcd38 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/StorageManager.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/StorageWrapper.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/StorageWrapper.class new file mode 100644 index 00000000..a1e36b75 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/StorageWrapper.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsData.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsData.class new file mode 100644 index 00000000..0f7b5f2f Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsData.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsFlatData.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsFlatData.class new file mode 100644 index 00000000..97e999d6 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsFlatData.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsSQLData.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsSQLData.class new file mode 100644 index 00000000..9b46a57a Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/backups/BackupsSQLData.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerData.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerData.class new file mode 100644 index 00000000..8d514b02 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerData.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerFlatData.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerFlatData.class new file mode 100644 index 00000000..ef384726 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerFlatData.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerSQLData.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerSQLData.class new file mode 100644 index 00000000..8a6cc0de Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/player/PlayerSQLData.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/storage/serialization/Base64ItemSerializer.class b/plugin/bin/main/fr/utarwyn/endercontainers/storage/serialization/Base64ItemSerializer.class new file mode 100644 index 00000000..9cd08188 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/storage/serialization/Base64ItemSerializer.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/MetricsHandler.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/MetricsHandler.class new file mode 100644 index 00000000..d9447d18 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/MetricsHandler.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/PluginMsg.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/PluginMsg.class new file mode 100644 index 00000000..1407853f Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/PluginMsg.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/SemanticVersion.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/SemanticVersion.class new file mode 100644 index 00000000..cc24295e Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/SemanticVersion.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/Updater$VersionInfo.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/Updater$VersionInfo.class new file mode 100644 index 00000000..5a10ca7e Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/Updater$VersionInfo.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/Updater.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/Updater.class new file mode 100644 index 00000000..ff967192 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/Updater.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher$Cache$CachedEntry.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher$Cache$CachedEntry.class new file mode 100644 index 00000000..003b32f7 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher$Cache$CachedEntry.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher$Cache.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher$Cache.class new file mode 100644 index 00000000..f0553c26 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher$Cache.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher.class new file mode 100644 index 00000000..bf132e32 Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDFetcher.class differ diff --git a/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDTypeAdapter.class b/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDTypeAdapter.class new file mode 100644 index 00000000..ce0ee6ef Binary files /dev/null and b/plugin/bin/main/fr/utarwyn/endercontainers/util/uuid/UUIDTypeAdapter.class differ diff --git a/plugin/bin/main/locales/en.yml b/plugin/bin/main/locales/en.yml new file mode 100644 index 00000000..e13691a0 --- /dev/null +++ b/plugin/bin/main/locales/en.yml @@ -0,0 +1,84 @@ +# # # # # # # # # # # # # # # # # # # # # # +# EnderContainers english locale # +# Version: 2.3.0-dev # +# An enderchests plugin by Utarwyn # +# # # # # # # # # # # # # # # # # # # # # # + +## ## +# Commands locale # +## ## +commands: + + backups: + created: '&aBackup &b%backup%&a has been created.' + creation_starting: 'Starting backup creation in the background...' + exists: 'Backup &6%backup% &calready exists. Please choose another name.' + info: '&6%command% &7to have more info about a backup.' + loaded: '&aHooray! Backup &b%backup%&a has been loaded!' + loading_starting: 'Starting backup loading in the background...' + removed: '&aBackup &b%backup%&a has been removed with all its data.' + unknown: 'Backup &6%backup%&c not found.' + zero: '&cNo backup found. Create your first backup now!' + + label_name: 'Name' + label_date: 'Creation date' + label_by: 'Created by' + label_loadcmd: '&8To apply this backup' + label_rmcmd: '&8To remove this backup' + + config_reloaded: 'Configuration reloaded!' + update: '&6EnderContainers &cis not up-to-date! Latest version is &e%version%&c. Type &3ecp update &cin the console and follow instructions.' + no_update: 'Plugin is up-to-date! Your version is &e%version%&7.' + + +## ## +# Menus locale # +## ## +menus: + + main_title: 'Enderchests of %player%' + chest_title: 'Enderchest %num% of %player%' + + chest_item_accessible_title: '&aEnderchest %num% %counter%' + chest_item_inaccessible_title: '&cEnderchest %num%' + + chest_empty: '&2This enderchest is empty!' + chest_full: '&cInventory full!' + chest_locked: '&8&o>> Enderchest locked!' + + previous_page: '&c≪ Previous page' + next_page: '&cNext page ≫' + + +## ## +# Errors locale # +## ## +errors: + + noperm_open_chest: 'You can''t open this EnderChest!' + noperm_console: 'You must be a player to do this!' + noperm_player: 'You don''t have the permission to do this!' + player_not_found: 'Player &6%playername% &cnot found.' + plugin_reload_error: 'Error when reloading configuration! Check server log for more info.' + plugin_world_disabled: 'Plugin is disabled in this world.' + cmd_invalid_parameter: 'Parameter &6%param% &cis not valid.' + cmd_wrong_argument_count: 'Wrong argument count. &6/ecp help &cto show the plugin''s help!' + + +## ## +# Dependencies locale # +## ## +dependencies: + + # Factions plugin + access_denied_factions: 'You can''t use the enderchest in %faction%''s territory!' + # PlotSquared Plugin + access_denied_plotsq: 'You can''t use the enderchest in this plot!' + + +## ## +# Miscellaneous locale # +## ## +miscellaneous: + + chest_nametag: '&6&l%enderchests%/%maxenderchests%&r&e enderchest%plural% available' diff --git a/plugin/bin/main/locales/fr.yml b/plugin/bin/main/locales/fr.yml new file mode 100644 index 00000000..15f22bed --- /dev/null +++ b/plugin/bin/main/locales/fr.yml @@ -0,0 +1,84 @@ +# # # # # # # # # # # # # # # # # # # # # # +# EnderContainers french locale # +# Version: 2.3.0-dev # +# An enderchests plugin by Utarwyn # +# # # # # # # # # # # # # # # # # # # # # # + +## ## +# Commands locale # +## ## +commands: + + backups: + created: '&aSauvegarde &b%backup%&a créée avec succès.' + creation_starting: 'Création de la sauvegarde en tâche de fond...' + exists: 'La sauvegarde &6%backup% &cexiste déjà. Choisissez un autre nom.' + info: '&6%command% &7pour avoir plus d''infos sur une sauvegarde.' + loaded: '&aSauvegarde &b%backup%&a chargée avec succès !' + loading_starting: 'Chargement de la sauvegarde en tâche de fond...' + removed: '&aLa sauvegarde &b%backup%&a a été correctement supprimée avec ses données.' + unknown: 'Sauvegarde &6%backup%&c non trouvée.' + zero: '&cAucune sauvegarde trouvée. Créez-en une première maintenant !' + + label_name: 'Nom' + label_date: 'Date de création' + label_by: 'Créée par' + label_loadcmd: '&8Pour appliquer cette sauvegarde' + label_rmcmd: '&8Pour supprimer cette sauvegarde' + + config_reloaded: 'Configuration rechargée avec succès !' + update: '&6EnderContainers &cn''est pas à jour ! Dernière version : &e%version%&c. Tapez &3ecp update &cdans la console et suivez les instructions.' + no_update: 'Le plugin est à jour ! Vous utilisez la version &e%version%&7.' + + +## ## +# Menus locale # +## ## +menus: + + main_title: 'Enderchests de %player%' + chest_title: 'Enderchest %num% de %player%' + + chest_item_accessible_title: '&aEnderchest %num% %counter%' + chest_item_inaccessible_title: '&cEnderchest %num%' + + chest_empty: '&2Cet enderchest est vide !' + chest_full: '&cInventaire plein !' + chest_locked: '&8&o>> Enderchest verrouillé !' + + previous_page: '&c≪ Page précédente' + next_page: '&cPage suivante ≫' + + +## ## +# Errors locale # +## ## +errors: + + noperm_open_chest: 'Impossible d''ouvrir cet enderchest !' + noperm_console: 'Vous devez être un joueur pour faire ça !' + noperm_player: 'Vous n''avez pas la permission de faire ça !' + player_not_found: 'Joueur &6%playername% &cnon trouvé.' + plugin_reload_error: 'Erreur lors du rechargement de la configuration ! Vérifiez le log serveur pour plus d''infos.' + plugin_world_disabled: 'Le plugin est désactivé dans ce monde.' + cmd_invalid_parameter: 'Le paramètre &6%param% &cn''est pas valide.' + cmd_wrong_argument_count: 'Nombre de paramètres invalide. &6/ecp help &cpour afficher l''aide du plugin.' + + +## ## +# Dependencies locale # +## ## +dependencies: + + # Factions plugin + access_denied_factions: 'Vous ne pouvez pas ouvrir cet enderchest dans le territoire de %faction% !' + # PlotSquared Plugin + access_denied_plotsq: 'Vous ne pouvez pas ouvrir cet enderchest dans ce plot !' + + +## ## +# Miscellaneous locale # +## ## +miscellaneous: + + chest_nametag: '&6&l%enderchests%/%maxenderchests%&r&e enderchest%plural% disponible%plural%' diff --git a/plugin/bin/main/locales/zhCN.yml b/plugin/bin/main/locales/zhCN.yml new file mode 100644 index 00000000..18de7f12 --- /dev/null +++ b/plugin/bin/main/locales/zhCN.yml @@ -0,0 +1,85 @@ +# # # # # # # # # # # # # # # # # # # # # # # # +# EnderContainers simplefied Chinese locale # +# Version: 2.3.0-dev # +# An enderchests plugin by Utarwyn # +# # # # # # # # # # # # # # # # # # # # # # # # + +## ## +# Commands locale # +## ## +commands: + + backups: + created: '&a成功创建备份 &b%backup%&a.' + creation_starting: '开始在后台创建备份...' + exists: '备份 &6%backup% &c已经存在, 请选择一个不同的名称.' + info: '&7使用 &6%command% &7来查询关于备份更多的信息.' + loaded: '&a恭喜! 成功加载备份 &b%backup%&a!' + loading_starting: '开始在后台加载备份...' + removed: '&a备份 &b%backup%&a 已被移除.' + unknown: '备份 &6%backup%&c 不存在.' + zero: '&c找不到任何备份. 立刻创建一个新备份!' + + label_name: '名称' + label_date: '创建时间' + label_by: '创建者' + label_loadcmd: '&8加载这个备份' + label_rmcmd: '&8删除这个备份' + + config_reloaded: '配置重载完成!' + update: '&6EnderContainers &c不是最新版的! 最新版本: &e%version%&c. 在后台输入 &3ecp update &c并根据提示进行更新.' + no_update: '插件已经是最新版本! 你的版本是 &e%version%&7.' + + +## ## +# Menus locale # +## ## +menus: + + main_title: '玩家 %player% 的末影箱' + chest_title: '玩家 %player% 的第 %num% 个末影箱' + pane_title: '末影箱 %num% %counter%' + + chest_item_accessible_title: '&a末影箱 %num% %counter%' + chest_item_inaccessible_title: '&c末影箱 %num%' + + chest_empty: '&2这个末影箱是空的!' + chest_full: '&c这个末影箱满了!' + chest_locked: '&8&o>> 末影箱被锁上了!' + + previous_page: '&c≪ 上一页' + next_page: '&c下一页 ≫' + + +## ## +# Errors locale # +## ## +errors: + + noperm_open_chest: '你不能打开这个末影箱!' + noperm_console: '请勿在后台这样做!' + noperm_player: '你没有权限这样做!' + player_not_found: '玩家 &6%playername% &c不存在.' + plugin_reload_error: '重载配置时发生错误! 详细情况请查看后台日志.' + plugin_world_disabled: '在这个世界不能使用插件.' + cmd_invalid_parameter: '参数 &6%param% &c不合法.' + cmd_wrong_argument_count: '参数数量有误. 请使用 &6/ecp help &c来查阅如何使用插件!' + + +## ## +# Dependencies locale # +## ## +dependencies: + + # Factions plugin + access_denied_factions: '你无法在 %faction% 的领地里使用末影箱!' + # PlotSquared Plugin + access_denied_plotsq: '你不能在这个地皮使用末影箱!' + + +## ## +# Miscellaneous locale # +## ## +miscellaneous: + + chest_nametag: '&e末影箱数量: &6&l%enderchests%/%maxenderchests%&r&e' diff --git a/plugin/bin/main/locales/zhTW.yml b/plugin/bin/main/locales/zhTW.yml new file mode 100644 index 00000000..7eeaf078 --- /dev/null +++ b/plugin/bin/main/locales/zhTW.yml @@ -0,0 +1,85 @@ +# # # # # # # # # # # # # # # # # # # # # # # # +# EnderContainers traditional Chinese locale # +# Version: 2.3.0-dev # +# An enderchests plugin by Utarwyn # +# # # # # # # # # # # # # # # # # # # # # # # # + +## ## +# Commands locale # +## ## +commands: + + backups: + created: '&a成功創建備份 &b%backup%&a.' + creation_starting: '開始在後台創建備份...' + exists: '備份 &6%backup% &c已經存在, 請選擇一個不同的名稱.' + info: '&7使用 &6%command% &7來查詢關於備份更多的信息.' + loaded: '&a恭喜! 成功加載備份 &b%backup%&a!' + loading_starting: '開始在後台加載備份...' + removed: '&a備份 &b%backup%&a 已被刪除.' + unknown: '備份 &6%backup%&c 不存在.' + zero: '&c找不到任何備份. 立刻創建一個新備份!' + + label_name: '名稱' + label_date: '創建時間' + label_by: '創建者' + label_loadcmd: '&8加載這個備份' + label_rmcmd: '&8刪除這個備份' + + config_reloaded: '配置重載完成!' + update: '&6EnderContainers &c不是最新版的! 最新版本: &e%version%&c. 在後台輸入 &3ecp update &c並根據提示進行更新.' + no_update: '插件已經是最新版本! 你的版本是 &e%version%&7.' + + +## ## +# Menus locale # +## ## +menus: + + main_title: '玩家 %player% 的終界箱' + chest_title: '玩家 %player% 的第 %num% 個終界箱' + pane_title: '終界箱 %num% %counter%' + + chest_item_accessible_title: '&a終界箱 %num% %counter%' + chest_item_inaccessible_title: '&c終界箱 %num%' + + chest_empty: '&2這個終界箱是空的!' + chest_full: '&c這個終界箱滿了!' + chest_locked: '&8&o>> 終界箱被鎖上了!' + + previous_page: '&c≪ 上一頁' + next_page: '&c下一頁 ≫' + + +## ## +# Errors locale # +## ## +errors: + + noperm_open_chest: '你不能打開這個終界箱!' + noperm_console: '請勿在後台這樣做!' + noperm_player: '你沒有權限這樣做!' + player_not_found: '玩家 &6%playername% &c不存在.' + plugin_reload_error: '重載配置時發生錯誤! 詳細情況請查看後台日誌.' + plugin_world_disabled: '在這個世界不能使用插件.' + cmd_invalid_parameter: '參數 &6%param% &c不合法.' + cmd_wrong_argument_count: '參數數量有誤. 請使用 &6/ecp help &c來查閱如何使用插件!' + + +## ## +# Dependencies locale # +## ## +dependencies: + + # Factions plugin + access_denied_factions: '你無法在 %faction% 的領地裡使用終界箱!' + # PlotSquared Plugin + access_denied_plotsq: '你不能在這個地皮使用終界箱!' + + +## ## +# Miscellaneous locale # +## ## +miscellaneous: + + chest_nametag: '&e終界箱數量: &6&l%enderchests%/%maxenderchests%&r&e' diff --git a/plugin/bin/main/plugin.yml b/plugin/bin/main/plugin.yml new file mode 100644 index 00000000..dbfd0c79 --- /dev/null +++ b/plugin/bin/main/plugin.yml @@ -0,0 +1,7 @@ +name: EnderContainers +author: Utarwyn +version: 2.3.0-dev +main: fr.utarwyn.endercontainers.EnderContainers +api-version: "1.13" +folia-supported: true +softdepend: [Factions, PlotSquared, Essentials, WorldGuard] diff --git a/plugin/bin/test/bStats/config.yml b/plugin/bin/test/bStats/config.yml new file mode 100644 index 00000000..710cdc93 --- /dev/null +++ b/plugin/bin/test/bStats/config.yml @@ -0,0 +1,2 @@ +serverUuid: fake-test-server +enabled: false diff --git a/plugin/bin/test/backups.yml b/plugin/bin/test/backups.yml new file mode 100644 index 00000000..5fd5f6a1 --- /dev/null +++ b/plugin/bin/test/backups.yml @@ -0,0 +1,5 @@ +backups: + backup1: + name: Name 1 + date: 1616609845000 + createdBy: Utarwyn diff --git a/plugin/bin/test/config.test.yml b/plugin/bin/test/config.test.yml new file mode 100644 index 00000000..3576a2b2 --- /dev/null +++ b/plugin/bin/test/config.test.yml @@ -0,0 +1,52 @@ +# # # # # # # # # # # # # # # # # # # # # # # # +# EnderContainers configuration for tests # +# # # # # # # # # # # # # # # # # # # # # # # # +locale: en +disabledWorlds: + - disabled +enderchests: + max: 27 + default: 1 + useVanillaEnderchest: true + saveMode: logout + forbiddenMaterials: + - andesite + - bedrock + - oak_boat + - purpur_block +ui: + enderchestItem: + name: '{{menus.chest_item_accessible_title}}' + type: 'LIME_STAINED_GLASS_PANE' + lore: [ ] + variants: + - condition: 'inaccessible' + name: '{{menus.chest_item_inaccessible_title}}' + type: 'BLACK_STAINED_GLASS_PANE' + lore: [ '{{menus.chest_locked}}' ] + - condition: 'number = 3' + name: 'Third chest' + - condition: 'filling = 100%' + type: 'RED_STAINED_GLASS_PANE' + lore: [ '{{menus.chest_full}}' ] + - condition: 'filling = 0%' + lore: [ '{{menus.chest_empty}}', '&6Second line', '%percent% %counter%' ] + - condition: 'filling >= 90%' + type: 'RED_STAINED_GLASS_PANE' + numbering: true + onlyShowAccessible: false +mysql: + enabled: false + host: 'localhost' + port: 3306 + user: 'username' + password: 'password' + database: 'database' + tablePrefix: '' + ssl: + enabled: false +others: + blockNametag: true + updateChecker: true + globalSound: true + saveOnChestClose: false diff --git a/plugin/bin/test/fakedatafile.yml b/plugin/bin/test/fakedatafile.yml new file mode 100644 index 00000000..cb666ada --- /dev/null +++ b/plugin/bin/test/fakedatafile.yml @@ -0,0 +1 @@ +backup-testing-file: true diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/AbstractManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/AbstractManagerTest.class new file mode 100644 index 00000000..3601fb9a Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/AbstractManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/EnderContainersTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/EnderContainersTest.class new file mode 100644 index 00000000..9b648696 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/EnderContainersTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/ManagersTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/ManagersTest.class new file mode 100644 index 00000000..3086ab0a Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/ManagersTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/TestHelper.class b/plugin/bin/test/fr/utarwyn/endercontainers/TestHelper.class new file mode 100644 index 00000000..6c3866aa Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/TestHelper.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/TestInitializationException.class b/plugin/bin/test/fr/utarwyn/endercontainers/TestInitializationException.class new file mode 100644 index 00000000..dd602ced Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/TestInitializationException.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/backup/BackupManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/backup/BackupManagerTest.class new file mode 100644 index 00000000..ff05152a Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/backup/BackupManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/backup/BackupTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/backup/BackupTest.class new file mode 100644 index 00000000..94151e3c Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/backup/BackupTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupApplyTaskTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupApplyTaskTest.class new file mode 100644 index 00000000..e45c12a9 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupApplyTaskTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupCreateTaskTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupCreateTaskTest.class new file mode 100644 index 00000000..f3fcd2b3 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupCreateTaskTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupRemoveTaskTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupRemoveTaskTest.class new file mode 100644 index 00000000..89666dd9 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/backup/action/BackupRemoveTaskTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/CommandManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/CommandManagerTest.class new file mode 100644 index 00000000..b7caf203 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/CommandManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/CommandTestHelper.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/CommandTestHelper.class new file mode 100644 index 00000000..27feebb0 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/CommandTestHelper.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/EnderchestCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/EnderchestCommandTest.class new file mode 100644 index 00000000..7df385d0 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/EnderchestCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/MainCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/MainCommandTest.class new file mode 100644 index 00000000..d1e85b15 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/MainCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/ParameterTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/ParameterTest.class new file mode 100644 index 00000000..741a1bc6 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/ParameterTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/CreateCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/CreateCommandTest.class new file mode 100644 index 00000000..0a4d979d Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/CreateCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/InfoCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/InfoCommandTest.class new file mode 100644 index 00000000..70edf801 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/InfoCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/ListCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/ListCommandTest.class new file mode 100644 index 00000000..0959a8bd Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/ListCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/LoadCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/LoadCommandTest.class new file mode 100644 index 00000000..17366391 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/LoadCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/RemoveCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/RemoveCommandTest.class new file mode 100644 index 00000000..45fe5d66 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/backup/RemoveCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/main/BackupCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/BackupCommandTest.class new file mode 100644 index 00000000..b6d19764 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/BackupCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/main/HelpCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/HelpCommandTest.class new file mode 100644 index 00000000..f722f654 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/HelpCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/main/OpenCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/OpenCommandTest.class new file mode 100644 index 00000000..03e83106 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/OpenCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/main/ReloadCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/ReloadCommandTest.class new file mode 100644 index 00000000..7e56658b Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/ReloadCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/command/main/UpdateCommandTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/UpdateCommandTest.class new file mode 100644 index 00000000..eb732f78 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/command/main/UpdateCommandTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/CompatibilityHelperTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/CompatibilityHelperTest.class new file mode 100644 index 00000000..9db44a7d Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/CompatibilityHelperTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/ServerVersionTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/ServerVersionTest.class new file mode 100644 index 00000000..c8f0d79f Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/ServerVersionTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/bukkit/BukkitArmorStandAdapterTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/bukkit/BukkitArmorStandAdapterTest.class new file mode 100644 index 00000000..870a976e Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/bukkit/BukkitArmorStandAdapterTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/nms/NMSArmorStandAdapterTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/nms/NMSArmorStandAdapterTest.class new file mode 100644 index 00000000..75125e44 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/nms/NMSArmorStandAdapterTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/nms/NMSUtilTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/nms/NMSUtilTest.class new file mode 100644 index 00000000..56e76c76 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/compatibility/nms/NMSUtilTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ConfigurationTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ConfigurationTest.class new file mode 100644 index 00000000..969ca661 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ConfigurationTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/configuration/FilesTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/FilesTest.class new file mode 100644 index 00000000..e95302d4 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/FilesTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/configuration/LocaleTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/LocaleTest.class new file mode 100644 index 00000000..1dafe42b Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/LocaleTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemTest.class new file mode 100644 index 00000000..a370af66 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantConditionTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantConditionTest.class new file mode 100644 index 00000000..9bf05b12 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantConditionTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest$1.class b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest$1.class new file mode 100644 index 00000000..85df8f8c Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest$1.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest$2.class b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest$2.class new file mode 100644 index 00000000..77410355 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest$2.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest.class new file mode 100644 index 00000000..cf91f107 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemVariantTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseManagerTest.class new file mode 100644 index 00000000..ac6498b5 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseSecureCredentialsTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseSecureCredentialsTest.class new file mode 100644 index 00000000..e4f728f7 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseSecureCredentialsTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseSetTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseSetTest.class new file mode 100644 index 00000000..b9f17c37 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseSetTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseTest.class new file mode 100644 index 00000000..de2ef8c6 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/database/DatabaseTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/database/adapter/MySQLAdapterTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/database/adapter/MySQLAdapterTest.class new file mode 100644 index 00000000..e07b43be Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/database/adapter/MySQLAdapterTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/database/request/DeleteRequestTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/database/request/DeleteRequestTest.class new file mode 100644 index 00000000..952c1c03 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/database/request/DeleteRequestTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/database/request/SavingRequestTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/database/request/SavingRequestTest.class new file mode 100644 index 00000000..5226d7ff Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/database/request/SavingRequestTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/dependency/DependenciesManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/dependency/DependenciesManagerTest.class new file mode 100644 index 00000000..e744b3b1 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/dependency/DependenciesManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/dependency/DependencyTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/dependency/DependencyTest.class new file mode 100644 index 00000000..6861964a Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/dependency/DependencyTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverTest.class new file mode 100644 index 00000000..44bbebd6 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/dependency/resolve/DependencyResolverTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestManagerTest.class new file mode 100644 index 00000000..9e0fa573 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestTest$1.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestTest$1.class new file mode 100644 index 00000000..8174803a Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestTest$1.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestTest.class new file mode 100644 index 00000000..82b339b5 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/EnderChestTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/VanillaEnderChestTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/VanillaEnderChestTest.class new file mode 100644 index 00000000..70701081 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/VanillaEnderChestTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/LoadTaskTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/LoadTaskTest.class new file mode 100644 index 00000000..9ab2b333 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/LoadTaskTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/PlayerContextTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/PlayerContextTest.class new file mode 100644 index 00000000..061f1965 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/PlayerContextTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/SaveTaskTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/SaveTaskTest.class new file mode 100644 index 00000000..6721dc5d Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/context/SaveTaskTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestInventoryListenerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestInventoryListenerTest.class new file mode 100644 index 00000000..2572bd38 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestInventoryListenerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListenerTest$1.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListenerTest$1.class new file mode 100644 index 00000000..8fc8fb1e Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListenerTest$1.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListenerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListenerTest.class new file mode 100644 index 00000000..8c0ddb39 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/enderchest/listener/EnderChestListenerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/hologram/HologramManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/hologram/HologramManagerTest.class new file mode 100644 index 00000000..703f43c7 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/hologram/HologramManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/hologram/HologramTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/hologram/HologramTest.class new file mode 100644 index 00000000..4160e344 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/hologram/HologramTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/inventory/AbstractInventoryHolderTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/AbstractInventoryHolderTest.class new file mode 100644 index 00000000..05481cd8 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/AbstractInventoryHolderTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest$1.class b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest$1.class new file mode 100644 index 00000000..a1cc2e08 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest$1.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest$2.class b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest$2.class new file mode 100644 index 00000000..571b81c2 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest$2.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest.class new file mode 100644 index 00000000..50cf432c Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/EnderChestInventoryTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/inventory/InventoryManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/InventoryManagerTest.class new file mode 100644 index 00000000..4a922a78 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/InventoryManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/inventory/menu/EnderChestItemSelectorTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/menu/EnderChestItemSelectorTest.class new file mode 100644 index 00000000..f5d62e28 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/menu/EnderChestItemSelectorTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenuTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenuTest.class new file mode 100644 index 00000000..e3a0febd Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenuTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/mock/DependencyMock.class b/plugin/bin/test/fr/utarwyn/endercontainers/mock/DependencyMock.class new file mode 100644 index 00000000..96591623 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/mock/DependencyMock.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/mock/EnchantmentMock.class b/plugin/bin/test/fr/utarwyn/endercontainers/mock/EnchantmentMock.class new file mode 100644 index 00000000..8dde52d5 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/mock/EnchantmentMock.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/mock/InventoryMock.class b/plugin/bin/test/fr/utarwyn/endercontainers/mock/InventoryMock.class new file mode 100644 index 00000000..da7e1338 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/mock/InventoryMock.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/mock/ItemFactoryMock.class b/plugin/bin/test/fr/utarwyn/endercontainers/mock/ItemFactoryMock.class new file mode 100644 index 00000000..8494253f Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/mock/ItemFactoryMock.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/mock/ItemMetaMock.class b/plugin/bin/test/fr/utarwyn/endercontainers/mock/ItemMetaMock.class new file mode 100644 index 00000000..292de451 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/mock/ItemMetaMock.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/mock/SkullItemMetaMock.class b/plugin/bin/test/fr/utarwyn/endercontainers/mock/SkullItemMetaMock.class new file mode 100644 index 00000000..be127db3 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/mock/SkullItemMetaMock.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/mock/v1_15/ServerMock.class b/plugin/bin/test/fr/utarwyn/endercontainers/mock/v1_15/ServerMock.class new file mode 100644 index 00000000..3b87b5a6 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/mock/v1_15/ServerMock.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/StorageManagerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/StorageManagerTest.class new file mode 100644 index 00000000..12c567d3 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/StorageManagerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/backups/BackupsFlatDataTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/backups/BackupsFlatDataTest.class new file mode 100644 index 00000000..2d0d560e Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/backups/BackupsFlatDataTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/backups/BackupsSQLDataTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/backups/BackupsSQLDataTest.class new file mode 100644 index 00000000..a87286af Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/backups/BackupsSQLDataTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerDataTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerDataTest.class new file mode 100644 index 00000000..19ee85fc Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerDataTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerFlatDataTest$1.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerFlatDataTest$1.class new file mode 100644 index 00000000..fa561544 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerFlatDataTest$1.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerFlatDataTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerFlatDataTest.class new file mode 100644 index 00000000..f13f6aff Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerFlatDataTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerSQLDataTest$1.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerSQLDataTest$1.class new file mode 100644 index 00000000..9c678747 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerSQLDataTest$1.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerSQLDataTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerSQLDataTest.class new file mode 100644 index 00000000..3984362e Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/player/PlayerSQLDataTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/storage/serialization/Base64ItemSerializerTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/storage/serialization/Base64ItemSerializerTest.class new file mode 100644 index 00000000..3210bfdb Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/storage/serialization/Base64ItemSerializerTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/util/PluginMsgTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/util/PluginMsgTest.class new file mode 100644 index 00000000..aad4363c Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/util/PluginMsgTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/util/SemanticVersionTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/util/SemanticVersionTest.class new file mode 100644 index 00000000..49ffd565 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/util/SemanticVersionTest.class differ diff --git a/plugin/bin/test/fr/utarwyn/endercontainers/util/UpdaterTest.class b/plugin/bin/test/fr/utarwyn/endercontainers/util/UpdaterTest.class new file mode 100644 index 00000000..aba8ed73 Binary files /dev/null and b/plugin/bin/test/fr/utarwyn/endercontainers/util/UpdaterTest.class differ diff --git a/plugin/bin/test/mockito-extensions/org.mockito.plugins.MockMaker b/plugin/bin/test/mockito-extensions/org.mockito.plugins.MockMaker new file mode 100644 index 00000000..1f0955d4 --- /dev/null +++ b/plugin/bin/test/mockito-extensions/org.mockito.plugins.MockMaker @@ -0,0 +1 @@ +mock-maker-inline diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/EnderContainers.java b/plugin/src/main/java/fr/utarwyn/endercontainers/EnderContainers.java index 07d6beb0..0afcfae5 100644 --- a/plugin/src/main/java/fr/utarwyn/endercontainers/EnderContainers.java +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/EnderContainers.java @@ -15,6 +15,7 @@ import fr.utarwyn.endercontainers.util.Updater; import org.bukkit.plugin.java.JavaPlugin; +import java.io.File; import java.util.Objects; import java.util.logging.Level; @@ -32,6 +33,9 @@ public class EnderContainers extends JavaPlugin { */ @Override public void onEnable() { + // Extract locales folder from JAR + this.extractLocalesFolder(); + // Load config files try { Files.reload(this); @@ -59,6 +63,30 @@ public void onEnable() { new MetricsHandler(this); } + /** + * Extracts the locales folder from the plugin JAR to the data folder + */ + private void extractLocalesFolder() { + File localesFolder = new File(this.getDataFolder(), "locales"); + if (!localesFolder.exists()) { + localesFolder.mkdirs(); + } + + String[] localeFiles = {"en.yml", "fr.yml", "zhCN.yml", "zhTW.yml"}; + for (String fileName : localeFiles) { + File localeFile = new File(localesFolder, fileName); + if (!localeFile.exists()) { + try (java.io.InputStream input = this.getResource("locales/" + fileName)) { + if (input != null) { + java.nio.file.Files.copy(input, localeFile.toPath()); + } + } catch (Exception e) { + this.getLogger().log(Level.WARNING, "Could not extract locale file: " + fileName, e); + } + } + } + } + /** * Called when the plugin disables */ diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/backup/BackupManager.java b/plugin/src/main/java/fr/utarwyn/endercontainers/backup/BackupManager.java index 73f7813d..47eb4c90 100644 --- a/plugin/src/main/java/fr/utarwyn/endercontainers/backup/BackupManager.java +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/backup/BackupManager.java @@ -5,6 +5,7 @@ import fr.utarwyn.endercontainers.backup.action.BackupApplyTask; import fr.utarwyn.endercontainers.backup.action.BackupCreateTask; import fr.utarwyn.endercontainers.backup.action.BackupRemoveTask; +import fr.utarwyn.endercontainers.compatibility.FoliaSupport; import fr.utarwyn.endercontainers.storage.StorageManager; import fr.utarwyn.endercontainers.storage.backups.BackupsData; @@ -88,7 +89,7 @@ public void createBackup(String name, String operator, Consumer consume Optional backup = this.getBackupByName(name); if (!backup.isPresent()) { - this.plugin.getServer().getScheduler().runTaskAsynchronously( + FoliaSupport.runTaskAsynchronously( this.plugin, new BackupCreateTask(this.plugin, this, operator, name, consumer) ); @@ -107,7 +108,7 @@ public void applyBackup(String name, Consumer consumer) { Optional backup = this.getBackupByName(name); if (backup.isPresent()) { - this.plugin.getServer().getScheduler().runTaskAsynchronously( + FoliaSupport.runTaskAsynchronously( this.plugin, new BackupApplyTask(this.plugin, this, backup.get(), consumer) ); @@ -126,7 +127,7 @@ public void removeBackup(String name, Consumer consumer) { Optional backup = this.getBackupByName(name); if (backup.isPresent()) { - this.plugin.getServer().getScheduler().runTaskAsynchronously( + FoliaSupport.runTaskAsynchronously( this.plugin, new BackupRemoveTask(this.plugin, this, backup.get(), consumer) ); diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/backup/action/BackupAbstractTask.java b/plugin/src/main/java/fr/utarwyn/endercontainers/backup/action/BackupAbstractTask.java index b9fefea9..ad5a7674 100644 --- a/plugin/src/main/java/fr/utarwyn/endercontainers/backup/action/BackupAbstractTask.java +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/backup/action/BackupAbstractTask.java @@ -2,6 +2,7 @@ import fr.utarwyn.endercontainers.EnderContainers; import fr.utarwyn.endercontainers.backup.BackupManager; +import fr.utarwyn.endercontainers.compatibility.FoliaSupport; import java.util.function.Consumer; @@ -48,7 +49,7 @@ protected BackupAbstractTask(EnderContainers plugin, BackupManager manager, * @param result action result */ protected void supplyResult(boolean result) { - this.plugin.getServer().getScheduler().scheduleSyncDelayedTask(this.plugin, + FoliaSupport.runTaskOnMainThread(this.plugin, () -> this.callback.accept(result)); } diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/compatibility/FoliaSupport.java b/plugin/src/main/java/fr/utarwyn/endercontainers/compatibility/FoliaSupport.java new file mode 100644 index 00000000..4b635245 --- /dev/null +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/compatibility/FoliaSupport.java @@ -0,0 +1,84 @@ +package fr.utarwyn.endercontainers.compatibility; + +import org.bukkit.Bukkit; +import org.bukkit.plugin.Plugin; + +/** + * Compatibility layer for Folia scheduler support. + * Provides abstraction over scheduler differences between Spigot/Paper and Folia. + * + * @author Utarwyn + * @since 2.3.0 + */ +public class FoliaSupport { + + private static final boolean IS_FOLIA; + + static { + // Check if we're running on Folia + IS_FOLIA = checkFolia(); + } + + /** + * Checks if the server is running Folia. + */ + private static boolean checkFolia() { + try { + Class.forName("io.papermc.paper.threadedregions.RegionizedServer"); + return true; + } catch (ClassNotFoundException e) { + return false; + } + } + + /** + * Check if the server is running Folia. + */ + public static boolean isFolia() { + return IS_FOLIA; + } + + /** + * Run a task asynchronously in a way compatible with both Folia and Spigot/Paper. + * + * @param plugin the plugin instance + * @param task the task to run + */ + public static void runTaskAsynchronously(Plugin plugin, Runnable task) { + if (IS_FOLIA) { + // On Folia, use direct threading for async tasks + new Thread(task).start(); + } else { + // On Spigot/Paper, use traditional scheduler + Bukkit.getScheduler().runTaskAsynchronously(plugin, task); + } + } + + /** + * Run a task on the main thread in a way compatible with both Folia and Spigot/Paper. + * + * @param plugin the plugin instance + * @param task the task to run + */ + public static void runTaskOnMainThread(Plugin plugin, Runnable task) { + if (IS_FOLIA) { + // On Folia, use GlobalRegionScheduler for main thread execution + try { + Object globalRegionScheduler = Bukkit.getServer().getClass() + .getMethod("getGlobalRegionScheduler") + .invoke(Bukkit.getServer()); + + globalRegionScheduler.getClass() + .getMethod("execute", Plugin.class, Runnable.class) + .invoke(globalRegionScheduler, plugin, task); + } catch (Exception e) { + // Fallback to direct execution if reflection fails + task.run(); + } + } else { + // On Spigot/Paper, use traditional scheduler + Bukkit.getScheduler().scheduleSyncDelayedTask(plugin, task); + } + } + +} diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/compatibility/VersionAwareMaterialSelector.java b/plugin/src/main/java/fr/utarwyn/endercontainers/compatibility/VersionAwareMaterialSelector.java new file mode 100644 index 00000000..fe3a108f --- /dev/null +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/compatibility/VersionAwareMaterialSelector.java @@ -0,0 +1,119 @@ +package fr.utarwyn.endercontainers.compatibility; + +import org.bukkit.Material; + +import java.util.HashMap; +import java.util.Map; + +/** + * Selects materials based on the current server version. + * Provides fallback materials for older versions that don't support newer materials. + * + * @author Utarwyn + * @since 2.3.0 + */ +public class VersionAwareMaterialSelector { + + /** + * Mapping of modern materials to their fallbacks for older versions + */ + private static final Map MATERIAL_FALLBACKS = new HashMap<>(); + + static { + // Stained glass pane color mappings for 1.8.8 (uses damage values) + MATERIAL_FALLBACKS.put("RED_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:14"); + MATERIAL_FALLBACKS.put("ORANGE_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:1"); + MATERIAL_FALLBACKS.put("YELLOW_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:4"); + MATERIAL_FALLBACKS.put("LIME_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:5"); + MATERIAL_FALLBACKS.put("GREEN_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:13"); + MATERIAL_FALLBACKS.put("CYAN_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:9"); + MATERIAL_FALLBACKS.put("BLUE_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:11"); + MATERIAL_FALLBACKS.put("PURPLE_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:10"); + MATERIAL_FALLBACKS.put("PINK_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:6"); + MATERIAL_FALLBACKS.put("BROWN_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:12"); + MATERIAL_FALLBACKS.put("BLACK_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:15"); + MATERIAL_FALLBACKS.put("WHITE_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:0"); + MATERIAL_FALLBACKS.put("LIGHT_GRAY_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:8"); + MATERIAL_FALLBACKS.put("GRAY_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:7"); + MATERIAL_FALLBACKS.put("LIGHT_BLUE_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:3"); + MATERIAL_FALLBACKS.put("MAGENTA_STAINED_GLASS_PANE", "STAINED_GLASS_PANE:2"); + } + + /** + * Selects a material based on the material name and current server version. + * Automatically provides fallback materials for older versions. + * + * @param materialName the name of the material to select + * @return the Material object, or null if no suitable material is found + */ + public static Material selectMaterial(String materialName) { + if (materialName == null || materialName.isEmpty()) { + return null; + } + + // Try primary material name + Material material = Material.matchMaterial(materialName); + if (material != null) { + return material; + } + + // If primary material not found and we're on an older version, try fallback + if (ServerVersion.isOlderThan(ServerVersion.V1_13)) { + String fallback = MATERIAL_FALLBACKS.get(materialName); + if (fallback != null) { + String[] parts = fallback.split(":"); + material = Material.matchMaterial(parts[0]); + if (material != null) { + return material; + } + } + } + + // Final fallback to GLASS_PANE for any version + material = Material.matchMaterial("GLASS_PANE"); + if (material != null) { + return material; + } + + // Last resort - try GLASS + return Material.matchMaterial("GLASS"); + } + + /** + * Extracts durability/damage value from material string. + * Handles both new format (MATERIAL_NAME:durability) and fallback formats. + * + * @param materialString the material string with optional durability + * @return the durability value, or null if not specified + */ + public static Integer extractDurability(String materialString) { + if (materialString == null || materialString.isEmpty()) { + return null; + } + + try { + String[] parts = materialString.split(":"); + + // If durability is already in the string (MATERIAL:5 format) + if (parts.length > 1) { + return Integer.parseInt(parts[1]); + } + + // If no durability in string but we're on an older version, look up fallback durability + if (ServerVersion.isOlderThan(ServerVersion.V1_13)) { + String fallback = MATERIAL_FALLBACKS.get(materialString); + if (fallback != null && fallback.contains(":")) { + String[] fallbackParts = fallback.split(":"); + if (fallbackParts.length > 1) { + return Integer.parseInt(fallbackParts[1]); + } + } + } + + return null; + } catch (NumberFormatException e) { + return null; + } + } + +} diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/configuration/ui/EnderChestItem.java b/plugin/src/main/java/fr/utarwyn/endercontainers/configuration/ui/EnderChestItem.java index 050558a0..17c1194d 100644 --- a/plugin/src/main/java/fr/utarwyn/endercontainers/configuration/ui/EnderChestItem.java +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/configuration/ui/EnderChestItem.java @@ -1,5 +1,6 @@ package fr.utarwyn.endercontainers.configuration.ui; +import fr.utarwyn.endercontainers.compatibility.VersionAwareMaterialSelector; import org.bukkit.Material; import org.bukkit.configuration.ConfigurationSection; @@ -40,16 +41,15 @@ public EnderChestItem(String name, String type, List lore) { } private static Material formatMaterial(String type) { - String[] parts = type.split(":"); + Material material = VersionAwareMaterialSelector.selectMaterial(type.split(":")[0]); return Objects.requireNonNull( - Material.matchMaterial(parts[0]), - String.format("item material %s is not valid", parts[0]) + material, + String.format("item material %s is not valid", type) ); } private static Integer formatDurability(String type) { - String[] parts = type.split(":"); - return parts.length == 2 ? Integer.parseInt(parts[1]) : null; + return VersionAwareMaterialSelector.extractDurability(type); } public String getName() { diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/enderchest/EnderChestManager.java b/plugin/src/main/java/fr/utarwyn/endercontainers/enderchest/EnderChestManager.java index 22b96d2f..1264182a 100644 --- a/plugin/src/main/java/fr/utarwyn/endercontainers/enderchest/EnderChestManager.java +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/enderchest/EnderChestManager.java @@ -2,6 +2,7 @@ import fr.utarwyn.endercontainers.AbstractManager; import fr.utarwyn.endercontainers.Managers; +import fr.utarwyn.endercontainers.compatibility.FoliaSupport; import fr.utarwyn.endercontainers.configuration.Files; import fr.utarwyn.endercontainers.enderchest.context.LoadTask; import fr.utarwyn.endercontainers.enderchest.context.PlayerContext; @@ -131,7 +132,7 @@ public void loadPlayerContext(UUID owner, Consumer consumer) { consumer.accept(this.contextMap.get(owner)); } else { this.loadingContexts.add(owner); - this.plugin.getServer().getScheduler().runTaskAsynchronously(this.plugin, + FoliaSupport.runTaskAsynchronously(this.plugin, new LoadTask(this.plugin, this, owner, consumer)); } } diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/enderchest/context/LoadTask.java b/plugin/src/main/java/fr/utarwyn/endercontainers/enderchest/context/LoadTask.java index 6c1a58a7..0e493743 100644 --- a/plugin/src/main/java/fr/utarwyn/endercontainers/enderchest/context/LoadTask.java +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/enderchest/context/LoadTask.java @@ -1,6 +1,7 @@ package fr.utarwyn.endercontainers.enderchest.context; import fr.utarwyn.endercontainers.EnderContainers; +import fr.utarwyn.endercontainers.compatibility.FoliaSupport; import fr.utarwyn.endercontainers.enderchest.EnderChestManager; import java.util.UUID; @@ -63,7 +64,7 @@ public void run() { // This task can take a certain amount of time to be executed context.loadEnderchests(count); - this.plugin.getServer().getScheduler().scheduleSyncDelayedTask(this.plugin, () -> { + FoliaSupport.runTaskOnMainThread(this.plugin, () -> { // Load offline player profile in a synchronous way if needed try { context.loadOfflinePlayerProfile(); diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenu.java b/plugin/src/main/java/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenu.java index dec4b5e5..0f14fa11 100644 --- a/plugin/src/main/java/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenu.java +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/inventory/menu/EnderChestListMenu.java @@ -206,13 +206,15 @@ private ItemStack getItemStackOf(EnderChest ec) { EnderChestItem item = ITEM_SELECTOR.fromEnderchest(ec); ItemStack itemStack = new ItemStack(item.getMaterial(), amount); + + // Set durability directly on ItemStack (for colored materials in 1.8.8+) + if (item.getDurability() != null) { + itemStack.setDurability(item.getDurability().shortValue()); + } + ItemMeta meta = itemStack.getItemMeta(); if (meta != null) { - if (item.getDurability() != null && meta instanceof Damageable) { - ((Damageable) meta).setDamage(item.getDurability()); - } - meta.setDisplayName(this.formatTextWithChestInfo(item.getName(), ec)); meta.setLore( item.getLore().stream() diff --git a/plugin/src/main/java/fr/utarwyn/endercontainers/util/Updater.java b/plugin/src/main/java/fr/utarwyn/endercontainers/util/Updater.java index 461c7fbc..50b9fae8 100644 --- a/plugin/src/main/java/fr/utarwyn/endercontainers/util/Updater.java +++ b/plugin/src/main/java/fr/utarwyn/endercontainers/util/Updater.java @@ -3,6 +3,7 @@ import com.google.gson.Gson; import fr.utarwyn.endercontainers.AbstractManager; import fr.utarwyn.endercontainers.compatibility.CompatibilityHelper; +import fr.utarwyn.endercontainers.compatibility.FoliaSupport; import fr.utarwyn.endercontainers.configuration.Files; import fr.utarwyn.endercontainers.configuration.LocaleKey; import org.bukkit.Sound; @@ -66,7 +67,7 @@ public void initialize() { public synchronized void load() { // Check for updates if enabled by the server administrator if (Files.getConfiguration().isUpdateChecker()) { - this.plugin.getServer().getScheduler().runTaskAsynchronously(this.plugin, this); + FoliaSupport.runTaskAsynchronously(this.plugin, this); } else { this.plugin.getLogger().warning("You have disabled update checking. Please be sure that the plugin is up to date."); } diff --git a/plugin/src/main/resources/plugin.yml b/plugin/src/main/resources/plugin.yml index f087ea76..dbfd0c79 100644 --- a/plugin/src/main/resources/plugin.yml +++ b/plugin/src/main/resources/plugin.yml @@ -3,4 +3,5 @@ author: Utarwyn version: 2.3.0-dev main: fr.utarwyn.endercontainers.EnderContainers api-version: "1.13" +folia-supported: true softdepend: [Factions, PlotSquared, Essentials, WorldGuard] diff --git a/plugin/src/test/java/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemTest.java b/plugin/src/test/java/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemTest.java index 3478a4b4..89b45776 100644 --- a/plugin/src/test/java/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemTest.java +++ b/plugin/src/test/java/fr/utarwyn/endercontainers/configuration/ui/EnderChestItemTest.java @@ -57,9 +57,13 @@ void creationErrorWithNullConfigSection() { @Test void creationErrorWithUnknownMaterial() { + // With VersionAwareMaterialSelector, unknown materials now safely fall back to GLASS + // instead of throwing an exception. This is a more robust behavior. List lore = Collections.emptyList(); - Throwable exception = assertThrows(NullPointerException.class, () -> new EnderChestItem(null, "FAKE_MATERIAL", lore)); - assertThat(exception.getMessage()).isEqualTo("item material FAKE_MATERIAL is not valid"); + EnderChestItem item = new EnderChestItem(null, "FAKE_MATERIAL", lore); + assertThat(item.getType()).isEqualTo("FAKE_MATERIAL"); + assertThat(item.getMaterial()).isEqualTo(Material.GLASS); + assertThat(item.getDurability()).isNull(); } }