[Help] How to detect if skill is used?

Hello dear Community, I am new here and not sure if my topic is in the right board. If not, feel free to move it to the right spot.

Ok, lets get serious.

First of all: I am new to Ruby as a programming language, I know several basics, not the complex stuff.

So, I plan to make a system, with scene and windows (I have to learn that next...), where the player can combine elements to get new elements and can learn new skills of this element. 

The idea is, if the player uses the Fire skill lets say 10 times, he earns one point for Fire. He used the Earth skill 12 times and earn a point for Earth. Now he can go to the combination scene and spend this points either to make the Fire or Earth skill stronger or combine both (since the player has 1 point for both) to create a Magma Element skill.

My problem here is, after hours of searching and reading the help file, ..... how can I check in battle what elemental skill is used and is successfull and store this into a variable??

I am sure I can do this with Common Events but since I plan to make a whole menu for this, I think it is not clever to make something like this with Common Events, so I have to make this as script.

Does anyone have an idea?? Every help is very welcome!!

Thanks for reading. =)
You do not have to use a script for this (but if you really wanted to, Learning Ruby and RGSSx, or RGSSx Script Support would be the appropriate places to post). You could simply edit your skill's damage formula for each skill to increment the appropriate variable when the skill is used. Don't even need to use a common event.


Let's say variable 1 is your fire element variable.


In all of your fire skills, put this into the start of the damage formula:

v[1] += 1;and leave the original formula at the end.
Then each time one of your fire skills is used, variable 1 will be incremented.
Oooohh... I can do THIS in damage formula?? I don't know this, never read anything that I can do this this way.

Well... Thank you very much Shaz!! Wow.

So, next on Todo List: learn how to make scenes and windows ^^

I think.. this topic can be closed due to solving my problem. =)

Original thread: https://forums.rpgmakerweb.com/threads/help-how-to-detect-if-skill-is-used.35674/