Class LootContextPredicate

java.lang.Object
net.minecraft.predicate.entity.LootContextPredicate

public class LootContextPredicate extends Object
A list of loot conditions applied to entities. All conditions must match for this unified conditions to match. Mainly used by advancements.
Mappings:
Namespace Name
named net/minecraft/predicate/entity/LootContextPredicate
intermediary net/minecraft/class_5258
official bg
  • Field Details

    • CODEC

      public static final com.mojang.serialization.Codec<LootContextPredicate> CODEC
      Mappings:
      Namespace Name Mixin selector
      named CODEC Lnet/minecraft/predicate/entity/LootContextPredicate;CODEC:Lcom/mojang/serialization/Codec;
      intermediary field_47234 Lnet/minecraft/class_5258;field_47234:Lcom/mojang/serialization/Codec;
      official a Lbg;a:Lcom/mojang/serialization/Codec;
    • conditions

      private final List<LootCondition> conditions
      Mappings:
      Namespace Name Mixin selector
      named conditions Lnet/minecraft/predicate/entity/LootContextPredicate;conditions:Ljava/util/List;
      intermediary field_24389 Lnet/minecraft/class_5258;field_24389:Ljava/util/List;
      official b Lbg;b:Ljava/util/List;
    • combinedCondition

      private final Predicate<LootContext> combinedCondition
      Mappings:
      Namespace Name Mixin selector
      named combinedCondition Lnet/minecraft/predicate/entity/LootContextPredicate;combinedCondition:Ljava/util/function/Predicate;
      intermediary field_24390 Lnet/minecraft/class_5258;field_24390:Ljava/util/function/Predicate;
      official c Lbg;c:Ljava/util/function/Predicate;
  • Constructor Details

    • LootContextPredicate

      LootContextPredicate(List<LootCondition> conditions)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/predicate/entity/LootContextPredicate;<init>(Ljava/util/List;)V
      intermediary <init> Lnet/minecraft/class_5258;<init>(Ljava/util/List;)V
      official <init> Lbg;<init>(Ljava/util/List;)V
  • Method Details

    • create

      public static LootContextPredicate create(LootCondition[] conditions)
      Mappings:
      Namespace Name Mixin selector
      named create Lnet/minecraft/predicate/entity/LootContextPredicate;create([Lnet/minecraft/loot/condition/LootCondition;)Lnet/minecraft/predicate/entity/LootContextPredicate;
      intermediary method_27973 Lnet/minecraft/class_5258;method_27973([Lnet/minecraft/class_5341;)Lnet/minecraft/class_5258;
      official a Lbg;a([Leuw;)Lbg;
    • test

      public boolean test(LootContext context)
      Mappings:
      Namespace Name Mixin selector
      named test Lnet/minecraft/predicate/entity/LootContextPredicate;test(Lnet/minecraft/loot/context/LootContext;)Z
      intermediary method_27806 Lnet/minecraft/class_5258;method_27806(Lnet/minecraft/class_47;)Z
      official a Lbg;a(Lerl;)Z
    • validateConditions

      public void validateConditions(LootTableReporter reporter)
      Mappings:
      Namespace Name Mixin selector
      named validateConditions Lnet/minecraft/predicate/entity/LootContextPredicate;validateConditions(Lnet/minecraft/loot/LootTableReporter;)V
      intermediary method_54959 Lnet/minecraft/class_5258;method_54959(Lnet/minecraft/class_58;)V
      official a Lbg;a(Lerr;)V