Interface CocoaDecorator

All Superinterfaces:
TreeDecorator, Wrapper

@NullMarked @AsOf("3.0.0") public interface CocoaDecorator extends TreeDecorator
Places cocoa beans on the bottom 3 blocks of the trunk with a probability of 25% for each face. The specified probability determines how often any cocoa beans are placed.
Since:
3.0.0
See Also:
  • Method Details

    • probability

      @AsOf("3.0.0") float probability()
      The probability that this decorator places any cocoa beans, between 0.0F and 1.0F (inclusive).
      Returns:
      the probability
      Since:
      3.0.0
    • toBuilder

      @AsOf("3.0.0") default CocoaDecorator.Builder toBuilder()
      Converts this object back to a builder.
      Returns:
      a builder with the same values as this object
      Since:
      3.0.0
    • of

      @AsOf("3.0.0") static CocoaDecorator of(float probability)
      Creates a new cocoa decorator.
      Parameters:
      probability - the probability that this decorator places any cocoa beans, between 0.0F and 1.0F (inclusive)
      Returns:
      a new cocoa decorator
      Since:
      3.0.0
    • builder

      @AsOf("3.0.0") static CocoaDecorator.Builder builder()
      Creates a new builder.
      Returns:
      a new builder
      Since:
      3.0.0