Displaying HP Bars via skill? (Enemy HP Bars script)

Hi, I've been having some trouble with HP bars.

In my game, enemies don't have visible HP bars. However, I want a party member to have a skill that makes an HP bar appear underneath the enemy it is used on, like the Tattle skill in the Paper Mario series.

Since HP bars require scripting, so far I have worked around it by simply having a text box pop up that says "this enemy has ___ HP remaining". However this isn't a very elegant solution especially considering you have to use it every time you want to see how much health they have, and it's especially annoying to remember when multiple enemies are in battle considering it doesn't distinguish which enemy it's currently talking about.

So I asked my friend for help and they sent me the Enemy HP Bars script (I'm using the Yanfly engine) and recommended fiddling around with enemy tags. It works fine still, but I can't get HP bars to appear or disappear mid-battle by tweaking any variables or state tags. I've tried utilizing states with "<show gauge>" or "<hide gauge>" in the tags and have a skill apply or remove it, but that doesn't work. I think this is because state tags can't apply enemy tags, which happen upon initialization of the battle, I think.

I haven't been able to find another script for this kind of thing, and I'm a little too scared to dive into the code and try to engineer a solution myself because I'm not very code-literate. What should I do?
Moved to: RGSSx Script Support
It's not impossible to come up with a scriptlet focused on just drawing the HP bar / gauge. The thing is that I ignore what's the exact name of the battlesystem you've implemented in your game.
+ my add on to hide until skill is selected
Spoiler: Hide HP bar
Ruby:
# ╔═════════════════════════════════════╦════════════════════╗
# ║ Title: Ventwig Enemy HP Selection   ║  Version: 1.05a    ║
# ║ Author: Roninator2                  ║                    ║
# ╠═════════════════════════════════════╬════════════════════╣
# ║ Function:                           ║   Date Created     ║
# ║                                     ╠════════════════════╣
# ║ Show hp only for enemy selected     ║    08 Jan 2022     ║
# ╚═════════════════════════════════════╩════════════════════╝
# ╔══════════════════════════════════════════════════════════╗
# ║ Requires: Ventwig Enemy HP Bars Script                   ║
# ╚══════════════════════════════════════════════════════════╝
# ╔══════════════════════════════════════════════════════════╗
# ║ Script adjusts Ventwigs script to make the Bars shown to ║
# ║ only be visible on the enemy when that enemy is selected ║
# ╚══════════════════════════════════════════════════════════╝
# ╔══════════════════════════════════════════════════════════╗
# ║ Updates:                                                 ║
# ║ 1.05a - 08 Jan 2022 - Initial publish                    ║
# ╚══════════════════════════════════════════════════════════╝
# ╔══════════════════════════════════════════════════════════╗
# ║ Terms of use:                                            ║
# ║ Free for all RPG Maker VX Ace uses                       ║
# ╚══════════════════════════════════════════════════════════╝
module R2_Enemy_Hud_Show_HP
  Skill = [80,105]       # skills that will show the HP bar
end
class Window_Enemy_Hud < Window_Base
  attr_accessor :damage_time
  alias r2_init_enemy_hp initialize
  def initialize
    r2_init_enemy_hp
    show_hp(false)
  end
 
  def show_hp(value = false)
    @show_hp = value
  end
 
  def enemy_id(value = -1)
    @enemy_id = value
  end
 
  def update
    refresh_okay = false
    $game_troop.alive_members.each do |enemy|
      if enemy.hp != enemy.old_hp || enemy.mp != enemy.old_mp
        refresh_okay = true
        enemy.old_hp = enemy.hp
        enemy.old_mp = enemy.mp
      end
    end
  
    if $game_troop.alive_members.size != @old_size
      refresh_okay = true
    end
  
    if refresh_okay
      refresh
    end
  end

  def enemy_hud
    troop_fix
    for i in [email hidden]_members.size-1
      e = @enemy[i]
      if i <= 1 and e.boss_bar == true and e == @boss_enemy[i]
        draw_actor_name(e,EHUD::BOSS_GAUGEX,5+50*i)
        draw_actor_hp(e,EHUD::BOSS_GAUGEX,20+50*i,width=EHUD::BOSS_GAUGEW) unless e.hide_hp == true
        draw_actor_mp(e,EHUD::BOSS_GAUGEX,30+50*i,width=EHUD::BOSS_GAUGEW) unless e.show_mp == false
        draw_actor_icons(e,EHUD::BOSS_GAUGEX+200,5+50*i, width = 96)
      elsif ($game_switches[EHUD::HIDE_MINIONS] != true && @show_hp == true) && e.index == @enemy_id
        draw_actor_hp(e,e.screen_x-50,e.screen_y+EHUD::Y_MOVE-50+e.personal_y,width=96) unless e.hide_hp == true
        draw_actor_mp(e,e.screen_x-50,e.screen_y+EHUD::Y_MOVE-40+e.personal_y,width=96) unless e.show_mp == false
        draw_actor_icons(e,e.screen_x-50,e.screen_y+EHUD::Y_MOVE-70+e.personal_y,width=96)
      end
    end
  end
end

class Scene_Battle < Scene_Base
 
  alias r2_update_basic_hp  update_basic
  def update_basic
    @skill_check = -1 unless @enemy_window.active
    @skill_check = @skill_window.item.id if @skill_window.active
    if @enemy_window.active
      enemy_hp_shown(true) if R2_Enemy_Hud_Show_HP::Skill.include?(@skill_check)
    else
      enemy_hp_shown(false) if (!@subject && @enemy_hud_window.damage_time = 0) && !@enemy_window.active
    end
    r2_update_basic_hp
  end

  def enemy_hp_shown(value = false)
    @enemy_hud_window.show_hp(value)
    if @enemy_window.enemy != nil
      @enemy_hud_window.enemy_id(@enemy_window.enemy.index)
    end
    @enemy_hud_window.refresh
  end
end

Original thread: https://forums.rpgmakerweb.com/threads/displaying-hp-bars-via-skill-enemy-hp-bars-script.143711/