Class NumberEstimate

java.lang.Object
petrolpark.mc.library.core.data.numberProvider.NumberEstimate
Direct Known Subclasses:
NumberEstimate.Exact, NumberEstimate.Range, NumberEstimate.Unknown

public abstract sealed class NumberEstimate extends Object permits NumberEstimate.Exact, NumberEstimate.Range, NumberEstimate.Unknown
  • Field Details

  • Constructor Details

    • NumberEstimate

      protected NumberEstimate(boolean approximate)
  • Method Details

    • fieldCodec

      public static final com.mojang.serialization.MapCodec<NumberEstimate> fieldCodec(String key)
    • getMax

      @Deprecated public static float getMax(net.minecraft.world.level.storage.loot.LootContext context, net.minecraft.world.level.storage.loot.providers.number.NumberProvider provider)
      Deprecated.
    • getMax

      @Deprecated public static float getMax(net.minecraft.world.level.storage.loot.LootContext context, net.minecraft.world.level.storage.loot.providers.number.NumberProvider provider, int rolls)
      Deprecated.
    • get

      public static NumberEstimate get(net.minecraft.world.level.storage.loot.providers.number.NumberProvider numberProvider)
    • getBinomial

      public static final NumberEstimate getBinomial(net.minecraft.world.level.storage.loot.providers.number.BinomialDistributionGenerator binomial)
    • exactly

      public static final NumberEstimate exactly(float value)
    • approximately

      public static final NumberEstimate approximately(float value)
    • ranged

      public static final NumberEstimate ranged(NumberEstimate minEstimate, NumberEstimate maxEstimate)
    • ranged

      public static final NumberEstimate ranged(NumberEstimate minEstimate, NumberEstimate maxEstimate, boolean approximate)
    • ranged

      public static final NumberEstimate ranged(float min, float max, boolean approximate)
    • ranged

      public static final NumberEstimate ranged(float min, float max)
    • getIntComponent

      public net.minecraft.network.chat.Component getIntComponent()
    • getComponent

      public abstract net.minecraft.network.chat.Component getComponent(DecimalFormat df)
    • approximate

      public final boolean approximate()
    • min

      public abstract float min()
    • max

      public abstract float max()
    • add

      public abstract NumberEstimate add(NumberEstimate estimate)
    • subtract

      public NumberEstimate subtract(NumberEstimate estimate)
    • add

      public abstract NumberEstimate add(float value)
    • multiply

      public abstract NumberEstimate multiply(NumberEstimate estimate)
    • divide

      public NumberEstimate divide(NumberEstimate estimate)
    • multiply

      public abstract NumberEstimate multiply(float value)
    • reciprocal

      public abstract NumberEstimate reciprocal()
    • negative

      public abstract NumberEstimate negative()
    • pow

      public abstract NumberEstimate pow(float exponent)
    • exp

      public abstract NumberEstimate exp()
    • or

      public abstract NumberEstimate or(NumberEstimate estimate)
    • streamPossibleInts

      public abstract IntStream streamPossibleInts()
    • wrap

    • unknown

      public boolean unknown()