How do you handle level dependent traits?

For example, you have a Fire Mage. He or she starts with 25% fire resistance. When they reach level 10, it goes up to 50%. Level 20, it becomes 75% and at level 30 they get full-on fire immunity. How do you do this in RPG Maker MV?

My closest guess would be permanent States but I'm not sure of a very clean way to actually add one when a character reaches a specific level. An always running background process that's constantly checking whether a certain Actor is a certain level and doesn't have a particular state is total overkill for something that's going to happen 1-3 times in the entire game. I feel like I'm missing something that's staring me right in the face.

How do you guys and gals handle this sort of thing that's extremely common in a lot of RPGs like D&D? Seems like it's something that should be built directly into the editor but I'm not seeing it.
A few plugins out there exist to give actors (or equips or enemies or classes and so on) Passive States. The most popular is Yanfly's Auto Passive States. You can check for things like level easily, using conditionals.
I think you shouldn't handle it by states, but use a plugin for dynamic traits instead. Those plugins allow you to add or remove traits from your actors, making that workaround with states unneeded.
https://forums.rpgmakerweb.com/index.php?threads/dynamic-traits-and-effects.51533/
I see how to do this with Yanfly's Auto-Passive States. It requires Lunatic Code but it's extremely easy.

Adding traits would be a little cleaner but Shaz's plug-in seems to be reliant on running an event to add them. Level ups typically just happen when you reach XP thresholds so I'm not exactly sure how that would work. I suppose it wouldn't be too difficult to add in a Common Event call on level up to the JavaScript.

Thanks for the advice! If anyone has any other ideas, please share.
You can use level based traits by using these plugins.
https://forums.rpgmakerweb.com/index.php?threads/icf-soft-main-utility.67848/
https://forums.rpgmakerweb.com/index.php?threads/icf-soft-actors-core.76319/
Latest versions can be found in my blog.

You can give them to actors or classes. Here the code for your example:
Code:
<LEVEL SUBTRAITS: 0 0, 10 1, 20 2, 30 3>

<SUBTRAITS MASTER>
elem_rate 1 0.75
<SUBTRAITS MASTER>
elem_rate 1 0.50
<SUBTRAITS MASTER>
elem_rate 1 0.25
<SUBTRAITS MASTER>
elem_rate 1 0
</SUBTRAITS MASTER>
As you can see element rate works differently.

I hope this will be usefull.

Original thread: https://forums.rpgmakerweb.com/threads/how-do-you-handle-level-dependent-traits.78456/