Corrosive Mage (5e Feat)
From D&D Wiki
Prerequisites: The ability to cast at least one spell
You have learned to imbue your magic with an abrasive nature that, over time, can erode away even the strongest resistance
When you gain this feat, choose one of the following damage types: acid, cold, fire, lightning, or thunder. When you cast a spell that deals your chosen damage type they have an additional effect. After dealing damage (or attempting to if creature has Absorption or Immunity), the target loses a level of resistance to your damage of that type
The effect can stack multiple times, reducing resistance further, however at the end of their turn targets make a constitution saving throw. On a success they remove a stack and lower the total reduction to the appropriate level
Absorption is treated as immunity, Immunity as resistance, Resistance is ignored, Normal and vulnerable creatures take an additional 1d6 of damage per stack
Absorption-> Immunity-> Resistance-> Normal-> +1d6 of damage type-> +2d6 of damage type...