2019-06-28 17:55:20 -04:00
|
|
|
CLASS net/minecraft/class_1914 net/minecraft/village/TradeOffer
|
|
|
|
FIELD field_18676 specialPrice I
|
|
|
|
FIELD field_18677 demandBonus I
|
|
|
|
FIELD field_18678 priceMultiplier F
|
2020-10-10 07:48:27 -04:00
|
|
|
FIELD field_18679 merchantExperience I
|
2019-06-28 17:55:20 -04:00
|
|
|
FIELD field_9143 secondBuyItem Lnet/minecraft/class_1799;
|
|
|
|
FIELD field_9144 maxUses I
|
|
|
|
FIELD field_9145 rewardingPlayerExperience Z
|
|
|
|
FIELD field_9146 firstBuyItem Lnet/minecraft/class_1799;
|
|
|
|
FIELD field_9147 uses I
|
|
|
|
FIELD field_9148 sellItem Lnet/minecraft/class_1799;
|
2019-07-08 12:09:22 -04:00
|
|
|
METHOD <init> (Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;IIF)V
|
2018-11-04 07:22:38 -05:00
|
|
|
ARG 1 buyItem
|
2019-02-13 11:31:54 -05:00
|
|
|
ARG 2 sellItem
|
2019-03-20 13:45:35 -04:00
|
|
|
ARG 3 maxUses
|
2021-03-13 16:18:04 -05:00
|
|
|
ARG 4 merchantExperience
|
2019-03-20 13:45:35 -04:00
|
|
|
ARG 5 priceMultiplier
|
2019-07-08 12:09:22 -04:00
|
|
|
METHOD <init> (Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;IIF)V
|
2019-02-13 11:31:54 -05:00
|
|
|
ARG 1 firstBuyItem
|
2018-11-04 07:22:38 -05:00
|
|
|
ARG 2 secondBuyItem
|
2019-02-13 11:31:54 -05:00
|
|
|
ARG 3 sellItem
|
2019-03-20 13:45:35 -04:00
|
|
|
ARG 4 maxUses
|
2021-03-13 16:18:04 -05:00
|
|
|
ARG 5 merchantExperience
|
2019-03-20 13:45:35 -04:00
|
|
|
ARG 6 priceMultiplier
|
2019-07-08 12:09:22 -04:00
|
|
|
METHOD <init> (Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;IIIF)V
|
2019-02-13 11:31:54 -05:00
|
|
|
ARG 1 firstBuyItem
|
2018-11-04 07:22:38 -05:00
|
|
|
ARG 2 secondBuyItem
|
|
|
|
ARG 3 sellItem
|
|
|
|
ARG 4 uses
|
2019-02-13 11:31:54 -05:00
|
|
|
ARG 5 maxUses
|
2021-03-13 16:18:04 -05:00
|
|
|
ARG 6 merchantExperience
|
2019-03-20 13:45:35 -04:00
|
|
|
ARG 7 priceMultiplier
|
2020-12-06 13:04:59 -05:00
|
|
|
METHOD <init> (Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;IIIFI)V
|
|
|
|
ARG 1 firstBuyItem
|
|
|
|
ARG 2 secondBuyItem
|
|
|
|
ARG 3 sellItem
|
|
|
|
ARG 4 uses
|
|
|
|
ARG 5 maxUses
|
2021-03-13 16:18:04 -05:00
|
|
|
ARG 6 merchantExperience
|
2020-12-06 13:04:59 -05:00
|
|
|
ARG 7 priceMultiplier
|
|
|
|
ARG 8 demandBonus
|
|
|
|
METHOD <init> (Lnet/minecraft/class_2487;)V
|
2021-04-02 17:03:30 -04:00
|
|
|
ARG 1 nbt
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_16952 matchesBuyItems (Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;)Z
|
2019-02-13 11:31:54 -05:00
|
|
|
ARG 1 first
|
|
|
|
ARG 2 second
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_16953 depleteBuyItems (Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;)Z
|
2021-01-31 12:06:03 -05:00
|
|
|
ARG 1 firstBuyStack
|
|
|
|
ARG 2 secondBuyStack
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_16954 acceptsBuy (Lnet/minecraft/class_1799;Lnet/minecraft/class_1799;)Z
|
2019-02-13 11:31:54 -05:00
|
|
|
ARG 1 given
|
|
|
|
ARG 2 sample
|
2021-03-13 16:18:04 -05:00
|
|
|
METHOD method_18019 copySellItem ()Lnet/minecraft/class_1799;
|
|
|
|
COMMENT Returns a copy of the sell item of this trade offer.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_19272 getAdjustedFirstBuyItem ()Lnet/minecraft/class_1799;
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns a copy of the first buy item of this trade offer,
|
|
|
|
COMMENT with its price adjusted depending on the demand bonus, the
|
|
|
|
COMMENT special price and the price multiplier.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_19273 setSpecialPrice (I)V
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Sets the special price of this trade offer to {@code specialPrice}.
|
2020-12-06 13:04:59 -05:00
|
|
|
ARG 1 specialPrice
|
2021-03-13 16:18:04 -05:00
|
|
|
METHOD method_19274 updateDemandBonus ()V
|
|
|
|
COMMENT Updates the demand bonus of this trade offer depending on its
|
|
|
|
COMMENT previous demand bonus, the number of times it has been used and
|
|
|
|
COMMENT its remaining uses.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_19275 resetUses ()V
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Resets the number of times this trade offer has been used.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_19276 clearSpecialPrice ()V
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Resets the special price of this trade offer.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_19277 getSpecialPrice ()I
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns the special price of this trade offer. It is used to
|
|
|
|
COMMENT adjust the price of its first buy item.
|
|
|
|
COMMENT
|
|
|
|
COMMENT <p>The less the special price is, the more the price will be low.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_19278 getPriceMultiplier ()F
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns the price multiplier of this trade offer. It is used to
|
|
|
|
COMMENT adjust the price of its first buy item.
|
2020-10-10 07:48:27 -04:00
|
|
|
METHOD method_19279 getMerchantExperience ()I
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns the amount of experience that will be given to a merchant
|
|
|
|
COMMENT after this trade offer has been used.
|
2019-09-12 09:28:23 -04:00
|
|
|
METHOD method_21725 getDemandBonus ()I
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns the demand bonus of this trade offer. It is used to
|
|
|
|
COMMENT adjust the price of its first buy item.
|
|
|
|
COMMENT
|
|
|
|
COMMENT <p>The more the demand bonus is, the more the price will be high.
|
|
|
|
COMMENT
|
|
|
|
COMMENT <p>It is updated when a villager restocks.
|
|
|
|
COMMENT
|
|
|
|
COMMENT @see #updateDemandBonus()
|
|
|
|
METHOD method_21834 hasBeenUsed ()Z
|
|
|
|
COMMENT Returns whether this trade offer has already been used.
|
|
|
|
COMMENT
|
|
|
|
COMMENT <p>Checks if the number of times this trade offer has been used
|
|
|
|
COMMENT is greater than 0.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_8244 use ()V
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Increments the number of times this trade offer has been used.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_8245 increaseSpecialPrice (I)V
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Increases the special price of this trade offer by {@code increment}.
|
|
|
|
COMMENT
|
|
|
|
COMMENT <p>A negative {@code increment} value will decrease the special price.
|
2020-12-06 13:04:59 -05:00
|
|
|
ARG 1 increment
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_8246 getOriginalFirstBuyItem ()Lnet/minecraft/class_1799;
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns the first buy item of this trade offer.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_8247 getSecondBuyItem ()Lnet/minecraft/class_1799;
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns the second buy item of this trade offer.
|
|
|
|
COMMENT
|
|
|
|
COMMENT <p>If there is no second buy item, this returns the {@linkplain ItemStack#EMPTY empty
|
|
|
|
COMMENT item stack}.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_8248 getMaxUses ()I
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns the maximum number of times this trade offer can be used.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_8249 getUses ()I
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns the number of times this trade offer has been used.
|
|
|
|
METHOD method_8250 getSellItem ()Lnet/minecraft/class_1799;
|
|
|
|
COMMENT Returns the sell item of this trade offer.
|
2021-02-17 13:16:46 -05:00
|
|
|
METHOD method_8251 toNbt ()Lnet/minecraft/class_2487;
|
2021-03-13 16:18:04 -05:00
|
|
|
METHOD method_8254 disable ()V
|
|
|
|
COMMENT Sets the number of times this trade offer has been used to
|
|
|
|
COMMENT its maximum uses, making it disabled.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_8255 isDisabled ()Z
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns whether this trade offer is disabled.
|
|
|
|
COMMENT
|
|
|
|
COMMENT <p>Checks if the number of times this trade offer has been used
|
|
|
|
COMMENT is greater or equal to its maximum uses.
|
2019-06-28 17:55:20 -04:00
|
|
|
METHOD method_8256 shouldRewardPlayerExperience ()Z
|
2021-03-13 16:18:04 -05:00
|
|
|
COMMENT Returns whether experience should be given to a player when
|
|
|
|
COMMENT they use this trade offer.
|