Class CopyComponentsLootFunction

java.lang.Object
net.minecraft.loot.function.ConditionalLootFunction
net.minecraft.loot.function.CopyComponentsLootFunction
All Implemented Interfaces:
BiFunction<ItemStack,LootContext,ItemStack>, LootContextAware, LootFunction

public class CopyComponentsLootFunction extends ConditionalLootFunction
Mappings:
Namespace Name
named net/minecraft/loot/function/CopyComponentsLootFunction
intermediary net/minecraft/class_9317
official exo
  • Field Details

    • CODEC

      public static final com.mojang.serialization.MapCodec<CopyComponentsLootFunction> CODEC
      Mappings:
      Namespace Name Mixin selector
      named CODEC Lnet/minecraft/loot/function/CopyComponentsLootFunction;CODEC:Lcom/mojang/serialization/MapCodec;
      intermediary field_49430 Lnet/minecraft/class_9317;field_49430:Lcom/mojang/serialization/MapCodec;
      official a Lexo;a:Lcom/mojang/serialization/MapCodec;
    • source

      private final CopyComponentsLootFunction.Source source
      Mappings:
      Namespace Name Mixin selector
      named source Lnet/minecraft/loot/function/CopyComponentsLootFunction;source:Lnet/minecraft/loot/function/CopyComponentsLootFunction$Source;
      intermediary field_49431 Lnet/minecraft/class_9317;field_49431:Lnet/minecraft/class_9317$class_9319;
      official b Lexo;b:Lexo$b;
    • include

      private final Optional<List<ComponentType<?>>> include
      Mappings:
      Namespace Name Mixin selector
      named include Lnet/minecraft/loot/function/CopyComponentsLootFunction;include:Ljava/util/Optional;
      intermediary field_50202 Lnet/minecraft/class_9317;field_50202:Ljava/util/Optional;
      official c Lexo;c:Ljava/util/Optional;
    • exclude

      private final Optional<List<ComponentType<?>>> exclude
      Mappings:
      Namespace Name Mixin selector
      named exclude Lnet/minecraft/loot/function/CopyComponentsLootFunction;exclude:Ljava/util/Optional;
      intermediary field_50203 Lnet/minecraft/class_9317;field_50203:Ljava/util/Optional;
      official d Lexo;d:Ljava/util/Optional;
    • filter

      private final Predicate<ComponentType<?>> filter
      Mappings:
      Namespace Name Mixin selector
      named filter Lnet/minecraft/loot/function/CopyComponentsLootFunction;filter:Ljava/util/function/Predicate;
      intermediary field_50204 Lnet/minecraft/class_9317;field_50204:Ljava/util/function/Predicate;
      official e Lexo;e:Ljava/util/function/Predicate;
  • Constructor Details

    • CopyComponentsLootFunction

      CopyComponentsLootFunction(List<LootCondition> conditions, CopyComponentsLootFunction.Source source, Optional<List<ComponentType<?>>> include, Optional<List<ComponentType<?>>> exclude)
      Mappings:
      Namespace Name Mixin selector
      named <init> Lnet/minecraft/loot/function/CopyComponentsLootFunction;<init>(Ljava/util/List;Lnet/minecraft/loot/function/CopyComponentsLootFunction$Source;Ljava/util/Optional;Ljava/util/Optional;)V
      intermediary <init> Lnet/minecraft/class_9317;<init>(Ljava/util/List;Lnet/minecraft/class_9317$class_9319;Ljava/util/Optional;Ljava/util/Optional;)V
      official <init> Lexo;<init>(Ljava/util/List;Lexo$b;Ljava/util/Optional;Ljava/util/Optional;)V
  • Method Details

    • getType

      Specified by:
      getType in interface LootFunction
      Specified by:
      getType in class ConditionalLootFunction
      Mappings:
      Namespace Name Mixin selector
      named getType Lnet/minecraft/loot/function/LootFunction;getType()Lnet/minecraft/loot/function/LootFunctionType;
      intermediary method_29321 Lnet/minecraft/class_117;method_29321()Lnet/minecraft/class_5339;
      official b Leyc;b()Leyd;
    • getAllowedParameters

      public Set<ContextParameter<?>> getAllowedParameters()
      Mappings:
      Namespace Name Mixin selector
      named getAllowedParameters Lnet/minecraft/loot/context/LootContextAware;getAllowedParameters()Ljava/util/Set;
      intermediary method_293 Lnet/minecraft/class_46;method_293()Ljava/util/Set;
      official a Lewp;a()Ljava/util/Set;
    • process

      public ItemStack process(ItemStack stack, LootContext context)
      Specified by:
      process in class ConditionalLootFunction
      Mappings:
      Namespace Name Mixin selector
      named process Lnet/minecraft/loot/function/ConditionalLootFunction;process(Lnet/minecraft/item/ItemStack;Lnet/minecraft/loot/context/LootContext;)Lnet/minecraft/item/ItemStack;
      intermediary method_522 Lnet/minecraft/class_120;method_522(Lnet/minecraft/class_1799;Lnet/minecraft/class_47;)Lnet/minecraft/class_1799;
      official a Leyb;a(Lcxo;Lewo;)Lcxo;
    • builder

      Mappings:
      Namespace Name Mixin selector
      named builder Lnet/minecraft/loot/function/CopyComponentsLootFunction;builder(Lnet/minecraft/loot/function/CopyComponentsLootFunction$Source;)Lnet/minecraft/loot/function/CopyComponentsLootFunction$Builder;
      intermediary method_57637 Lnet/minecraft/class_9317;method_57637(Lnet/minecraft/class_9317$class_9319;)Lnet/minecraft/class_9317$class_9318;
      official a Lexo;a(Lexo$b;)Lexo$a;