mojira.dev
MC-96261

Lightning turns Villager with "Invulnerable" into witch

If you summon a villager with the command

/summon Villager ~ ~ ~3 {Invulnerable:1,CustomName:Tim,Profession:2,Career:1,NoAI:1,CareerLevel:4}

and summon a lightning with

/summon LightningBolt

the villager gets morphed into a witch, and also loses the invulnerability.

This is a problem, since we use custom villagers as traders on our server, and with thunderstorms we lose them from time to time.

I would rather expect the "Invulnerability" flag to protect them not only from damage, but also from the morph-effect from lightning strikes.
I understand, that the current state is "the morphing of an entity is not prevented by the invulnerable flag, because the lightning does not call the damage trigger event in the code".

If this is WAI, this may be closed, but I found no source confirming that invulnerability is not MEANT to provide immunity against the effects of lightning strike.

Linked issues

Comments 6

invulnerable litirally means won't take damage, morphing doesn't damage an entity, for feature suggestions/chages go to the reddit page

This is not a suggestion. The "Invulnerable" tag is not on the witch, even though when an "Invulnerable" Villager is struck by Lighting. Also confirmed for 16w04a.

@unknown that's not what this report is about, that's MC-88967

Oh, I see, I didn't read until the end. Work as Intended. Please close issue.

Thanks for your feedback!

I understand, that the current state is "the morphing of an entity is not prevented by the invulnerable flag, because the lightning does not call the damage trigger event in the code".
Though I would consider this a bug until I read an official statement, that "invulnerable" actually is not meant to protect against morphing.

If you can provide a resource containing an official statement/explanation, that the current design is WAI this may as well be closed 🙂

I will then go to reddit and suggest a separate tag for immunity against lightning strike morphing. There apparently is no other flag to achieve such immunity, or am I missing something?

(updated the initial issue)

It has never been mentioned it does prevent it, that already makes this a feature request

Paul Wiedebusch

Erik Broes

Unconfirmed

Minecraft 1.8.9, Minecraft 16w04a

Retrieved