[Ace] Looking for a script to trigger SE for counterattack and others

I'm working on a full speech battle system.

For every event in a battle, you can hear a voice saying "attack", "miss", etc.

By default, RPG-Maker uses the same sound effect for "evasion" and "counterattack", which in my case makes things confusing.

I'm looking for a script which can trigger different SE for the following events during a battle:

- counterattack

- substitute

- drain

- buff

- debuff

- action failure

- critical hit

Now, I already have an excellent script made by Nicke (see below).

This scripts works perfectly for the "critical hit" SE. I would need pretty much the same thing for all of the above events.

Hopefully, someone can help me out. Or is there a complete battle system which allows you to do these things?

cheers,

Ultrabonz

#==============================================================================
#   XaiL System - Critical SE
#   Author: Nicke
#   Created: 05/09/2012
#   Edited: 05/09/2012
#   Version: 1.0
#==============================================================================
# Instructions
# -----------------------------------------------------------------------------
# To install this script, open up your script editor and copy/paste this script
# to an open slot below Materials but above Main. Remember to save.
#
# Small snippet to play a critical sound effect at battle.
#
# *** Only for RPG Maker VX Ace. ***
#==============================================================================
($imported ||= {})["XAIL-CRITICAL-SE"] = true

module XAIL
  module CRITICAL_SE
  #--------------------------------------------------------------------------#
  # * Settings
  #--------------------------------------------------------------------------# 
    # Set the Critical sound effect(s).
    # Can be nil to disable.
    # If you have more then one sound effect setup it will be randomized each
    # time a critical effect occurs.
    # SND "name" => [volume, pitch]
    SND = {
    "critical" => [80, 100],
    "critical" => [80, 100],
    "well done" => [80, 100],
    "critical" => [80, 100],
    "totalpain" => [80, 100]
    } # Don't remove this line!
  end
end
# *** Don't edit below unless you know what you are doing. ***
#==============================================================================#
# ** Module Sound
#==============================================================================#
class << Sound
 
  def play_critical
    # // Method to play critical sound effect.
    # This will play a sound effect or return nil if SND is empty/nil.
    return if XAIL::CRITICAL_SE::SND.nil?
    begin
      name = XAIL::CRITICAL_SE::SND.keys.sample
      RPG::SE.new(name, XAIL::CRITICAL_SE::SND[name][0], XAIL::CRITICAL_SE::SND[name][1]).play
    rescue
      msgbox("Error. Unable to locate critical sound effect: " + name)
      exit
    end
  end

end
#==============================================================================#
# ** Window_BattleLog
#==============================================================================#
class Window_BattleLog < Window_Selectable
 
  alias xail_critical_se_win_battlelog_display_critical display_critical
  def display_critical(target, item)
    # // Method to display criticial effect.
    xail_critical_se_win_battlelog_display_critical(target, item)
    if target.result.critical
      Sound.play_critical
    end
  end
 
end # END OF FILE

#=*==========================================================================*=#
# ** END OF FILE
#=*==========================================================================*=#

Original thread: https://forums.rpgmakerweb.com/threads/ace-looking-for-a-script-to-trigger-se-for-counterattack-and-others.17011/