2021-05-15 18:22:44 +02:00
|
|
|
/*
|
|
|
|
* TownPortalAction.h, part of VCMI engine
|
|
|
|
*
|
|
|
|
* Authors: listed in file AUTHORS in main folder
|
|
|
|
*
|
|
|
|
* License: GNU General Public License v2.0 or later
|
|
|
|
* Full text of license available in license.txt file, in main folder
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2021-05-16 13:38:53 +02:00
|
|
|
#include "SpecialAction.h"
|
2021-05-15 18:22:44 +02:00
|
|
|
#include "../../../../lib/mapObjects/MapObjects.h"
|
|
|
|
#include "../../Goals/AdventureSpellCast.h"
|
|
|
|
|
2022-09-26 20:01:07 +02:00
|
|
|
namespace NKAI
|
|
|
|
{
|
2021-05-15 18:22:44 +02:00
|
|
|
namespace AIPathfinding
|
|
|
|
{
|
2021-05-16 13:38:53 +02:00
|
|
|
class TownPortalAction : public SpecialAction
|
2021-05-15 18:22:44 +02:00
|
|
|
{
|
|
|
|
private:
|
|
|
|
const CGTownInstance * target;
|
|
|
|
|
|
|
|
public:
|
|
|
|
TownPortalAction(const CGTownInstance * target)
|
|
|
|
:target(target)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2024-03-31 17:39:00 +02:00
|
|
|
void execute(AIGateway * ai, const CGHeroInstance * hero) const override;
|
2021-05-16 13:38:53 +02:00
|
|
|
|
2024-02-13 16:21:30 +02:00
|
|
|
std::string toString() const override;
|
2021-05-15 18:22:44 +02:00
|
|
|
};
|
2022-09-26 20:01:07 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
}
|