2
0

BattleAction.cpp 610 B

1234567891011121314151617181920212223242526272829303132
  1. /*
  2. * BattleAction.cpp, part of VCMI engine
  3. *
  4. * Authors: listed in file AUTHORS in main folder
  5. *
  6. * License: GNU General Public License v2.0 or later
  7. * Full text of license available in license.txt file, in main folder
  8. *
  9. */
  10. #include "StdInc.h"
  11. #include "BattleAction.h"
  12. #include "../../AIGateway.h"
  13. #include "../../Goals/CompleteQuest.h"
  14. namespace NKAI
  15. {
  16. namespace AIPathfinding
  17. {
  18. void BattleAction::execute(AIGateway * ai, const CGHeroInstance * hero) const
  19. {
  20. ai->moveHeroToTile(targetTile, hero);
  21. }
  22. std::string BattleAction::toString() const
  23. {
  24. return "Battle at " + targetTile.toString();
  25. }
  26. }
  27. }