You mean, directly in the Database?
Yes.
The idea would be something like:
JavaScript:
if (currentStack < maxStack){
apply the same state again;
}
// The final result I want to achieve is to increase the damage
// done with each stack using the Element Rate Trait
For a stack counter, consider looking at how the core scripts handle
_stateTurns (rpg_objects.js): you could add a similar counter for stacks.
Traits are fetched from states through the
traitObjects method of
Game_BattlerBase. So maybe just add duplicate copies of each stacked state there?