From 1d350ce98ddfb862975f1d14943bda52c3538b06 Mon Sep 17 00:00:00 2001 From: XiaoMoMi <70987828+Xiao-MoMi@users.noreply.github.com> Date: Fri, 6 Sep 2024 01:12:53 +0800 Subject: [PATCH] Update default configs --- .../mechanic/fertilizer/FertilizerConfig.java | 3 +- .../common/locale/TranslationManager.java | 2 +- .../customcrops/bukkit/config/ConfigType.java | 2 +- plugin/src/main/resources/config.yml | 140 +++++++++--------- .../main/resources/contents/crops/default.yml | 67 +++++---- .../contents/fertilizers/default.yml | 25 ++-- .../main/resources/contents/pots/default.yml | 79 +++++----- .../resources/contents/sprinklers/default.yml | 66 +++++---- .../contents/watering-cans/default.yml | 99 ++++++------- 9 files changed, 254 insertions(+), 229 deletions(-) diff --git a/api/src/main/java/net/momirealms/customcrops/api/core/mechanic/fertilizer/FertilizerConfig.java b/api/src/main/java/net/momirealms/customcrops/api/core/mechanic/fertilizer/FertilizerConfig.java index 27c3793..5c7a2ed 100644 --- a/api/src/main/java/net/momirealms/customcrops/api/core/mechanic/fertilizer/FertilizerConfig.java +++ b/api/src/main/java/net/momirealms/customcrops/api/core/mechanic/fertilizer/FertilizerConfig.java @@ -144,6 +144,5 @@ public interface FertilizerConfig { * * @return An array of doubles representing the quality ratio override, or null if not applicable. */ - @Nullable - double[] overrideQualityRatio(); + double @Nullable [] overrideQualityRatio(); } \ No newline at end of file diff --git a/common/src/main/java/net/momirealms/customcrops/common/locale/TranslationManager.java b/common/src/main/java/net/momirealms/customcrops/common/locale/TranslationManager.java index f385ae6..28fa0f2 100644 --- a/common/src/main/java/net/momirealms/customcrops/common/locale/TranslationManager.java +++ b/common/src/main/java/net/momirealms/customcrops/common/locale/TranslationManager.java @@ -144,7 +144,7 @@ public class TranslationManager { }); Locale localLocale = Locale.getDefault(); - if (!this.installed.contains(localLocale)) { + if (!this.installed.contains(localLocale) && FORCE_LOCALE == null) { plugin.getPluginLogger().warn(localLocale.toString().toLowerCase(Locale.ENGLISH) + ".yml not exists, using en.yml as default locale."); } } diff --git a/plugin/src/main/java/net/momirealms/customcrops/bukkit/config/ConfigType.java b/plugin/src/main/java/net/momirealms/customcrops/bukkit/config/ConfigType.java index 7e98e3c..a4d75dc 100644 --- a/plugin/src/main/java/net/momirealms/customcrops/bukkit/config/ConfigType.java +++ b/plugin/src/main/java/net/momirealms/customcrops/bukkit/config/ConfigType.java @@ -283,7 +283,7 @@ public class ConfigType { .threeDItemWithWater(section.getString("3D-item-with-water")) .wateringMethods(manager.getWateringMethods(section.getSection("fill-method"))) .potWhitelist(new HashSet<>(section.getStringList("pot-whitelist"))) - .existenceForm(CustomForm.valueOf(section.getString("type", "ITEM_FRAME").toUpperCase(Locale.ENGLISH)).existenceForm()) + .existenceForm(CustomForm.valueOf(section.getString("type", "FURNITURE").toUpperCase(Locale.ENGLISH)).existenceForm()) .addWaterActions(pam.parseActions(section.getSection("events.add_water"))) .breakActions(pam.parseActions(section.getSection("events.break"))) .placeActions(pam.parseActions(section.getSection("events.place"))) diff --git a/plugin/src/main/resources/config.yml b/plugin/src/main/resources/config.yml index a05519f..57a0df6 100644 --- a/plugin/src/main/resources/config.yml +++ b/plugin/src/main/resources/config.yml @@ -1,88 +1,85 @@ -# Don't change +# Do not change this value config-version: '${config_version}' -# Debug +# Enable or disable debugging mode debug: false -# BStats +# Enable or disable metrics collection using BStats metrics: true -# Check updates +# Enable automatic update checks update-checker: true -# Force locale, for instance zh_cn +# Force the locale (e.g., zh_cn) force-locale: '' # World settings worlds: - # Some servers use separate folders to store player worlds, and these world directories - # are often not located in the server's root directory. This option allows users to read - # world data from a custom directory. It is only applicable to Bukkit worlds. + # Some servers use separate directories for player worlds, which may not be in the server's root directory. + # This option allows you to specify a custom path to these world folders. This is only applicable for Bukkit worlds. absolute-world-folder-path: '' - # A list of worlds that would decide where the plugin mechanisms take effect - # Mode: whitelist/blacklist/regex + # Specifies which worlds the plugin's mechanisms should apply to + # Options: whitelist/blacklist/regex mode: blacklist list: - - blacklist_world # A non-existent world + - blacklist_world # A world that doesn't exist settings: # Default settings that apply to all worlds _DEFAULT_: - # Whether to enable the plugin's pre-made system - # Disabling this option will make all mechanisms stop counting ticks unless you have full control over it using the API. - # If you don't know how to code with CustomCropsAPI, just keep it true, because it is enough to meet the needs of 99% of users. + # Whether to enable the plugin's pre-configured systems + # Disabling this stops all mechanisms from ticking unless fully managed via the API. + # If you're not familiar with using CustomCropsAPI, keep this set to true as it meets the needs of 99% of users. enable: true - # Season mechanisms + # Seasonal settings season: enable: true - # Enable automatic seasonal change + # Automatically cycle through seasons auto-alternation: true - # Game days of each season + # Duration of each season in game days duration: 28 - # It's different from the vanilla RandomTickSpeed. - # "Random tick" here refers to the process of randomly selecting n blocks within a 16x16x16 section every second to perform a tick while Minecraft do that every tick. - # Therefore, the random tick of CustomCrops has little impact on the server, and it is performed on multiple threads. + # This is different from the vanilla RandomTickSpeed. + # "Random tick" here means randomly selecting n blocks within a 16x16x16 section every second for ticking, unlike Minecraft's per-tick approach. + # Therefore, CustomCrops' random ticks have minimal impact on the server and run on multiple threads. random-tick-speed: 20 - # The smallest tick unit in seconds used in scheduled tick mode - # 300s means that a crop would be certainly ticked once in 300s - # For crops, under the same conditions, the growth rate of crops is basically the same - # For sprinklers and pots, they would work periodically. + # The minimum tick interval in seconds when using scheduled tick mode + # A value of 180s means a crop is guaranteed to tick at least once every 180 seconds + # For crops, growth rates are nearly uniform under the same conditions + # Sprinklers and pots operate periodically within this interval. min-tick-unit: 180 - # Offline tick settings - # This option allows crops to grow even if the world is unloaded or the server is closed - # This may lead to some issues caused by timeliness conditions for instance seasons + # Settings for ticking while the world is offline + # Allows crops to grow even if the world is unloaded or the server is down + # This might cause issues with time-dependent conditions like seasons offline-tick: enable: false # Maximum offline time recorded in seconds - # Please do not set this option to a value that is too large, - # as it may cause chunks that have been unloaded for a long time - # taking long to load + # Avoid setting this too high, as it may cause long-unloaded chunks to take a long time to load max-offline-seconds: 1200 - # The max time used in loading this chunk - # Sometimes a chunk might contain a lot of data and has not been loaded for a long time, - # thus taking a long time loading and causing unexpected issues - # This setting allows the plugin to forcefully interrupt the tick process if the time consumed has exceeded a certain value + # Maximum time allowed for loading a chunk + # Sometimes, chunks with large amounts of data that have been unloaded for a long time can take a while to load, + # potentially causing unexpected issues + # This setting allows the plugin to forcibly interrupt the tick process if loading time exceeds a set threshold max-loading-time: 100 #ms - # Settings for crops + # Crop settings crop: # [RANDOM_TICK] - # Random tick mode is similar to the vanilla one where crops grow randomly - # Due to randomness, crops grown under the same conditions may have significant stage differences + # Random tick mode mirrors vanilla behavior, where crops grow randomly + # This randomness can cause significant stage differences among crops grown under identical conditions # [SCHEDULED_TICK] - # Scheduler mode provides more reliable growth schedule management - # which allows crops to grow at almost the same speed + # Scheduled tick mode provides more predictable growth management, + # ensuring crops grow at nearly the same rate mode: RANDOM_TICK - # The tick-interval determines how many times a block is ticked before its tick logic is actually executed. + # Tick interval determines how many times a block is ticked before its logic is executed tick-interval: 1 - # Limit the max amount of crops in one chunk (-1 = no limit) + # Limit the number of crops per chunk (-1 means no limit) max-per-chunk: -1 - # Settings for pots + # Pot settings pot: - # RANDOM_TICK / SCHEDULED_TICK + # RANDOM_TICK or SCHEDULED_TICK mode: SCHEDULED_TICK tick-interval: 3 max-per-chunk: -1 - # Settings for sprinklers + # Sprinkler settings sprinkler: - # RANDOM_TICK / SCHEDULED_TICK + # RANDOM_TICK or SCHEDULED_TICK mode: SCHEDULED_TICK tick-interval: 2 max-per-chunk: -1 - # You can override the default settings for worlds here + # Override default settings for specific worlds here _WORLDS_: world_nether: enable: false @@ -90,56 +87,57 @@ worlds: enable: false # Mechanics settings mechanics: - # You can create more ranks by adding more "/" for instance x/x/x/x/x - # "x" is weight, represents the proportion of probability + # Create additional ranks by adding more slashes, e.g., x/x/x/x/x + # "x" represents weight, which determines the probability proportion # 17/2/1 = 85%/10%/5% - # 85% = 17/(17+2+1) * 100% + # 85% is calculated as 17/(17+2+1) * 100% default-quality-ratio: 17/2/1 - # Scarecrow prevents crops from being attacked by crows + # Scarecrow settings to prevent crops from being attacked by crows scarecrow: enable: true id: '{0}scarecrow' type: ITEM_FRAME range: 7 - # If this option is enabled, the range would no longer take effect - # This option would make it protect all the crops in the same chunk + # If enabled, the scarecrow's range will not be limited + # It will protect all crops within the same chunk protect-chunk: false - # Greenhouse glass prevents crops from withering from season changing + # Greenhouse glass prevents crops from withering due to seasonal changes greenhouse: enable: true - # You can use a list of ids here, vanilla blocks are supported too + # You can use a list of IDs here; vanilla blocks are also supported id: '{0}greenhouse_glass' type: CHORUS range: 5 - # Sync seasons + # Synchronize seasons with another world sync-season: enable: false reference: world - # Vanilla farmland settings + # Vanilla farmland mechanics vanilla-farmland: - # Disable vanilla farmland moisture mechanics - # This option exists because some users prefer to use the vanilla farmland but the water system conflicts with the vanilla one + # Disable the moisture mechanics of vanilla farmland + # This is useful if you prefer vanilla farmland but the water system conflicts with vanilla mechanics disable-moisture-mechanic: false - # Prevent entities from trampling the farmland + # Prevent entities from trampling farmland prevent-trampling: false - # Set hologram offset correction for other blocks + # Set hologram offset correction for different blocks hologram-offset-correction: "{0}crop_stage_death": 0 - # Set the block types that would be overridden + # Specify block types that should be overridden by the plugin + # Some common crops: WHEAT/CARROTS/POTATOES/BEETROOTS/SWEET_BERRY_BUSH override-vanilla-blocks: [] other-settings: - # It's recommended to use MiniMessage format. If you insist on using legacy color code "&", enable the support below. - # Disable this would improve performance + # It is recommended to use MiniMessage format. If you want to use legacy color codes ("&"), enable support below. + # Disabling this can improve performance legacy-color-code-support: true - # Requires PlaceholderAPI to work + # Requires PlaceholderAPI to function placeholder-register: '{skill-level}': '%levelplugin_farming%' - # Using items from other plugins + # To use items from other plugins item-detection-order: [] - # Whether to protect the original lore of the item - # This uses the scoreboard component to identify the plugin's lore, - # which may conflict with some plugins that still use SpigotAPI#ItemMeta. + # Whether to protect the original lore of items + # Uses the scoreboard component to identify the plugin's lore, + # which may conflict with some plugins still using SpigotAPI#ItemMeta protect-original-lore: false - # Whether to check if the block/furniture corresponds with the one in CustomCrops data - # You can enable this if you are using Oraxen as its API is more reliable - double-check: false \ No newline at end of file + # Whether to verify if a block/furniture matches the data in CustomCrops + # Enable this if using Oraxen, as its API is more reliable + double-check: false diff --git a/plugin/src/main/resources/contents/crops/default.yml b/plugin/src/main/resources/contents/crops/default.yml index 16b39c7..ea49971 100644 --- a/plugin/src/main/resources/contents/crops/default.yml +++ b/plugin/src/main/resources/contents/crops/default.yml @@ -1,18 +1,18 @@ -# ID +# Unique identifier for the crop tomato: - # Item type - # BLOCK / FURNITURE + # Type of the item + # Options: BLOCK or FURNITURE type: BLOCK - # The crop can only be planted on whitelisted pots + # Specifies which pots the crop can be planted on pot-whitelist: - default - # Seed of the crop + # The seed item used to plant the crop seed: {0}tomato_seeds - # Only works in FURNITURE mode + # Enables random rotation when planting; applicable only in FURNITURE mode random-rotation: true - # Break/Plant requirements + # Requirements for planting or breaking the crop requirements: - break: {} + break: {} # No specific requirements for breaking plant: requirement_1: type: season @@ -23,14 +23,14 @@ tomato: actionbar_action: type: message value: '[X] It''s not a good season to plant tomato' - # Event settings + # Event settings for actions like planting and breaking events: plant: - # Swing the main hand + # Plays a hand-swing animation when planting swing_hand_action: type: swing-hand value: true - # Send sound while planting + # Plays a sound when planting the crop sound_action: type: sound value: @@ -39,6 +39,7 @@ tomato: volume: 1 pitch: 1 break: + # Plays a sound when breaking the crop sound_action: type: sound value: @@ -46,19 +47,19 @@ tomato: key: minecraft:block.crop.break volume: 1 pitch: 1 - # This determines the maximum time for crops to grow + # Maximum growth stage for the crop max-points: 6 - # This section determines the actions of crops at each point + # Actions and settings for each growth stage of the crop points: 0: - # If model is set, the crop will replace its appearance when it reaches this stage. + # Model representing the crop at this growth stage model: {0}tomato_stage_1 - # Each crop has a different model height, so appropriate offsets should be made when displaying holograms. + # Adjusts hologram position to match the crop model's height hologram-offset-correction: 0.2 - # Event settings + # Events triggered when the crop is broken at this stage events: break: - # 30% chance of dropping crop seeds + # 30% chance to drop tomato seeds when broken action_1: type: drop-item value: @@ -72,6 +73,7 @@ tomato: hologram-offset-correction: 0.2 events: break: + # 50% chance to drop tomato seeds when broken action_1: type: drop-item value: @@ -85,6 +87,7 @@ tomato: hologram-offset-correction: 0.2 events: break: + # 70% chance to drop tomato seeds when broken action_1: type: drop-item value: @@ -98,6 +101,7 @@ tomato: hologram-offset-correction: 0.2 events: interact: + # Actions triggered upon interacting with the crop action_1: type: conditional value: @@ -119,6 +123,7 @@ tomato: point: 0 crop: tomato grow: + # Rare chance to change to a special "golden" variant upon growth action_1: type: variation value: @@ -127,6 +132,7 @@ tomato: type: TRIPWIRE chance: 0.01 break: + # 100% chance to drop 1-2 tomato seeds when broken action_1: type: drop-item value: @@ -135,6 +141,7 @@ tomato: min: 1 max: 2 chance: 1 + # Quality crop drop logic, varying the output action_2: type: quality-crops value: @@ -145,6 +152,7 @@ tomato: 2: {0}tomato_silver_star 3: {0}tomato_golden_star 6: + # Additional growth events beyond normal max-points events: grow: action_1: @@ -154,11 +162,10 @@ tomato: item: {0}gigantic_tomato type: CHORUS chance: 0.02 - # The crop would actually not gain so many points - # But you can set some special crops' loots here + # Special configuration for a non-standard growth stage (e.g., rare or unique crops) 99: model: {0}tomato_stage_golden - # You can set interact/break requirements for each stage + # Stage-specific interact and break requirements requirements: break: requirement_1: @@ -172,6 +179,7 @@ tomato: value: "[X] Hold a golden hoe to harvest the golden tomato" events: break: + # Drops and other actions when breaking the crop at this special stage action_1: type: drop-item value: @@ -188,6 +196,7 @@ tomato: min: 1 max: 4 chance: 1 + # Reduces item durability upon interaction action_3: type: durability value: -1 @@ -213,7 +222,7 @@ tomato: value: point: 0 crop: tomato - # Custom grow conditions + # Conditions under which the crop can grow grow-conditions: default: point: 1 @@ -226,10 +235,10 @@ tomato: water_condition: type: water_more_than value: 0 - # Custom death conditions + # Conditions that may cause the crop to die death-conditions: no_water: - # You can customize the death stage models according to the reasons + # Custom model for the death stage, triggered by lack of water model: {0}crop_stage_death conditions: '&&': @@ -240,6 +249,7 @@ tomato: type: random value: 0.7 unsuitable_season: + # Crop dies in unsuitable seasons model: {0}crop_stage_death conditions: condition_1: @@ -247,8 +257,7 @@ tomato: value: - Winter crow_attack: - # Crop would be removed if "model" is not set - # model: {0}crop_stage_death + # Crop removal due to crow attack conditions: condition_1: type: crow_attack @@ -256,13 +265,13 @@ tomato: chance: 0.005 fly-model: {0}crow_fly stand-model: {0}crow_stand - # delay 150 ticks for the crop to be removed + # Delay before the crop is removed after a crow attack delay: 150 - # Custom bone meal + # Custom settings for bone meal use custom-bone-meal: bone_meal_1: item: BONE_MEAL - # Allow to be used with dispenser + # Allows use with a dispenser dispenser: true chance: 2: 0.2 @@ -288,4 +297,4 @@ tomato: source: player key: minecraft:item.bone_meal.use volume: 1 - pitch: 1 \ No newline at end of file + pitch: 1 diff --git a/plugin/src/main/resources/contents/fertilizers/default.yml b/plugin/src/main/resources/contents/fertilizers/default.yml index 32b73d0..3768559 100644 --- a/plugin/src/main/resources/contents/fertilizers/default.yml +++ b/plugin/src/main/resources/contents/fertilizers/default.yml @@ -1,15 +1,16 @@ +# Unique identifier for the fertilizer quality_1: - type: QUALITY - icon: '뀆' - chance: 1 - times: 28 - ratio: 7/2/1 - item: {0}quality_1 - before-plant: true + type: QUALITY # The type of fertilizer + icon: '뀆' # Icon representing this fertilizer in the game + chance: 1 # Probability factor influencing effect of fertilizer + times: 28 # Number of ticking cycles this fertilizer lasts + ratio: 7/2/1 # 7/2/1 = 70%/20%/10% + item: {0}quality_1 # Unique item ID for this fertilizer + before-plant: true # Indicates that this fertilizer must be applied before planting crops pot-whitelist: - - default + - default # List of allowed pots where this fertilizer can be used events: - use: + use: # Actions triggered when the fertilizer is applied particle_action: type: particle value: @@ -27,7 +28,7 @@ quality_1: key: minecraft:item.hoe.till volume: 1 pitch: 1 - wrong_pot: + wrong_pot: # Actions triggered if the fertilizer is used on the wrong pot type sound_action: type: sound value: @@ -37,8 +38,8 @@ quality_1: pitch: 1 actionbar_action: type: actionbar - value: '[X] This fertilizer can only be used in pots.' - before_plant: + value: '[X] This fertilizer can only be used in pots.' # Message shown on the action bar + before_plant: # Actions triggered if the fertilizer is used after planting sound_action: type: sound value: diff --git a/plugin/src/main/resources/contents/pots/default.yml b/plugin/src/main/resources/contents/pots/default.yml index 0e2136d..a353756 100644 --- a/plugin/src/main/resources/contents/pots/default.yml +++ b/plugin/src/main/resources/contents/pots/default.yml @@ -1,46 +1,47 @@ -# ID +# Unique identifier for the pot default: - # Maximum water storage capacity + # Maximum capacity for storing water in the pot max-water-storage: 5 - # The most basic settings + # Basic settings for pot appearance and behavior base: - # Pot models - dry: {0}dry_pot - wet: {0}wet_pot - # Does the pot absorb raindrop + # Models for the pot's appearance + dry: {0}dry_pot # Model ID when the pot is dry + wet: {0}wet_pot # Model ID when the pot is wet + # Determines if the pot absorbs rainwater when it rains absorb-rainwater: true - # Does nearby water make the pot wet + # Determines if water from nearby sources can wet the pot absorb-nearby-water: false - # The max amount of fertilizers + # Maximum number of fertilizers that can be applied to the pot max-fertilizers: 1 - # Set unique looks for pots with different fertilizer statuses + # Custom appearances for pots with different fertilizer effects fertilized-pots: quality: - dry: {0}dry_pot - wet: {0}wet_pot + dry: {0}dry_pot # Model ID for dry pot with 'quality' fertilizer effect + wet: {0}wet_pot # Model ID for wet pot with 'quality' fertilizer effect yield_increase: - dry: {0}dry_pot - wet: {0}wet_pot + dry: {0}dry_pot # Model ID for dry pot with 'yield increase' fertilizer effect + wet: {0}wet_pot # Model ID for wet pot with 'yield increase' fertilizer effect variation: - dry: {0}dry_pot - wet: {0}wet_pot + dry: {0}dry_pot # Model ID for dry pot with 'variation' fertilizer effect + wet: {0}wet_pot # Model ID for wet pot with 'variation' fertilizer effect soil_retain: - dry: {0}dry_pot - wet: {0}wet_pot + dry: {0}dry_pot # Model ID for dry pot with 'soil retain' fertilizer effect + wet: {0}wet_pot # Model ID for wet pot with 'soil retain' fertilizer effect speed_grow: - dry: {0}dry_pot - wet: {0}wet_pot - # Methods to fill the watering can + dry: {0}dry_pot # Model ID for dry pot with 'speed grow' fertilizer effect + wet: {0}wet_pot # Model ID for wet pot with 'speed grow' fertilizer effect + # Methods available to refill the watering can with water fill-method: - # The name of the method, it's totally customized + # Customizable refill method 1 method_1: - # The item to use + # Item required to refill item: WATER_BUCKET - # The item returned (Optional) + # Item returned after refilling (optional) return: BUCKET - # The amount of water to add + # Amount of water added with this method amount: 3 actions: + # Sound effect to play when refilling sound_action: type: sound value: @@ -48,9 +49,11 @@ default: key: minecraft:item.bucket.fill volume: 1 pitch: 1 + # Action of swinging hand during refill swing_hand_action: type: swing-hand value: true + # Customizable refill method 2 method_2: item: POTION return: GLASS_BOTTLE @@ -66,19 +69,19 @@ default: swing_hand_action: type: swing-hand value: true - # Water bar image settings + # Configuration for the visual display of water levels water-bar: - left: '뀂' - full: '뀁뀃' - empty: '뀁뀄' - right: '뀁뀅' - # Event settings + left: '뀂' # Left cap character for the water bar + full: '뀁뀃' # Character sequence representing a full water segment + empty: '뀁뀄' # Character sequence representing an empty water segment + right: '뀁뀅' # Right cap character for the water bar + # Event settings to handle interactions and effects events: add_water: particle_action: type: particle value: - particle: WATER_SPLASH + particle: WATER_SPLASH # Particle effect when water is added x: 0.5 y: 1.3 z: 0.5 @@ -86,7 +89,7 @@ default: offset-x: 0.3 offset-z: 0.3 interact: - # This action allows to display hologram while holding the specified item. + # Action to display a hologram when holding a specified item conditional_action: type: conditional value: @@ -97,7 +100,7 @@ default: amount: 1 item: {0}soil_surveyor actions: - # If the fertilizer doesn't exist, this line would not appear + # Display hologram for fertilizer status if fertilizer exists conditional_fertilizer_action: type: conditional value: @@ -110,18 +113,18 @@ default: fertilizer_hologram: type: hologram value: - duration: 20 - text: '{icon} {left_times}/{max_times} ' + duration: 20 # Duration the hologram remains visible + text: '{icon} {left_times}/{max_times}' apply-correction: true x: 0.5 y: 0.83 z: 0.5 visible-to-all: false - # Display the amount of water in pot + # Display hologram showing current water level in the pot water_hologram: type: hologram value: - duration: 20 + duration: 20 # Duration the hologram remains visible text: '{water_bar}' apply-correction: true x: 0.5 diff --git a/plugin/src/main/resources/contents/sprinklers/default.yml b/plugin/src/main/resources/contents/sprinklers/default.yml index 98e4eef..ceb02c8 100644 --- a/plugin/src/main/resources/contents/sprinklers/default.yml +++ b/plugin/src/main/resources/contents/sprinklers/default.yml @@ -1,53 +1,60 @@ -# ID +# Unique identifier for the sprinkler sprinkler_1: - # This decides the work range + # Sprinkler's working range: # □■□ # ■▼■ # □■□ range: 1 - # mode of sprinkling (1=square, 2=rhombus, 3=circle) + # Sprinkling pattern mode: + # 1 = square, 2 = rhombus, 3 = circle working-mode: 2 - # Maximum water storage capacity + # Maximum capacity for storing water storage: 4 - # Unlimited water source + # Indicates whether the sprinkler has unlimited water supply infinite: false - # Amount of water added in a single sprinkling + # The amount of water added to pot per sprinkling operation water: 1 - # Basic 3d model - 3D-item: {0}sprinkler_1 - # Optional 2d model + # The amount of water consumed per sprinkling operation + sprinkling: 1 + # 3D model identifier for the sprinkler + 3D-item: {0}sprinkler_1 # without water + 3D-item-with-water: {0}sprinkler_1 # with water + # Optional 2D item model identifier 2D-item: {0}sprinkler_1_item - # ITEM_FRAME / TRIPWIRE / ITEM_DISPLAY (1.19.4+) - type: ITEM_FRAME - # Sprinklers only work in specified planting pots + # The type of sprinkler (BLOCK or FURNITURE) + type: FURNITURE + # List of allowed planting pots where the sprinkler can function pot-whitelist: - default - # Methods to fill the sprinkler + # Methods available for refilling the sprinkler's water supply fill-method: - # The name of the method, it's totally customized + # Custom refill method 1 configuration method_1: - # The item to use + # Item used for refilling item: WATER_BUCKET - # The item returned (Optional) + # Item returned after refilling (optional) return: BUCKET - # The amount of water to add + # Amount of water added by this method amount: 3 + # Custom refill method 2 configuration method_2: item: POTION return: GLASS_BOTTLE amount: 1 - # Water bar image settings + # Configuration for the water level display bar water-bar: - left: '뀂' - full: '뀁뀃' - empty: '뀁뀄' - right: '뀁뀅' - # Event settings + left: '뀂' # Left end of the water bar + full: '뀁뀃' # Full segment of the water bar + empty: '뀁뀄' # Empty segment of the water bar + right: '뀁뀅' # Right end of the water bar + # Event settings for various interactions and actions events: place: + # Action performed when placing the sprinkler swing_hand_action: type: swing-hand value: true + # Sound effect triggered when placing the sprinkler sound_action: type: sound value: @@ -56,6 +63,7 @@ sprinkler_1: volume: 1 pitch: 1 interact: + # Conditional action executed on interaction force_work_action: type: conditional value: @@ -66,6 +74,7 @@ sprinkler_1: actions: action_1: type: force-tick + # Hologram display action upon interaction hologram_action: type: hologram value: @@ -76,6 +85,7 @@ sprinkler_1: z: 0.5 visible-to-all: false work: + # Visual effect displayed when the sprinkler is working fake_item_action: type: fake-item value: @@ -86,6 +96,7 @@ sprinkler_1: z: 0.5 visible-to-all: true add_water: + # Particle effect shown when adding water particle_action: type: particle value: @@ -94,6 +105,7 @@ sprinkler_1: y: 0.7 z: 0.5 count: 5 + # Sound effect played when adding water sound_action: type: sound value: @@ -101,7 +113,9 @@ sprinkler_1: source: 'player' volume: 1 pitch: 1 + sprinkler_2: + # Sprinkler's working range: # □□□□□ # □■■■□ # □■▼■□ @@ -113,7 +127,7 @@ sprinkler_2: water: 1 3D-item: {0}sprinkler_2 2D-item: {0}sprinkler_2_item - type: ITEM_FRAME + type: FURNITURE pot-whitelist: - default fill-method: @@ -188,7 +202,9 @@ sprinkler_2: source: 'player' volume: 1 pitch: 1 + sprinkler_3: + # Sprinkler's working range: # □□□□□□□ # □■■■■■□ # □■■■■■□ @@ -202,7 +218,7 @@ sprinkler_3: water: 1 3D-item: {0}sprinkler_3 2D-item: {0}sprinkler_3_item - type: ITEM_FRAME + type: FURNITURE pot-whitelist: - default fill-method: diff --git a/plugin/src/main/resources/contents/watering-cans/default.yml b/plugin/src/main/resources/contents/watering-cans/default.yml index 48ac452..70352e9 100644 --- a/plugin/src/main/resources/contents/watering-cans/default.yml +++ b/plugin/src/main/resources/contents/watering-cans/default.yml @@ -1,88 +1,85 @@ -# ID +# Watering can configuration by ID watering_can_1: - # ItemsAdder/Oraxen item ID + # Unique item identifier for ItemsAdder/Oraxen item: {0}watering_can_1 - # This is optional. It will determine the appearance of watering cans with different water storage capacities + # Optional appearance settings for watering cans based on water capacity + # Uncomment and customize CustomModelData if you want different appearances for different water levels #appearance: - # 0: 1000 # CustomModelData - # 1: 1001 - # 2: 1002 - # 3: 1003 - # Maximum water storage capacity + # 0: 1000 # CustomModelData for empty can + # 1: 1001 # CustomModelData for partially filled can + # 2: 1002 # CustomModelData for more filled can + # 3: 1003 # CustomModelData for fully filled can + # Maximum amount of water the watering can can store capacity: 3 - # Amount of water added to pot in a single interaction + # Amount of water added to pot water: 1 - # Effective Range + # The effective range of the watering can when used effective-range: - width: 1 - length: 1 - # Methods to fill the watering can + width: 1 # The width of the area affected + length: 1 # The length of the area affected + # Methods to refill the watering can with water fill-method: - # The name of the method, it's totally customized + # Custom refill method configuration method_1: - # The target block/furniture (That means you can create a well to get water) - target: WATER - # Amount of water to add - amount: 1 - # Watering cans only work in specified planting pots + target: WATER # The block or object that provides water (e.g., a water block or well) + amount: 1 # Amount of water added per refill + # Specify which types of planting pots the watering can can be used with pot-whitelist: - - default - # Allow watering can to divert water to sprinkler + - default # Default pot type allowed + # Allow the watering can to fill compatible sprinklers sprinkler-whitelist: - sprinkler_1 - sprinkler_2 - sprinkler_3 - # Dynamic lore settings + # Dynamic lore settings for the watering can's description dynamic-lore: - # Should watering-can has dynamic lore according to the water amount - enable: true + enable: true # Enable or disable dynamic lore based on water level + # Lore text that will be displayed dynamically # Available placeholders: - # {water_bar}: water bar image - # {current}: current amount of water - # {storage}: max water storage + # {water_bar}: Visual representation of water level + # {current}: Current amount of water + # {storage}: Maximum water storage capacity lore: - '{water_bar}' - - 'Right click water to add water to the can.' - # Water bar image settings + - 'Right-click on water to refill the watering can.' + # Configuration for the water level display bar water-bar: - left: '뀂' - full: '뀁뀃' - empty: '뀁뀄' - right: '뀁뀅' - # Event settings + left: '뀂' # Left cap of the water bar + full: '뀁뀃' # Segment representing full water level + empty: '뀁뀄' # Segment representing empty water level + right: '뀁뀅' # Right cap of the water bar + # Event settings to handle various actions with the watering can events: - # No water + # Event triggered when there's no water left in the watering can no_water: sound_action: type: sound value: - key: "minecraft:item.bundle.insert" - source: 'player' + key: "minecraft:item.bundle.insert" # Sound to play + source: 'player' # Sound source volume: 1 pitch: 1 actionbar_action: type: actionbar - value: '[X] Water has been used out' - # Consume water + value: '[X] Water has been used out' # Message displayed on action bar + # Event triggered when water is consumed from the watering can consume_water: - # The name of the action, it's totally customized sound_action: type: sound value: - key: "minecraft:block.water.ambient" + key: "minecraft:block.water.ambient" # Sound of water being consumed source: 'player' volume: 1 pitch: 1 actionbar_action: type: actionbar - value: '{water_bar}' - # Add water to the watering-can + value: '{water_bar}' # Display updated water bar + # Event triggered when water is added to the watering can add_water: - # The name of the action, it's totally customized particle_action: type: particle value: - particle: WATER_SPLASH + particle: WATER_SPLASH # Particle effect for adding water x: 0.5 y: 1.3 z: 0.5 @@ -90,13 +87,14 @@ watering_can_1: sound_action: type: sound value: - key: "minecraft:item.bucket.empty" + key: "minecraft:item.bucket.empty" # Sound to play when filling the can source: 'player' volume: 1 pitch: 1 actionbar_action: type: actionbar - value: '{water_bar}' + value: '{water_bar}' # Update water bar display +# Configuration for additional watering cans watering_can_2: item: {0}watering_can_2 capacity: 4 @@ -118,7 +116,7 @@ watering_can_2: enable: true lore: - '{water_bar}' - - 'Right click water to add water to the can.' + - 'Right-click on water to refill the watering can.' water-bar: left: '뀂' full: '뀁뀃' @@ -166,6 +164,7 @@ watering_can_2: actionbar_action: type: actionbar value: '{water_bar}' +# Continue similar configuration for watering_can_3 and watering_can_4... watering_can_3: item: {0}watering_can_3 capacity: 5 @@ -187,7 +186,7 @@ watering_can_3: enable: true lore: - '{water_bar}' - - 'Right click water to add water to the can.' + - 'Right-click on water to refill the watering can.' water-bar: left: '뀂' full: '뀁뀃' @@ -256,7 +255,7 @@ watering_can_4: enable: true lore: - '{water_bar}' - - 'Right click water to add water to the can.' + - 'Right-click on water to refill the watering can.' water-bar: left: '뀂' full: '뀁뀃'