Add option to disable zombie villagers cure

This commit is contained in:
rafael59r2
2025-01-12 13:16:46 -08:00
committed by granny
parent 18a5a3c335
commit 2949506adb
3 changed files with 8 additions and 41 deletions

View File

@@ -1,7 +1,11 @@
--- a/net/minecraft/world/entity/monster/ZombieVillager.java
+++ b/net/minecraft/world/entity/monster/ZombieVillager.java
@@ -159,7 +_,7 @@
if (this.hasEffect(MobEffects.WEAKNESS)) {
@@ -156,10 +_,10 @@
public InteractionResult mobInteract(Player player, InteractionHand hand) {
ItemStack itemInHand = player.getItemInHand(hand);
if (itemInHand.is(Items.GOLDEN_APPLE)) {
- if (this.hasEffect(MobEffects.WEAKNESS)) {
+ if (this.hasEffect(MobEffects.WEAKNESS) && level().purpurConfig.zombieVillagerCureEnabled) { // Purpur - Add option to disable zombie villagers cure
itemInHand.consume(1, player);
if (!this.level().isClientSide) {
- this.startConverting(player.getUUID(), this.random.nextInt(2401) + 3600);