Whats the easiest way to increment a variable when using an item?

Without common events? My issue is basically the exact same as this guys:


but I cant figure out how to do this in MV. I found another person saying to use the dmg formula of the item to do it (something like "v[200] += 1") but this simply did not work for me. Can anyone help me out?
Is there a particular reason you don't want to use a common event for this? Not doing so would require a plugin or code edit.
Is there a particular reason you don't want to use a common event for this? Not doing so would require a plugin or code edit.

Yes, Because im already running out of total common events in my 10 year long project of a game (ported over from older versions of rpg maker many times). This new system im building will be made up of over 100 items. I simply cannot implement it using a common event for each item (each common event would simply be a variable edit followed by an event call to the main event driving the system). I will use any code edit or plugin you know of. The post I linked showed a code edit to achieve this but I cant find the file to edit for MV.
Are you using any other plugins or just using out-of-the-box MV? (also if it helps you can do this with one common event)
I use many many plugins. It would be easier if you asked to check if I have a certain one lol. As for the common event thing, ya, thats absolutely the plan. This whole system can be built with 1 common event assuming I can have some idea of which item was used to call the common event. Ill take any form of identifier to know which item the user called the event with (capturing the item id etc.)
Its so weird, I keep doing research and everyone seems to have a way to do this but I cant get any of it to work. I must be crazy. I keep seeing people saying to use the DMG formula of the item but no matter what I do this wont adjust the variable. I just want to capture the item ID and/or adjust a variable manually before calling the items common event. I have 100 items and all of them will call the same common event, I just need a way to know what item called it.
Issue solved. Can close thread.
Turns out the game ships with a plugin called last used item... im... speechless.
You can use the damage formula. The damage formula runs before any common event assigned to the item. So you can make the event occur according to the var. I could only make it work with the scope being in someone in the party.

I had the same problem, it was kinda difficult to figure this out (even reading older topics). In the picture example, it sets the var 4990 to 1 and runs the common event "debug_file test". So in the common event there is a conditional branch "if var 4990 = 1, do this; else, do this; else, do this" and so goes on.

I've got Galv's plugin to skip the item target when there is only one person on the party, because I have multiple characters doing "solo runs". There are other plugins to skip that window if needed.
Thank you, but I actually just solved this. Turns out the game ships with a plugin called last used item. This solved everything. Cant believe I never noticed it. Thanks for the help everyone.
EDIT:
Your formula info was very helpful for future things ty. My issue was my target was set to none. I get it now.

Can close thread, unless Im able to do that?

Original thread: https://forums.rpgmakerweb.com/threads/whats-the-easiest-way-to-increment-a-variable-when-using-an-item.123545/