aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinnea Gräf <nea@nea.moe>2024-04-02 03:51:48 +0200
committerLinnea Gräf <nea@nea.moe>2024-04-02 03:51:48 +0200
commite55c465baef38bbfb0684bf20d2e4b87aa166705 (patch)
tree093122c1fff23fdfb8fbc144e239723cea6090df
parent94455031f150c4fb7120f7eba1d2ae5ce0694087 (diff)
downloadpotato-crimes-e55c465baef38bbfb0684bf20d2e4b87aa166705.tar.gz
potato-crimes-e55c465baef38bbfb0684bf20d2e4b87aa166705.tar.bz2
potato-crimes-e55c465baef38bbfb0684bf20d2e4b87aa166705.zip
Only trade with potato villager
-rw-r--r--src/main/java/moe/nea/potatocrime/mixin/ShillCarrotsToVillagerPatch.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/moe/nea/potatocrime/mixin/ShillCarrotsToVillagerPatch.java b/src/main/java/moe/nea/potatocrime/mixin/ShillCarrotsToVillagerPatch.java
index f4e3079..205f51d 100644
--- a/src/main/java/moe/nea/potatocrime/mixin/ShillCarrotsToVillagerPatch.java
+++ b/src/main/java/moe/nea/potatocrime/mixin/ShillCarrotsToVillagerPatch.java
@@ -30,7 +30,7 @@ public abstract class ShillCarrotsToVillagerPatch extends MerchantEntity {
@Inject(method = "interactMob", at = @At("HEAD"), cancellable = true)
private void onInteractMob(PlayerEntity player, Hand hand, CallbackInfoReturnable<ActionResult> cir) {
var itemInHand = player.getStackInHand(hand);
- if (this.isAlive() && !this.hasCustomer() && !this.isSleeping()) {
+ if (this.isAlive() && !this.hasCustomer() && !this.isSleeping() && this.method_58842()) { // method_58842 = isPotato
if (itemInHand.isOf(Items.CARROT)) {
if (!isClient()) {
playSound(SoundEvents.ENTITY_VILLAGER_TRADE);