dasher2023_10.

Make a Fabric 26.3 mod that brings back the 1.16.x piglin duping method. Where if you give a baby piglin an item, hit it until its 1 shot, and then gave it gold, and when it started looking at the gold, you would kill it and it drops two of that one item you gave it (dupe). And make it only server-sided

Kodari AI
KodariOct 10 at 11:40 pm 2
PiglinDupeRevival
Server-side Fabric mod restoring the 1.16.x piglin item duplication exploit. When a baby piglin is given an item, reduced to one health point, then given gold ingots, the piglin enters a dupe-ready state. Killing the piglin while it is distracted by the gold causes it to drop two copies of the originally given item instead of one. The mod tracks item stacks, health thresholds, and gold interaction timings per piglin entity. Includes configuration options to toggle the mechanic, adjust health requirements, and set dupe cooldowns. Fully client-compatible with no client-side code required.
  1. Identify the vanilla piglin barter/pickup flow and a server-safe hook.

  2. Create the 26.3 Fabric project and implement the baby-piglin duplication behavior.

Created the Fabric 26.3 mod. A baby piglin must pick up a player-dropped non-gold item, be damaged to 1 health or less, then begin inspecting gold. If it dies within one game tick of starting to inspect, the tracked item stack is duplicated.

The mod adds no items or recipes; use it in survival with a baby piglin, a dropped item, and a gold ingot. The behavior runs server-side, with no client code.

dasher2023_10.

No, don't make it so that it has to be one health, make it so that only if it gets one shot by anything, not just being one health

Kodari AI
KodariOct 11 at 12:04 am 1

Changed the eligibility check from a fixed 1-health threshold to the damage from a single hit: a baby piglin qualifies when its remaining health is no greater than that hit’s damage. Its health no longer needs to be exactly 1 when it starts inspecting gold.

Kodari can make mistakes. Review important code before using.
Files
src
build.gradle
gradle.properties
settings.gradle
Code
8 216
src/main/java/dev/kodari/piglindupe/PiglinDupeMod.java
package dev.kodari.piglindupe;

import net.fabricmc.api.ModInitializer;

public final class PiglinDupeMod implements ModInitializer {
    @Override
    public void onInitialize() {
        DuplicationTracker.initialize();
    }
}