#pragma once
#include "../Command.h"

class HealCommand : public LowLevelAction
{
public:
  HealCommand(IBehaviorState& state)
    : LowLevelAction(state)
  {
  }
  virtual std::string getDescription() const
  {
    return "Heal " + getObjectDescription(m_unitToHeal);
  }
  void setUnitToHeal(BWAPI::Unit* unit)
  {
    m_unitToHeal = unit;
  }
  virtual bool execute(BWAPI::Unit* unit) const
  {
    return unit->useTech(BWAPI::TechTypes::Healing, m_unitToHeal);
  }
protected:
  BWAPI::Unit* m_unitToHeal;
};