1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-29 23:07:48 +02:00

NKAI: rewardables

This commit is contained in:
Andrii Danylchenko
2024-04-20 15:28:42 +03:00
parent 1b10aaa493
commit 1be36e1ad4
5 changed files with 183 additions and 39 deletions

View File

@@ -29,9 +29,6 @@ private:
protected:
/// filters list of visit info and returns rewards that can be granted to current hero
std::vector<ui32> getAvailableRewards(const CGHeroInstance * hero, Rewardable::EEventType event) const;
/// function that must be called if hero got level-up during grantReward call
virtual void grantRewardAfterLevelup(IGameCallback * cb, const Rewardable::VisitInfo & reward, const CArmedInstance * army, const CGHeroInstance * hero) const;
@@ -39,6 +36,9 @@ protected:
virtual void grantRewardBeforeLevelup(IGameCallback * cb, const Rewardable::VisitInfo & reward, const CGHeroInstance * hero) const;
public:
/// filters list of visit info and returns rewards that can be granted to current hero
std::vector<ui32> getAvailableRewards(const CGHeroInstance * hero, Rewardable::EEventType event) const;
Rewardable::Configuration configuration;