Parrots are supposed to imitate piglin brutes, because they are hostile mobs. However, after testing, the parrots never made any piglin brute sounds.
What I expected to happen was...:
The parrots made high pitched piglin brute snorting, with the "Parrot snorts mightily" subtitle.
What actually happened was...:
The parrots did not imitate the piglin brute like they do to other hostile mobs.
Steps to Reproduce:
1. Have a piglin brute and some parrots
2. ❌ No parrots made any piglin brute sounds.
Code analysis
Code analysis by @unknown can be found in this comment
Linked issues
Attachments
Comments 6
I added two new screenshots.
In the next screenshot, there are parrots, piglin brutes, and ravagers (with NoAI:1b so they don't escape the pens). The parrots imitated the ravager, but not the piglin brute.
After that, there are parrots and a piglin brute, but the parrots did not make any piglin brute imitation sounds.
Code analysis
The sound event is specified and registered, with a proper sound associated with it:
// In net.minecraft.sound.SoundEvents
public static final SoundEvent ENTITY_PARROT_IMITATE_PIGLIN = register("entity.parrot.imitate.piglin");
public static final SoundEvent ENTITY_PARROT_IMITATE_PIGLIN_BRUTE = register("entity.parrot.imitate.piglin_brute");
However, unlike piglins, which can be imitated by parrots, piglin brutes are not added to the map of entity types to imitation sounds for parrots:
// In net.minecraft.entity.passive.ParrotEntity
MOB_SOUNDS = Util.make(Maps.newHashMap(), imitations -> {
imitations.put(EntityType.PIGLIN, SoundEvents.ENTITY_PARROT_IMITATE_PIGLIN);
// No piglin brute here :(
});
Because of this, the entity.parrot.imitate.piglin_brute
sound event will never play.
Here is a mod with the aforementioned fix:
GitHub: https://github.com/haykam821/Brute-Imitation/releases/tag/1.0.0
CurseForge (when approved): https://www.curseforge.com/minecraft/mc-mods/brute-imitation/files/2997033
/playsound works, and it seems like there is a sound "minecraft:entity.parrot.imitate.piglin_brute" but with so many parrots and a piglin brute, the parrots still do not actually imitate them.
Edit: For clarification, the sound for parrots imitating piglin brutes do exist, but after lots of experimentation, I am positive the parrots haven't actually made those piglin brute sounds, despite the piglin brute being adjacent to them.