package org.project.entity.players;


import org.project.entity.Entity;
import org.project.item.armors.Armor;
import org.project.item.armors.KnightArmor;
import org.project.item.weapons.Sword;
import org.project.item.weapons.Weapon;

public class Knight extends Player {

    public Knight(String name, int hp, int mp, Weapon weapon, Armor armor) {
        super(name, 80, 40, new Sword(), new KnightArmor(8,20));
    }

    public Knight(String name) {
        super(name, 80, 40, new Sword(), new KnightArmor(8,20));
    }

    @Override
    public void specialAbility(Entity target) {
        if(mp >= 15){
            mp -= 15;
            int damage = weapon.getDamage() + 15;
            target.takeDamage(damage);
            System.out.println("\u001B[35m " + name + "enemy stunned (-15 mana)" + damage + "damage! \u001B[0m");
        }else{
            System.out.println("\u001B[33m Not enough mana ! \u001B[0m");
            lightAttack(target);
        }
    }
}
