Record number of times a skill is used in battle

Hi,

Im looking for a plugin that records how many times a skill has been used in battle, esentially what i'm looking for is a MV version of this XP script

Spoiler
Code:
class Change_with_id_skl
 
 
  #EDIT THIS!
  #Is the ID of the variable where the values will be saved with the saves
  #You can't use it for other purpose in your game 
  Number_of_variable_to_save=6
  #END OF 1st EDIT
 
  @data_set={}
 
=begin
Type of edit:
-------------------------------------------------------
1st:
@data_set[id_of_player]={}
2nd step:
@data_set[id_of_player][id_of_skill]=0  #Or use some the default value
                                        #when "new game"
#id_of_player is the id of the player that cast the skill
              two players with the same magic have separate values
              To use the same value only sum both when needed
              Use a negative value for monsters!
#id_of_skill is the id of the skill used

And repeat for others skills
-------------------------------------------------------
=end


 
  #MUST EDIT FOR YOUR PLAYERS
#------------------------------------------------------


  @data_set[1]={}
  @data_set[1][1]=0
  @data_set[1][2]=0
  @data_set[1][7]=0
  @data_set[1][8]=0
  @data_set[1][13]=0
  @data_set[1][14]=0

 
#------------------------------------------------------
  #END MUST EDIT

 
  @data_set_starts=@data_set.dup
 
 
 
#To know a value:
#variable = Change_with_id_skl.returner(id_name,id_skill)

#To change a value:
#Change_with_id_skl.returner(id_name,id_skill,new_value)


  def self.returner(id_name,id_skill,value=nil)
    if value == nil
      if $game_variables[Number_of_variable_to_save] != 0
        @data_set=$game_variables[Number_of_variable_to_save].dup
      else
        @data_set=@data_set_starts.dup
      end
      if @data_set[id_name] == nil
        return nil
      else
        return @data_set[id_name][id_skill]
      end
    else
      @data_set[id_name][id_skill]=value
      $game_variables[Number_of_variable_to_save]=@data_set.dup
    end
  end
 
 
  def self.data(name,id_skill,value)
    if $game_variables[Number_of_variable_to_save] != 0
      @data_set=$game_variables[Number_of_variable_to_save].dup
    else
      @data_set=@data_set_starts.dup
    end
    if @data_set[Change_with_id_skl.id_searcher(name)] != nil
      if @data_set[Change_with_id_skl.id_searcher(name)][id_skill] != nil
        @data_set[Change_with_id_skl.id_searcher(name)][id_skill]+=value
        $game_variables[Number_of_variable_to_save]=@data_set.dup
      end
    end
  end
 
  def self.id_searcher(name)
    j=0
    $data_actors.each do |i|
      if i != nil
        if i.name == name
          return j
        end
      end
      j+=1
    end
    j=0
    $data_enemies.each do |i|
      if i != nil
        if i.name == name
          return -j
        end
      end
      j+=1
    end
  end
end

class Scene_Battle
  alias change_vars_with_id_name_MSAR make_skill_action_result
  def make_skill_action_result
    change_vars_with_id_name_MSAR
    Change_with_id_skl.data(@active_battler.name,
           @active_battler.current_action.skill_id,1)
  end
end
Here you go :

Original thread: https://forums.rpgmakerweb.com/threads/record-number-of-times-a-skill-is-used-in-battle.87883/