From 55c122e98733d5f7400138e340e9d3fb57af9d33 Mon Sep 17 00:00:00 2001 From: Juuxel <6596629+Juuxel@users.noreply.github.com> Date: Mon, 23 Aug 2021 00:15:46 +0300 Subject: [PATCH] Rename and document HoeItem tilling names (#2635) * Rename and document HoeItem tilling names - TILLED_BLOCKS -> TILLING_ACTIONS (it's not a pure block->block map anymore) - getTillingConsumer -> getTillingAction: more descriptive this way - usagePredicate -> canUse: more conventional and descriptive name for a boolean-returning method * HoeItem.canUse -> canTill * Address code review * Code review part II * Update mappings/net/minecraft/item/HoeItem.mapping Co-authored-by: liach <7806504+liach@users.noreply.github.com> Co-authored-by: liach <7806504+liach@users.noreply.github.com> --- mappings/net/minecraft/item/HoeItem.mapping | 25 +++++++++++++++------ 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/mappings/net/minecraft/item/HoeItem.mapping b/mappings/net/minecraft/item/HoeItem.mapping index 707a329c53..5ee7f048d0 100644 --- a/mappings/net/minecraft/item/HoeItem.mapping +++ b/mappings/net/minecraft/item/HoeItem.mapping @@ -1,5 +1,9 @@ CLASS net/minecraft/class_1794 net/minecraft/item/HoeItem - FIELD field_8023 TILLED_BLOCKS Ljava/util/Map; + FIELD field_8023 TILLING_ACTIONS Ljava/util/Map; + COMMENT A map of input blocks to predicate-consumer action pairs. + COMMENT + COMMENT
Tilling works so that if the predicate succeeds, the consumer (the real action)
+ COMMENT is executed, and the hoe is damaged.
METHOD