#pragma once
#include "Command.h"

class UnloadAllUnitsAtPositionCommand : public Command
{
public:
  UnloadAllUnitsAtPositionCommand(BehaviorState& state, BWAPI::Position position)
    : Command(state)
    , m_position(position)
  {
  }
  virtual bool execute(BWAPI::Unit* unit) const
  {
    return unit->unloadAll(m_position);
  }
protected:
  virtual void _output(std::ostream& out) const
  {
    out << "Unload-All-Units at " << m_position;
  }

  const BWAPI::Position m_position;
};
