Record Class OnKilledCriterion.Conditions

java.lang.Object
java.lang.Record
net.minecraft.advancement.criterion.OnKilledCriterion.Conditions
Record Components:
player -
entity -
killingBlow -
All Implemented Interfaces:
AbstractCriterion.Conditions, CriterionConditions
Enclosing class:
OnKilledCriterion

public static record OnKilledCriterion.Conditions(Optional<LootContextPredicate> player, Optional<LootContextPredicate> entity, Optional<DamageSourcePredicate> killingBlow) extends Record implements AbstractCriterion.Conditions
Mappings:
Namespace Name
named net/minecraft/advancement/criterion/OnKilledCriterion$Conditions
intermediary net/minecraft/class_2080$class_2083
official dc$a
named player
intermediary comp_2029
official b
named entity
intermediary comp_2068
official c
named killingBlow
intermediary comp_2069
official d
  • Field Details

    • player

      private final Optional<LootContextPredicate> player
      The field for the player record component.
    • entity

      private final Optional<LootContextPredicate> entity
      The field for the entity record component.
    • killingBlow

      private final Optional<DamageSourcePredicate> killingBlow
      The field for the killingBlow record component.
    • CODEC

      public static final com.mojang.serialization.Codec<OnKilledCriterion.Conditions> CODEC
      Mappings:
      Namespace Name Mixin selector
      named CODEC Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;CODEC:Lcom/mojang/serialization/Codec;
      intermediary field_47304 Lnet/minecraft/class_2080$class_2083;field_47304:Lcom/mojang/serialization/Codec;
      official a Ldc$a;a:Lcom/mojang/serialization/Codec;
  • Constructor Details

    • Conditions

      public Conditions(Optional<LootContextPredicate> playerPredicate, Optional<LootContextPredicate> entity, Optional<DamageSourcePredicate> killingBlow)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;<init>(Ljava/util/Optional;Ljava/util/Optional;Ljava/util/Optional;)V
      intermediary <init> Lnet/minecraft/class_2080$class_2083;<init>(Ljava/util/Optional;Ljava/util/Optional;Ljava/util/Optional;)V
      official <init> Ldc$a;<init>(Ljava/util/Optional;Ljava/util/Optional;Ljava/util/Optional;)V
  • Method Details

    • createPlayerKilledEntity

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createPlayerKilledEntity(Optional<EntityPredicate> entity)
      Mappings:
      Namespace Name Mixin selector
      named createPlayerKilledEntity Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createPlayerKilledEntity(Ljava/util/Optional;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35248 Lnet/minecraft/class_2080$class_2083;method_35248(Ljava/util/Optional;)Lnet/minecraft/class_175;
      official a Ldc$a;a(Ljava/util/Optional;)Lap;
    • createPlayerKilledEntity

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createPlayerKilledEntity(EntityPredicate.Builder killedEntityPredicateBuilder)
      Mappings:
      Namespace Name Mixin selector
      named createPlayerKilledEntity Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createPlayerKilledEntity(Lnet/minecraft/predicate/entity/EntityPredicate$Builder;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_8997 Lnet/minecraft/class_2080$class_2083;method_8997(Lnet/minecraft/class_2048$class_2049;)Lnet/minecraft/class_175;
      official a Ldc$a;a(Lbw$a;)Lap;
    • createPlayerKilledEntity

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createPlayerKilledEntity()
      Mappings:
      Namespace Name Mixin selector
      named createPlayerKilledEntity Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createPlayerKilledEntity()Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_8999 Lnet/minecraft/class_2080$class_2083;method_8999()Lnet/minecraft/class_175;
      official b Ldc$a;b()Lap;
    • createPlayerKilledEntity

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createPlayerKilledEntity(Optional<EntityPredicate> entity, Optional<DamageSourcePredicate> killingBlow)
      Mappings:
      Namespace Name Mixin selector
      named createPlayerKilledEntity Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createPlayerKilledEntity(Ljava/util/Optional;Ljava/util/Optional;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35250 Lnet/minecraft/class_2080$class_2083;method_35250(Ljava/util/Optional;Ljava/util/Optional;)Lnet/minecraft/class_175;
      official a Ldc$a;a(Ljava/util/Optional;Ljava/util/Optional;)Lap;
    • createPlayerKilledEntity

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createPlayerKilledEntity(EntityPredicate.Builder killedEntityPredicateBuilder, Optional<DamageSourcePredicate> killingBlow)
      Mappings:
      Namespace Name Mixin selector
      named createPlayerKilledEntity Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createPlayerKilledEntity(Lnet/minecraft/predicate/entity/EntityPredicate$Builder;Ljava/util/Optional;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35247 Lnet/minecraft/class_2080$class_2083;method_35247(Lnet/minecraft/class_2048$class_2049;Ljava/util/Optional;)Lnet/minecraft/class_175;
      official a Ldc$a;a(Lbw$a;Ljava/util/Optional;)Lap;
    • createPlayerKilledEntity

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createPlayerKilledEntity(Optional<EntityPredicate> entity, DamageSourcePredicate.Builder damageSourcePredicateBuilder)
      Mappings:
      Namespace Name Mixin selector
      named createPlayerKilledEntity Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createPlayerKilledEntity(Ljava/util/Optional;Lnet/minecraft/predicate/entity/DamageSourcePredicate$Builder;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35249 Lnet/minecraft/class_2080$class_2083;method_35249(Ljava/util/Optional;Lnet/minecraft/class_2022$class_2023;)Lnet/minecraft/class_175;
      official a Ldc$a;a(Ljava/util/Optional;Lbl$a;)Lap;
    • createPlayerKilledEntity

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createPlayerKilledEntity(EntityPredicate.Builder killedEntityPredicateBuilder, DamageSourcePredicate.Builder killingBlowBuilder)
      Mappings:
      Namespace Name Mixin selector
      named createPlayerKilledEntity Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createPlayerKilledEntity(Lnet/minecraft/predicate/entity/EntityPredicate$Builder;Lnet/minecraft/predicate/entity/DamageSourcePredicate$Builder;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_9001 Lnet/minecraft/class_2080$class_2083;method_9001(Lnet/minecraft/class_2048$class_2049;Lnet/minecraft/class_2022$class_2023;)Lnet/minecraft/class_175;
      official a Ldc$a;a(Lbw$a;Lbl$a;)Lap;
    • createKillMobNearSculkCatalyst

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createKillMobNearSculkCatalyst()
      Mappings:
      Namespace Name Mixin selector
      named createKillMobNearSculkCatalyst Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createKillMobNearSculkCatalyst()Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_42671 Lnet/minecraft/class_2080$class_2083;method_42671()Lnet/minecraft/class_175;
      official c Ldc$a;c()Lap;
    • createEntityKilledPlayer

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createEntityKilledPlayer(Optional<EntityPredicate> entity)
      Mappings:
      Namespace Name Mixin selector
      named createEntityKilledPlayer Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createEntityKilledPlayer(Ljava/util/Optional;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35254 Lnet/minecraft/class_2080$class_2083;method_35254(Ljava/util/Optional;)Lnet/minecraft/class_175;
      official b Ldc$a;b(Ljava/util/Optional;)Lap;
    • createEntityKilledPlayer

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createEntityKilledPlayer(EntityPredicate.Builder killerEntityPredicateBuilder)
      Mappings:
      Namespace Name Mixin selector
      named createEntityKilledPlayer Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createEntityKilledPlayer(Lnet/minecraft/predicate/entity/EntityPredicate$Builder;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35251 Lnet/minecraft/class_2080$class_2083;method_35251(Lnet/minecraft/class_2048$class_2049;)Lnet/minecraft/class_175;
      official b Ldc$a;b(Lbw$a;)Lap;
    • createEntityKilledPlayer

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createEntityKilledPlayer()
      Mappings:
      Namespace Name Mixin selector
      named createEntityKilledPlayer Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createEntityKilledPlayer()Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_8998 Lnet/minecraft/class_2080$class_2083;method_8998()Lnet/minecraft/class_175;
      official d Ldc$a;d()Lap;
    • createEntityKilledPlayer

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createEntityKilledPlayer(Optional<EntityPredicate> entity, Optional<DamageSourcePredicate> killingBlow)
      Mappings:
      Namespace Name Mixin selector
      named createEntityKilledPlayer Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createEntityKilledPlayer(Ljava/util/Optional;Ljava/util/Optional;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35256 Lnet/minecraft/class_2080$class_2083;method_35256(Ljava/util/Optional;Ljava/util/Optional;)Lnet/minecraft/class_175;
      official b Ldc$a;b(Ljava/util/Optional;Ljava/util/Optional;)Lap;
    • createEntityKilledPlayer

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createEntityKilledPlayer(EntityPredicate.Builder killerEntityPredicateBuilder, Optional<DamageSourcePredicate> killingBlow)
      Mappings:
      Namespace Name Mixin selector
      named createEntityKilledPlayer Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createEntityKilledPlayer(Lnet/minecraft/predicate/entity/EntityPredicate$Builder;Ljava/util/Optional;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35253 Lnet/minecraft/class_2080$class_2083;method_35253(Lnet/minecraft/class_2048$class_2049;Ljava/util/Optional;)Lnet/minecraft/class_175;
      official b Ldc$a;b(Lbw$a;Ljava/util/Optional;)Lap;
    • createEntityKilledPlayer

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createEntityKilledPlayer(Optional<EntityPredicate> entity, DamageSourcePredicate.Builder damageSourcePredicateBuilder)
      Mappings:
      Namespace Name Mixin selector
      named createEntityKilledPlayer Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createEntityKilledPlayer(Ljava/util/Optional;Lnet/minecraft/predicate/entity/DamageSourcePredicate$Builder;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35255 Lnet/minecraft/class_2080$class_2083;method_35255(Ljava/util/Optional;Lnet/minecraft/class_2022$class_2023;)Lnet/minecraft/class_175;
      official b Ldc$a;b(Ljava/util/Optional;Lbl$a;)Lap;
    • createEntityKilledPlayer

      public static AdvancementCriterion<OnKilledCriterion.Conditions> createEntityKilledPlayer(EntityPredicate.Builder killerEntityPredicateBuilder, DamageSourcePredicate.Builder damageSourcePredicateBuilder)
      Mappings:
      Namespace Name Mixin selector
      named createEntityKilledPlayer Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;createEntityKilledPlayer(Lnet/minecraft/predicate/entity/EntityPredicate$Builder;Lnet/minecraft/predicate/entity/DamageSourcePredicate$Builder;)Lnet/minecraft/advancement/AdvancementCriterion;
      intermediary method_35252 Lnet/minecraft/class_2080$class_2083;method_35252(Lnet/minecraft/class_2048$class_2049;Lnet/minecraft/class_2022$class_2023;)Lnet/minecraft/class_175;
      official b Ldc$a;b(Lbw$a;Lbl$a;)Lap;
    • test

      public boolean test(ServerPlayerEntity player, LootContext entity, DamageSource killingBlow)
      Mappings:
      Namespace Name Mixin selector
      named test Lnet/minecraft/advancement/criterion/OnKilledCriterion$Conditions;test(Lnet/minecraft/server/network/ServerPlayerEntity;Lnet/minecraft/loot/context/LootContext;Lnet/minecraft/entity/damage/DamageSource;)Z
      intermediary method_9000 Lnet/minecraft/class_2080$class_2083;method_9000(Lnet/minecraft/class_3222;Lnet/minecraft/class_47;Lnet/minecraft/class_1282;)Z
      official a Ldc$a;a(Lasi;Lewo;Lbtz;)Z
    • validate

      public void validate(LootContextPredicateValidator validator)
      Specified by:
      validate in interface AbstractCriterion.Conditions
      Specified by:
      validate in interface CriterionConditions
      Mappings:
      Namespace Name Mixin selector
      named validate Lnet/minecraft/advancement/criterion/CriterionConditions;validate(Lnet/minecraft/predicate/entity/LootContextPredicateValidator;)V
      intermediary method_54938 Lnet/minecraft/class_184;method_54938(Lnet/minecraft/class_8944;)V
      official a Las;a(Lbi;)V
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object object)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      object - the object with which to compare
      Returns:
      true if this object is the same as the object argument; false otherwise.
    • player

      public Optional<LootContextPredicate> player()
      Returns the value of the player record component.
      Specified by:
      player in interface AbstractCriterion.Conditions
      Returns:
      the value of the player record component
    • entity

      public Optional<LootContextPredicate> entity()
      Returns the value of the entity record component.
      Returns:
      the value of the entity record component
    • killingBlow

      public Optional<DamageSourcePredicate> killingBlow()
      Returns the value of the killingBlow record component.
      Returns:
      the value of the killingBlow record component