Interface EnchantTableConfiguration.Builder
- All Known Implementing Classes:
EnchantTableConfigurationBuilder
- Enclosing interface:
EnchantTableConfiguration
public static interface EnchantTableConfiguration.Builder
Builder for constructing table configurations.
- Since:
- 0.3.0
-
Method Summary
Modifier and TypeMethodDescription@NotNull EnchantTableConfiguration.BuilderallowMultiple(boolean allow) Sets whether multiple offers are allowed.@NotNull EnchantTableConfigurationbuild()Builds and returns the table configuration.@NotNull EnchantTableConfiguration.BuildercostMultiplier(double multiplier) Sets the cost multiplier.@NotNull EnchantTableConfiguration.BuildermaxBookshelves(int max) Sets the maximum bookshelves allowed.@NotNull EnchantTableConfiguration.BuilderminBookshelves(int min) Sets the minimum bookshelves required.@NotNull EnchantTableConfiguration.BuildertableMaxLevel(int level) Sets the maximum enchantment level for table offers.@NotNull EnchantTableConfiguration.BuildertableMinLevel(int level) Sets the minimum enchantment level for table offers.@NotNull EnchantTableConfiguration.Buildertreasure(boolean treasure) Sets whether this is a treasure enchantment.@NotNull EnchantTableConfiguration.BuilderweightMultiplier(double multiplier) Sets the weight multiplier for this enchantment.
-
Method Details
-
weightMultiplier
Sets the weight multiplier for this enchantment.- Parameters:
multiplier- the weight multiplier (must be > 0)- Returns:
- this builder for chaining
- Since:
- 0.3.0
-
minBookshelves
Sets the minimum bookshelves required.- Parameters:
min- the minimum bookshelves (must be >= 0)- Returns:
- this builder for chaining
- Since:
- 0.3.0
-
maxBookshelves
Sets the maximum bookshelves allowed.- Parameters:
max- the maximum bookshelves (must be >= min)- Returns:
- this builder for chaining
- Since:
- 0.3.0
-
costMultiplier
Sets the cost multiplier.- Parameters:
multiplier- the cost multiplier (must be > 0)- Returns:
- this builder for chaining
- Since:
- 0.3.0
-
allowMultiple
Sets whether multiple offers are allowed.- Parameters:
allow- true to allow multiple offers- Returns:
- this builder for chaining
- Since:
- 0.3.0
-
tableMinLevel
Sets the minimum enchantment level for table offers.- Parameters:
level- the minimum level (must be >= 1)- Returns:
- this builder for chaining
- Since:
- 0.3.0
-
tableMaxLevel
Sets the maximum enchantment level for table offers.- Parameters:
level- the maximum level (must be >= min)- Returns:
- this builder for chaining
- Since:
- 0.3.0
-
treasure
Sets whether this is a treasure enchantment.- Parameters:
treasure- true for treasure behavior- Returns:
- this builder for chaining
- Since:
- 0.3.0
-
build
Builds and returns the table configuration.- Returns:
- the completed configuration
- Since:
- 0.3.0
-