Class FloatRangeParser<C>

java.lang.Object
org.incendo.cloud.brigadier.parser.WrappedBrigadierParser<C, net.minecraft.advancements.predicates.MinMaxBounds.Doubles>
org.incendo.cloud.minecraft.modded.parser.FloatRangeParser<C>
Type Parameters:
C - the sender type
All Implemented Interfaces:
ArgumentParser<C, net.minecraft.advancements.predicates.MinMaxBounds.Doubles>, SuggestionProvider<C>, SuggestionProviderHolder<C>

public final class FloatRangeParser<C> extends WrappedBrigadierParser<C, net.minecraft.advancements.predicates.MinMaxBounds.Doubles>
An argument parsing an unbounded double range, in the form [min]..[max], where both lower and upper bounds are optional.
  • Method Details

    • floatRangeParser

      public static <C> @NonNull ParserDescriptor<C, net.minecraft.advancements.predicates.MinMaxBounds.Doubles> floatRangeParser()
      Creates a new float range parser.
      Type Parameters:
      C - command sender type
      Returns:
      the created parser
    • floatRangeComponent

      public static <C> @NonNull CommandComponent.Builder<C, net.minecraft.advancements.predicates.MinMaxBounds.Doubles> floatRangeComponent()
      Returns a CommandComponent.Builder using floatRangeParser() as the parser.
      Type Parameters:
      C - the command sender type
      Returns:
      the component builder