ISpecialAction.h 711 B

123456789101112131415161718192021222324252627282930313233343536
  1. /*
  2. * ISpecialAction.h, 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. #pragma once
  11. #include "../../AIUtility.h"
  12. #include "../../Goals/AbstractGoal.h"
  13. struct AIPathNode;
  14. class ISpecialAction
  15. {
  16. public:
  17. virtual bool canAct(const CGHeroInstance * hero) const
  18. {
  19. return true;
  20. }
  21. virtual Goals::TSubgoal whatToDo(const CGHeroInstance * hero) const = 0;
  22. virtual void applyOnDestination(
  23. const CGHeroInstance * hero,
  24. CDestinationNodeInfo & destination,
  25. const PathNodeInfo & source,
  26. AIPathNode * dstMode,
  27. const AIPathNode * srcNode) const
  28. {
  29. }
  30. };