Create a procedure Trigger: entity is attacked if provided damage type = explosion if item in armor slot 3 = explosion immunity helmet And if item in armor slot 2 = explosion immunity chestplate And if item in armor slot 1 = explosion immunity leggings And if item in armor slot 0 = explosion immunity boots Then cancel procedure/trigger.
Create a procedure
Trigger: entity is attacked
if provided damage type = explosion
if item in armor slot 3 = explosion immunity helmet
And if item in armor slot 2 = explosion immunity chestplate
And if item in armor slot 1 = explosion immunity leggings
And if item in armor slot 0 = explosion immunity boots
Then cancel procedure/trigger.