MZ Change weapon element mid battle?

Hi everyone, I want to conduct an experiment to potentially make my project's weapon combat more diverse with elements.
I've looked around and I can't exactly find anything out there that makes an actor's currently held weapon change it's element via skill command.

To make it sound simple enough, Imagine I wanted to make my actor's pistol have access to 4 different skills that change the element into either normal, fire, poison and ice -thus any attacks used by that weapon now apply the newly toggled element effect.

Now I don't quite know if the weapon's element data would be stored for continual use once a battle concludes or if it would restore itself to the default- whether or not the weapon has been changed around into something else.

Has anyone thought of this and know of a plugin already existing? Or is there other aspects of this that could fail in some way?
To make it sound simple enough, Imagine I wanted to make my actor's pistol have access to 4 different skills that change the element into either normal, fire, poison and ice -thus any attacks used by that weapon now apply the newly toggled element effect.
is there a reason the engine's default attack element trait isnt enough? it sounds like you'd just want the skill to set a state on the user with a trait for the corresponding element.

Technically, you could get away with using yanfly's skill core to find the user's weapon and change the element of the data entry, but that change wouldnt be retained when the game is closed and would be retained when changing saves.
Now if you happen to also be using yanfly's item core and use independent weapons, then i believe that wont be an issue as the independent item keeps their changed properties.
Just add a state that raise the element to your actor?

I think you also need to mention what elements can do in your project.
For example, if you get ice element, what do you get or what can you do?
is there a reason the engine's default attack element trait isnt enough? it sounds like you'd just want the skill to set a state on the user with a trait for the corresponding element.
The issue generally speaking with apply a state means that every command will use that same element, so in theory if I made the actor element into fire- the pistol would do fire damage (as if the user reloaded incendiary bullets) but the actor's other abilities like punching would also end up doing the same element which isn't quite what I want to happen.
Technically, you could get away with using yanfly's skill core to find the user's weapon and change the element of the data entry
The problem with Yanfly's plugins is that they don't quite seem to want to function reliably in MZ from memory, even with VS core plugins installed. I don't quite think the MV ones handle well.
but that change wouldnt be retained when the game is closed and would be retained when changing saves.
This does sound pretty good, course starting anew would have everything set to there default data, saved game data is key.

Just add a state that raise the element to your actor?

I think you also need to mention what elements can do in your project.
For example, if you get ice element, what do you get or what can you do?
As previously mentioned, in theory this would work but it would generalize the actor to that element and not the skills specific to the weapon in question.
For the most part my current project's elements are pretty much the same albeit some name changes like fire = pyro. Each weapon would have access to only a few types.
The problem with Yanfly's plugins is that they don't quite seem to want to function reliably in MZ from memory, even with VS core plugins installed. I don't quite think the MV ones handle well.
i mentioned yanfly's plugins because i remembered responding to threads of yours in the past, but you dont have your engine listed on your profile so i assumed MV. In terms of doing what i mentioned though, that still doable with Visustella's battle core where youd add the element trait to the weapon. However...

This does sound pretty good, course starting anew would have everything set to there default data, saved game data is key.
one thing i forgot to mention that this change would affect all versions of the weapon. so if both actor A and B use a "pistol", and A uses loads poison rounds, "pistol" is now dealing poison damage and both actors are "using" poison rounds.

If that wont be an issue and you need help, say the word, but that addition might change the usefulness of it.

Edit:
The issue generally speaking with apply a state means that every command will use that same element, so in theory if I made the actor element into fire- the pistol would do fire damage (as if the user reloaded incendiary bullets) but the actor's other abilities like punching would also end up doing the same element which isn't quite what I want to happen.
also keep in mind, attack element traits only impact skills with the normal attack element. neither changing the weapon's element trait nor giving attack element states will change the element of skills that arent normal attack, and both will affect skills that are normal attack
Hmm, based on what you've said, I myself would create 4 sets of pistol skills with same names but different elements. If I change my pistol element to ice, simply swap the skill set to ice.

Original thread: https://forums.rpgmakerweb.com/threads/change-weapon-element-mid-battle.174122/