# Vanguard - Melee Tank/DPS
# Flexible hybrid class: Choose Shield Bearer (tank) or Weapon Master (DPS)

class_id: vanguard
name: Vanguard
description: >
  A seasoned warrior who stands at the front lines of battle. Vanguards excel in melee combat,
  capable of becoming an unbreakable shield for their allies or a relentless damage dealer.
  Choose your path: become a stalwart defender or a devastating weapon master.

# Base stats (total: 65 + luck)
base_stats:
  strength: 14      # High physical power
  dexterity: 10     # Average agility
  constitution: 14  # High endurance for tanking
  intelligence: 8   # Low magic
  wisdom: 10        # Average perception
  charisma: 9       # Below average social
  luck: 8           # Low luck, relies on strength

# Starting equipment (minimal)
starting_equipment:
  - rusty_sword
  - cloth_armor
  - rusty_knife  # Everyone gets pocket knife

# Starting abilities
starting_abilities:
  - basic_attack

# Skill trees (mutually exclusive playstyles)
skill_trees:
  # ==================== SHIELD BEARER (Tank) ====================
  - tree_id: shield_bearer
    name: Shield Bearer
    description: >
      The path of the defender. Master the shield to become an impenetrable fortress,
      protecting your allies and controlling the battlefield.

    nodes:
      # --- TIER 1 ---
      - skill_id: shield_bash
        name: Shield Bash
        description: Strike an enemy with your shield, dealing minor damage and stunning them for 1 turn.
        tier: 1
        prerequisites: []
        effects:
          abilities:
            - shield_bash  # References ability YAML

      - skill_id: fortify
        name: Fortify
        description: Your defensive training grants you enhanced protection.
        tier: 1
        prerequisites: []
        effects:
          stat_bonuses:
            defense: 5

      # --- TIER 2 ---
      - skill_id: shield_wall
        name: Shield Wall
        description: Raise your shield to block incoming attacks, reducing damage by 50% for 3 turns.
        tier: 2
        prerequisites:
          - shield_bash
        effects:
          abilities:
            - shield_wall

      - skill_id: iron_skin
        name: Iron Skin
        description: Your body becomes hardened through relentless training.
        tier: 2
        prerequisites:
          - fortify
        effects:
          stat_bonuses:
            constitution: 5

      # --- TIER 3 ---
      - skill_id: guardians_resolve
        name: Guardian's Resolve
        description: Your unwavering determination makes you nearly impossible to break.
        tier: 3
        prerequisites:
          - shield_wall
        effects:
          stat_bonuses:
            defense: 10
          passive_effects:
            - stun_resistance  # Immune to stun when shield wall active

      - skill_id: riposte
        name: Riposte
        description: After blocking an attack, counter with a swift strike.
        tier: 3
        prerequisites:
          - iron_skin
        effects:
          abilities:
            - riposte

      # --- TIER 4 ---
      - skill_id: bulwark
        name: Bulwark
        description: You are a living fortress, shrugging off blows that would fell lesser warriors.
        tier: 4
        prerequisites:
          - guardians_resolve
        effects:
          stat_bonuses:
            constitution: 10
            resistance: 5

      - skill_id: counter_strike
        name: Counter Strike
        description: Enhance your Riposte ability to deal critical damage when countering.
        tier: 4
        prerequisites:
          - riposte
        effects:
          ability_enhancements:
            riposte:
              crit_chance_bonus: 0.3  # +30% crit on riposte

      # --- TIER 5 (Ultimate) ---
      - skill_id: unbreakable
        name: Unbreakable
        description: Channel your inner strength to become invulnerable, reducing all damage by 75% for 5 turns.
        tier: 5
        prerequisites:
          - bulwark
        effects:
          abilities:
            - unbreakable  # Ultimate defensive ability

      - skill_id: fortress
        name: Fortress
        description: Your defensive mastery reaches its peak. Permanently gain massive defensive bonuses.
        tier: 5
        prerequisites:
          - counter_strike
        effects:
          stat_bonuses:
            defense: 20
            constitution: 10
            resistance: 10

  # ==================== WEAPON MASTER (DPS) ====================
  - tree_id: weapon_master
    name: Weapon Master
    description: >
      The path of destruction. Master devastating melee techniques to cut through enemies
      with overwhelming physical power.

    nodes:
      # --- TIER 1 ---
      - skill_id: power_strike
        name: Power Strike
        description: A heavy attack that deals 150% weapon damage.
        tier: 1
        prerequisites: []
        effects:
          abilities:
            - power_strike

      - skill_id: weapon_proficiency
        name: Weapon Proficiency
        description: Your training with weapons grants increased physical power.
        tier: 1
        prerequisites: []
        effects:
          stat_bonuses:
            strength: 5

      # --- TIER 2 ---
      - skill_id: cleave
        name: Cleave
        description: Swing your weapon in a wide arc, hitting all enemies in front of you.
        tier: 2
        prerequisites:
          - power_strike
        effects:
          abilities:
            - cleave  # AoE attack

      - skill_id: battle_frenzy
        name: Battle Frenzy
        description: The heat of battle fuels your strength.
        tier: 2
        prerequisites:
          - weapon_proficiency
        effects:
          stat_bonuses:
            strength: 5

      # --- TIER 3 ---
      - skill_id: rending_blow
        name: Rending Blow
        description: Strike with such force that your enemy bleeds for 3 turns.
        tier: 3
        prerequisites:
          - cleave
        effects:
          abilities:
            - rending_blow  # Applies bleed DoT

      - skill_id: brutal_force
        name: Brutal Force
        description: Your attacks become devastatingly powerful.
        tier: 3
        prerequisites:
          - battle_frenzy
        effects:
          stat_bonuses:
            strength: 10

      # --- TIER 4 ---
      - skill_id: execute
        name: Execute
        description: Finish off weakened enemies. Deals bonus damage to targets below 30% HP.
        tier: 4
        prerequisites:
          - rending_blow
        effects:
          abilities:
            - execute

      - skill_id: weapon_mastery
        name: Weapon Mastery
        description: Your expertise with weapons allows you to find weak points more easily.
        tier: 4
        prerequisites:
          - brutal_force
        effects:
          stat_bonuses:
            strength: 5
          combat_bonuses:
            crit_chance: 0.15  # +15% crit chance

      # --- TIER 5 (Ultimate) ---
      - skill_id: titans_wrath
        name: Titan's Wrath
        description: Unleash a devastating attack that deals 300% weapon damage and stuns all enemies hit.
        tier: 5
        prerequisites:
          - execute
        effects:
          abilities:
            - titans_wrath  # Ultimate offensive ability

      - skill_id: perfect_form
        name: Perfect Form
        description: Your combat technique reaches perfection. Massive offensive bonuses.
        tier: 5
        prerequisites:
          - weapon_mastery
        effects:
          stat_bonuses:
            strength: 20
            dexterity: 10
          combat_bonuses:
            crit_chance: 0.1   # Additional +10% crit
            crit_multiplier: 0.5  # +0.5 to crit multiplier
