A zombie pigman is a neutral mob found in the Nether Wastes and Hell biomes. He is passive towards players unless provoked by attacking him or equipping a gold/gilded piece, either in hand or in armor slots. It wields either a ruby sword.
Zombie pigmans spawn in groups of 3-6 in nether wastes and hell biomes 5% of zombie pigmen spawn as babies, and 1% as ancient zombie pigmen.
On Death
Rotten Flesh: 0-1
Ruby Fragment: 0-1
Ruby: 2.5% chance (when killed by a player or tamed wolf)
Zombie Pigman Head: 2.5% (when killed by a player or tamed wolf)
XP: 5 (when killed by a player or tamed wolf)
Equipment
Adults have an 8.5% chance of dropping each naturally held or worn piece of equipment. The dropped item has a random durability. Each level of Looting used to kill the zombie pigman increases the drop chance for each piece of equipment by 1%.
Weapons
A zombie pigman naturally spawns with either of these weapons:
Ruby Sword
Crossbow
Bow
Armor
Zombie Pigman sometimes spawn with 1-4 normal or enchanted pieces of armor, which may be:
Ruby Helmet
Ruby Chestplate
Ruby Leggings
Ruby Boots
Zombie Pigmans cannot swim and can drown if submerged. They are immune to fire.
Zombie Pigs
When a zombie pigs or baby zombie pigs is struck by lightning, it transforms into a zombie pigman or baby zombie pigman, respectively.
Pigmans
A pigman that enters the Nether transforms into a zombie pigman after 15 seconds. When a pigman becomes a zombie, he keeps his profession and items.
Curing
Giving a zombie pigman the Strength effect and then feeding it a ruby carrot starts the curing process. After five minutes, it transforms into a piglin, displaying purple Nausea status effect particles for 10 seconds after being cured. (The zombie pigman must be in the overworld or the end, otherwise he will not be able to heal.)
Aggravation
Zombie Pigmen are neutral towards players as long as they do not equip any gold/gilded pieces in their hand/armor slot. Zombie Pigmen are provoked by any player who:
Holds/equips a golden/gilded piece.
Mid range, medium aggravation.
Attacks a zombie pig or zombie pigman, regardless if the player kills it in one hit or not.
Long range, heavy aggravation to the damaged zombie pigman, medium aggravation to other zombie pigmans.
Opens or breaks a chest, trapped chest, ender chest, shulker box, barrel, minecart with chest, or boat with chest.
Opening is short range, medium aggravation
Breaking is mid range, medium aggravation
Breaks a block of ruby, ruby ore, bloodstone ruby ore, nether ruby ore, deepslate ruby ore, and more.
Mid range, medium aggravation
Zombie Pigmans attack Piglins and Piglin Beasts. It also attacks any entity that holds/equips any ruby item, except those belonging to the following families: wither, skeleton, piglan, zombie piglan, zombie pigman, zombie piglin. They may occasionally hunt Hoglins.
Bartering
Zombie pigman can barter ruby for certain items, when a ruby is dropped near them or the player uses it while looking at them. The zombie pigman "examines" the ruby for eight seconds, then drops a random item from the chart. Zombie pigmans can also pick up items dropped by a dispenser or dropper.
Zombie Pigmans can pick up any items they come across, preferring ruby-related items, which they actively seek out.
Each zombie pigman has eight hidden inventory slots in which it can stack items. A zombie pigman with a full inventory does not attempt to pick up ruby-related items, except ruby.