Uses of Record Class
net.minecraft.advancements.Criterion
Package
Description
Classes for NeoForge's own data generation.
-
Uses of Criterion in net.minecraft.advancements
Modifier and TypeFieldDescriptionstatic final com.mojang.serialization.Codec
<Criterion<?>> Criterion.CODEC
Advancement.Builder.criteria
Advancement.criteria
The field for thecriteria
record component.Advancement.CRITERIA_CODEC
private static final com.mojang.serialization.MapCodec
<Criterion<?>> Criterion.MAP_CODEC
Modifier and TypeMethodDescriptionAdvancement.criteria()
Returns the value of thecriteria
record component.private static <T extends CriterionTriggerInstance>
com.mojang.serialization.Codec<Criterion<T>> Criterion.criterionCodec
(CriterionTrigger<T> p_312665_) Modifier and TypeMethodDescriptionAdvancement.Builder.addCriterion
(String p_138384_, Criterion<?> p_138385_) ModifierConstructorDescriptionAdvancement
(Optional<ResourceLocation> p_300893_, Optional<DisplayInfo> p_301147_, AdvancementRewards p_286389_, Map<String, Criterion<?>> p_286635_, AdvancementRequirements p_301002_, boolean p_286478_) Advancement
(Optional<ResourceLocation> parent, Optional<DisplayInfo> display, AdvancementRewards rewards, Map<String, Criterion<?>> criteria, AdvancementRequirements requirements, boolean sendsTelemetryEvent, Optional<Component> name) Creates an instance of aAdvancement
record class. -
Uses of Criterion in net.minecraft.advancements.critereon
Modifier and TypeMethodDescriptionItemUsedOnLocationTrigger.TriggerInstance.allayDropItemOnBlock
(LocationPredicate.Builder p_286325_, ItemPredicate.Builder p_286531_) PlayerTrigger.TriggerInstance.avoidVibration()
BredAnimalsTrigger.TriggerInstance.bredAnimals()
BredAnimalsTrigger.TriggerInstance.bredAnimals
(Optional<EntityPredicate> p_301067_, Optional<EntityPredicate> p_301159_, Optional<EntityPredicate> p_301056_) BredAnimalsTrigger.TriggerInstance.bredAnimals
(EntityPredicate.Builder p_301285_) BrewedPotionTrigger.TriggerInstance.brewedPotion()
ChangeDimensionTrigger.TriggerInstance.changedDimension()
ChangeDimensionTrigger.TriggerInstance.changedDimension
(ResourceKey<Level> p_301026_, ResourceKey<Level> p_301124_) ChangeDimensionTrigger.TriggerInstance.changedDimensionFrom
(ResourceKey<Level> p_147564_) ChangeDimensionTrigger.TriggerInstance.changedDimensionTo
(ResourceKey<Level> p_19783_) ItemDurabilityTrigger.TriggerInstance.changedDurability
(Optional<ContextAwarePredicate> p_299196_, Optional<ItemPredicate> p_299039_, MinMaxBounds.Ints p_286730_) ItemDurabilityTrigger.TriggerInstance.changedDurability
(Optional<ItemPredicate> p_299020_, MinMaxBounds.Ints p_151288_) ChanneledLightningTrigger.TriggerInstance.channeledLightning
(EntityPredicate.Builder... p_298972_) ConstructBeaconTrigger.TriggerInstance.constructedBeacon()
ConstructBeaconTrigger.TriggerInstance.constructedBeacon
(MinMaxBounds.Ints p_301138_) RecipeCraftedTrigger.TriggerInstance.craftedItem
(ResourceLocation p_283538_) RecipeCraftedTrigger.TriggerInstance.craftedItem
(ResourceLocation p_282794_, List<ItemPredicate.Builder> p_281369_) RecipeCraftedTrigger.TriggerInstance.crafterCraftedItem
(ResourceLocation p_335404_) KilledByCrossbowTrigger.TriggerInstance.crossbowKilled
(EntityPredicate.Builder... p_301077_) KilledByCrossbowTrigger.TriggerInstance.crossbowKilled
(MinMaxBounds.Ints p_301148_) CuredZombieVillagerTrigger.TriggerInstance.curedZombieVillager()
BeeNestDestroyedTrigger.TriggerInstance.destroyedBeeNest
(Block p_17513_, ItemPredicate.Builder p_17514_, MinMaxBounds.Ints p_17515_) EnchantedItemTrigger.TriggerInstance.enchantedItem()
EnterBlockTrigger.TriggerInstance.entersBlock
(Block p_31298_) EntityHurtPlayerTrigger.TriggerInstance.entityHurtPlayer()
EntityHurtPlayerTrigger.TriggerInstance.entityHurtPlayer
(DamagePredicate p_300967_) EntityHurtPlayerTrigger.TriggerInstance.entityHurtPlayer
(DamagePredicate.Builder p_301174_) KilledTrigger.TriggerInstance.entityKilledPlayer()
KilledTrigger.TriggerInstance.entityKilledPlayer
(Optional<EntityPredicate> p_298209_) KilledTrigger.TriggerInstance.entityKilledPlayer
(Optional<EntityPredicate> p_298878_, Optional<DamageSourcePredicate> p_300913_) KilledTrigger.TriggerInstance.entityKilledPlayer
(Optional<EntityPredicate> p_301135_, DamageSourcePredicate.Builder p_301143_) KilledTrigger.TriggerInstance.entityKilledPlayer
(EntityPredicate.Builder p_298389_) KilledTrigger.TriggerInstance.entityKilledPlayer
(EntityPredicate.Builder p_152119_, Optional<DamageSourcePredicate> p_301181_) KilledTrigger.TriggerInstance.entityKilledPlayer
(EntityPredicate.Builder p_301108_, DamageSourcePredicate.Builder p_298860_) FallAfterExplosionTrigger.TriggerInstance.fallAfterExplosion
(DistancePredicate p_335666_, EntityPredicate.Builder p_335823_) DistanceTrigger.TriggerInstance.fallFromHeight
(EntityPredicate.Builder p_186198_, DistancePredicate p_186199_, LocationPredicate.Builder p_299057_) FilledBucketTrigger.TriggerInstance.filledBucket
(ItemPredicate.Builder p_300965_) FishingRodHookedTrigger.TriggerInstance.fishedItem
(Optional<ItemPredicate> p_298233_, Optional<EntityPredicate> p_298660_, Optional<ItemPredicate> p_298847_) EffectsChangedTrigger.TriggerInstance.gotEffectsFrom
(EntityPredicate.Builder p_300971_) EffectsChangedTrigger.TriggerInstance.hasEffects
(MobEffectsPredicate.Builder p_299317_) InventoryChangeTrigger.TriggerInstance.hasItems
(ItemPredicate... p_43198_) InventoryChangeTrigger.TriggerInstance.hasItems
(ItemPredicate.Builder... p_298231_) ItemUsedOnLocationTrigger.TriggerInstance.itemUsedOnBlock
(LocationPredicate.Builder p_286808_, ItemPredicate.Builder p_286486_) PlayerInteractTrigger.TriggerInstance.itemUsedOnEntity
(Optional<ContextAwarePredicate> p_299056_, ItemPredicate.Builder p_286289_, Optional<ContextAwarePredicate> p_301218_) PlayerInteractTrigger.TriggerInstance.itemUsedOnEntity
(ItemPredicate.Builder p_286235_, Optional<ContextAwarePredicate> p_298893_) LevitationTrigger.TriggerInstance.levitated
(DistancePredicate p_49145_) LightningStrikeTrigger.TriggerInstance.lightningStrike
(Optional<EntityPredicate> p_301078_, Optional<EntityPredicate> p_301001_) PlayerTrigger.TriggerInstance.located
(Optional<EntityPredicate> p_301141_) PlayerTrigger.TriggerInstance.located
(EntityPredicate.Builder p_300962_) PlayerTrigger.TriggerInstance.located
(LocationPredicate.Builder p_301139_) UsingItemTrigger.TriggerInstance.lookingAt
(EntityPredicate.Builder p_163884_, ItemPredicate.Builder p_163885_) LootTableTrigger.TriggerInstance.lootTableUsed
(ResourceKey<LootTable> p_335395_) ItemUsedOnLocationTrigger.TriggerInstance.placedBlock
(Block p_301158_) ItemUsedOnLocationTrigger.TriggerInstance.placedBlock
(LootItemCondition.Builder... p_301013_) PlayerHurtEntityTrigger.TriggerInstance.playerHurtEntity()
PlayerHurtEntityTrigger.TriggerInstance.playerHurtEntity
(Optional<DamagePredicate> p_301287_, Optional<EntityPredicate> p_300951_) PlayerHurtEntityTrigger.TriggerInstance.playerHurtEntity
(Optional<EntityPredicate> p_298252_) PlayerHurtEntityTrigger.TriggerInstance.playerHurtEntity
(DamagePredicate.Builder p_301281_, Optional<EntityPredicate> p_298362_) PlayerHurtEntityTrigger.TriggerInstance.playerHurtEntityWithDamage
(Optional<DamagePredicate> p_300880_) PlayerHurtEntityTrigger.TriggerInstance.playerHurtEntityWithDamage
(DamagePredicate.Builder p_300924_) KilledTrigger.TriggerInstance.playerKilledEntity()
KilledTrigger.TriggerInstance.playerKilledEntity
(Optional<EntityPredicate> p_298999_) KilledTrigger.TriggerInstance.playerKilledEntity
(Optional<EntityPredicate> p_300920_, Optional<DamageSourcePredicate> p_300985_) KilledTrigger.TriggerInstance.playerKilledEntity
(Optional<EntityPredicate> p_299297_, DamageSourcePredicate.Builder p_301016_) KilledTrigger.TriggerInstance.playerKilledEntity
(EntityPredicate.Builder p_48137_) KilledTrigger.TriggerInstance.playerKilledEntity
(EntityPredicate.Builder p_300879_, Optional<DamageSourcePredicate> p_298956_) KilledTrigger.TriggerInstance.playerKilledEntity
(EntityPredicate.Builder p_152106_, DamageSourcePredicate.Builder p_301319_) KilledTrigger.TriggerInstance.playerKilledEntityNearSculkCatalyst()
StartRidingTrigger.TriggerInstance.playerStartsRiding
(EntityPredicate.Builder p_160402_) PlayerTrigger.TriggerInstance.raidWon()
DistanceTrigger.TriggerInstance.rideEntityInLava
(EntityPredicate.Builder p_186195_, DistancePredicate p_186196_) ShotCrossbowTrigger.TriggerInstance.shotCrossbow
(Optional<ItemPredicate> p_300988_) ShotCrossbowTrigger.TriggerInstance.shotCrossbow
(ItemLike p_301042_) PlayerTrigger.TriggerInstance.sleptInBed()
SlideDownBlockTrigger.TriggerInstance.slidesDownBlock
(Block p_67007_) SummonedEntityTrigger.TriggerInstance.summonedEntity
(EntityPredicate.Builder p_68276_) TameAnimalTrigger.TriggerInstance.tamedAnimal()
TameAnimalTrigger.TriggerInstance.tamedAnimal
(EntityPredicate.Builder p_301051_) TargetBlockTrigger.TriggerInstance.targetHit
(MinMaxBounds.Ints p_286700_, Optional<ContextAwarePredicate> p_298563_) PickedUpItemTrigger.TriggerInstance.thrownItemPickedUpByEntity
(ContextAwarePredicate p_286865_, Optional<ItemPredicate> p_299099_, Optional<ContextAwarePredicate> p_299117_) PickedUpItemTrigger.TriggerInstance.thrownItemPickedUpByPlayer
(Optional<ContextAwarePredicate> p_298917_, Optional<ItemPredicate> p_298224_, Optional<ContextAwarePredicate> p_298405_) PlayerTrigger.TriggerInstance.tick()
TradeTrigger.TriggerInstance.tradedWithVillager()
TradeTrigger.TriggerInstance.tradedWithVillager
(EntityPredicate.Builder p_191437_) DistanceTrigger.TriggerInstance.travelledThroughNether
(DistancePredicate p_186193_) RecipeUnlockedTrigger.unlocked
(ResourceLocation p_63729_) ConsumeItemTrigger.TriggerInstance.usedItem()
ConsumeItemTrigger.TriggerInstance.usedItem
(ItemPredicate.Builder p_300855_) UsedTotemTrigger.TriggerInstance.usedTotem
(ItemPredicate p_163725_) PlayerTrigger.TriggerInstance.walkOnBlockWithEquipment
(Block p_222638_, Item p_222639_) -
Uses of Criterion in net.minecraft.data.advancements.packs
Modifier and TypeMethodDescriptionprivate static Criterion
<LightningStrikeTrigger.TriggerInstance> VanillaAdventureAdvancements.fireCountAndBystander
(MinMaxBounds.Ints p_252298_, Optional<EntityPredicate> p_299106_) private static Criterion
<UsingItemTrigger.TriggerInstance> VanillaAdventureAdvancements.lookAtThroughItem
(EntityType<?> p_249703_, Item p_250746_) private static Criterion
<ItemUsedOnLocationTrigger.TriggerInstance> VanillaAdventureAdvancements.placedBlockReadByComparator
(Block p_286401_) private static Criterion
<ItemUsedOnLocationTrigger.TriggerInstance> VanillaAdventureAdvancements.placedComparatorReadingBlock
(Block p_286250_) -
Uses of Criterion in net.minecraft.data.recipes
Modifier and TypeFieldDescriptionShapedRecipeBuilder.criteria
ShapelessRecipeBuilder.criteria
SimpleCookingRecipeBuilder.criteria
SingleItemRecipeBuilder.criteria
SmithingTransformRecipeBuilder.criteria
SmithingTrimRecipeBuilder.criteria
Modifier and TypeMethodDescriptionprotected static Criterion
<InventoryChangeTrigger.TriggerInstance> RecipeProvider.has
(MinMaxBounds.Ints p_176521_, ItemLike p_176522_) protected static Criterion
<InventoryChangeTrigger.TriggerInstance> protected static Criterion
<InventoryChangeTrigger.TriggerInstance> protected static Criterion
<EnterBlockTrigger.TriggerInstance> protected static Criterion
<InventoryChangeTrigger.TriggerInstance> RecipeProvider.inventoryTrigger
(ItemPredicate... p_126012_) protected static Criterion
<InventoryChangeTrigger.TriggerInstance> RecipeProvider.inventoryTrigger
(ItemPredicate.Builder... p_299111_) Modifier and TypeMethodDescriptionRecipeBuilder.unlockedBy
(String p_176496_, Criterion<?> p_301065_) ShapedRecipeBuilder.unlockedBy
(String p_126133_, Criterion<?> p_301126_) ShapelessRecipeBuilder.unlockedBy
(String p_176781_, Criterion<?> p_300897_) SimpleCookingRecipeBuilder.unlockedBy
(String p_176792_, Criterion<?> p_300970_) SingleItemRecipeBuilder.unlockedBy
(String p_176810_, Criterion<?> p_301267_) -
Uses of Criterion in net.minecraft.server
Modifier and TypeMethodDescriptionprivate <T extends CriterionTriggerInstance>
voidPlayerAdvancements.registerListener
(AdvancementHolder p_301059_, String p_300946_, Criterion<T> p_300887_) private <T extends CriterionTriggerInstance>
voidPlayerAdvancements.removeListener
(AdvancementHolder p_301213_, String p_301253_, Criterion<T> p_301311_) -
Uses of Criterion in net.neoforged.neoforge.common.data.internal
Modifier and TypeFieldDescriptionprivate final List
<BiFunction<Criterion<?>, HolderLookup.Provider, Criterion<?>>> NeoForgeAdvancementProvider.NeoForgeAdvancementGenerator.criteriaReplacers
The field for thecriteriaReplacers
record component.private final List
<BiFunction<Criterion<?>, HolderLookup.Provider, Criterion<?>>> NeoForgeAdvancementProvider.NeoForgeAdvancementGenerator.criteriaReplacers
The field for thecriteriaReplacers
record component.Modifier and TypeMethodDescriptionprivate static <T extends SimpleCriterionTrigger.SimpleInstance>
Criterion<T> NeoForgeAdvancementProvider.replacePlayerPredicate
(Criterion<T> old, ContextAwarePredicate newPlayer, HolderLookup.Provider registries) Modifier and TypeMethodDescriptionNeoForgeAdvancementProvider.NeoForgeAdvancementGenerator.criteriaReplacers()
Returns the value of thecriteriaReplacers
record component.NeoForgeAdvancementProvider.NeoForgeAdvancementGenerator.criteriaReplacers()
Returns the value of thecriteriaReplacers
record component.private static BiFunction
<Criterion<?>, HolderLookup.Provider, Criterion<?>> NeoForgeAdvancementProvider.replaceInteractCriteria
(ItemPredicate replacement, ItemLike... targetItem) private static BiFunction
<Criterion<?>, HolderLookup.Provider, Criterion<?>> NeoForgeAdvancementProvider.replaceInteractCriteria
(ItemPredicate replacement, ItemLike... targetItem) private static BiFunction
<Criterion<?>, HolderLookup.Provider, Criterion<?>> NeoForgeAdvancementProvider.replaceMatchToolCriteria
(ToolAction toolAction, ItemLike... targetItem) private static BiFunction
<Criterion<?>, HolderLookup.Provider, Criterion<?>> NeoForgeAdvancementProvider.replaceMatchToolCriteria
(ToolAction toolAction, ItemLike... targetItem) private static BiFunction
<Criterion<?>, HolderLookup.Provider, Criterion<?>> NeoForgeAdvancementProvider.replacePlayerPredicate
(UnaryOperator<LootItemCondition> replacer, Predicate<LootItemCondition> shouldSkipReplacement) private static BiFunction
<Criterion<?>, HolderLookup.Provider, Criterion<?>> NeoForgeAdvancementProvider.replacePlayerPredicate
(UnaryOperator<LootItemCondition> replacer, Predicate<LootItemCondition> shouldSkipReplacement) private static BiFunction
<Criterion<?>, HolderLookup.Provider, Criterion<?>> NeoForgeAdvancementProvider.replaceWearingPredicate
(EntityPredicate replacement, Predicate<EntityEquipmentPredicate> shouldReplace) private static BiFunction
<Criterion<?>, HolderLookup.Provider, Criterion<?>> NeoForgeAdvancementProvider.replaceWearingPredicate
(EntityPredicate replacement, Predicate<EntityEquipmentPredicate> shouldReplace) Modifier and TypeMethodDescriptionprivate static <T extends SimpleCriterionTrigger.SimpleInstance>
Criterion<T> NeoForgeAdvancementProvider.replacePlayerPredicate
(Criterion<T> old, ContextAwarePredicate newPlayer, HolderLookup.Provider registries) ModifierConstructorDescriptionprivate
NeoForgeAdvancementGenerator
(AdvancementSubProvider vanillaProvider, List<BiFunction<Criterion<?>, HolderLookup.Provider, Criterion<?>>> criteriaReplacers) Creates an instance of aNeoForgeAdvancementGenerator
record class.private
NeoForgeAdvancementGenerator
(AdvancementSubProvider vanillaProvider, List<BiFunction<Criterion<?>, HolderLookup.Provider, Criterion<?>>> criteriaReplacers) Creates an instance of aNeoForgeAdvancementGenerator
record class.