mojira.dev
MC-302815

Zombified piglins spawned from lightning striking a pig do not have a chance to hold a golden spear

Zombified piglins spawned from lightning striking a pig do not have a chance to hold a golden spear instead of a golden sword. This may also affect reinforcements and spawning from portals, I’ve yet to test those cases extensively.

To reproduce (lightning)

  1. /gamerule commandBlockOutput false

  2. Place a repeating command block facing upwards with execute positioned ~ ~2 ~ summon pig summon minecraft:lightning_bolt as @n[type=minecraft:zombified_piglin] unless entity @s[nbt={equipment:{mainhand:{id:"golden_spear"}}}] run teleport @s ~ -128 ~

  3. Place a chain command block on top of it with execute if entity @e[type=minecraft:zombified_piglin,nbt={equipment:{mainhand:{id:"golden_spear"}}},distance=..2] run say He's got a spear!

  4. Power the repeating command block

Expected behavior

A message would be printed to indicate that a zombified piglin spawned with a spear (said zombified piglin would be killed by lightning before long).

Comments 0

No comments.

clamlol

(Unassigned)

1499344

Confirmed

Expansion A

Low

Mob spawning

25w41a

Retrieved