Skip to content

Commit

Permalink
Fix advancements
Browse files Browse the repository at this point in the history
  • Loading branch information
EngineMachiner committed Sep 29, 2024
1 parent 327bd1c commit eb18e5f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -175,14 +175,13 @@ class Advancements( generator: FabricDataGenerator ) : FabricAdvancementProvider

override fun conditions(): AbstractCriterionConditions {

val range = NumberRange.IntRange.atLeast(2)
val range = NumberRange.IntRange.ANY
val enchantmentPredicate = EnchantmentPredicate( enchantment, range )
val player = EntityPredicate.Extended.create()

val itemPredicate = ItemPredicate.Builder.create().tag(tag)
.enchantment( enchantmentPredicate ).build()
val predicate = ItemPredicate.Builder.create()
.enchantment( enchantmentPredicate ).tag(tag).build()

return EnchantedItemCriterion.Conditions( player, itemPredicate, range )
return InventoryChangedCriterion.Conditions.items(predicate)

}

Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/assets/honkytones/lang/en_us.json
Original file line number Diff line number Diff line change
Expand Up @@ -182,13 +182,13 @@

"honkytones.advancements.root.description": "Get your first instrument.",

"honkytones.advancements.doot.description": "Steal a skeleton's trumpet.",
"honkytones.advancements.doot.description": "Kill a skeleton that uses a trumpet.",

"honkytones.advancements.keyboard.title": "Classic",
"honkytones.advancements.keyboard.description": "Craft a keyboard.",

"honkytones.advancements.enchantment.title": "Musical projectiles",
"honkytones.advancements.enchantment.description": "Enchant an instrument with the ranged enchantment.",
"honkytones.advancements.enchantment.description": "Get an instrument with the ranged enchantment.",

"honkytones.advancements.instrument.description": "Obtain the instrument.",

Expand Down
4 changes: 2 additions & 2 deletions src/main/resources/assets/honkytones/lang/es_ec.json
Original file line number Diff line number Diff line change
Expand Up @@ -182,13 +182,13 @@

"honkytones.advancements.root.description": "Obten tu primer instrumento.",

"honkytones.advancements.doot.description": "Toma la trompeta de un esqueleto.",
"honkytones.advancements.doot.description": "Mata un esqueleto con trompeta.",

"honkytones.advancements.keyboard.title": "Clasico",
"honkytones.advancements.keyboard.description": "Fabrica un teclado.",

"honkytones.advancements.enchantment.title": "Proyectiles musicales",
"honkytones.advancements.enchantment.description": "Encanta un instrumento con el encantamiento de rango.",
"honkytones.advancements.enchantment.description": "Obten un instrumento con el encantamiento de rango.",

"honkytones.advancements.instrument.description": "Obten el instrumento.",

Expand Down

0 comments on commit eb18e5f

Please sign in to comment.